{"version":"2.1.299","anchor":"project-doc-writes-get-optimistic-concurrency-via-if-version","canonical_anchor":"project-doc-writes-get-optimistic-concurrency-via-if-version","heading":"Project doc writes can refuse to overwrite someone else's changes","tier":"notice","area":"Projects","scope":"individual","heads_up":false,"url":"https:\/\/changelogs.core-directive.com\/v\/2.1.299\/e\/project-doc-writes-get-optimistic-concurrency-via-if-version","release_url":"https:\/\/changelogs.core-directive.com\/v\/2.1.299","markdown":"### Project doc writes can refuse to overwrite someone else's changes\n\n`project_write` accepts an optional `if_version` and refuses to overwrite an existing doc that changed since that version\n\n**What**\n\nThe `project_write` tool, which writes project docs, now accepts an optional `if_version` field. When writing to a doc that already exists, you can pass the `version` that came with the copy you worked from. If the doc has changed since that version, the write is refused instead of going through.\n\n**Why**\n\nWithout this, two edits to the same doc made around the same time could mean one silently replaces the other. With `if_version`, the later write is stopped so the newer changes are not lost.\n\n- Area: Projects\n- Names: `if_version`\n- Tier: You'll notice\n- Useful: 3\/5\n- Signal: 2\/5\n- Scope: individual\n- Heads-up: no"}