Repository navigation
fix(roadmap): stage writes RENAMED and REMOVED spec deltas - #5367
Conversation
The stage reply had only `added` and `modified`, so a plan that changes the meaning of a requirement kept the old name above the new text. Plan #5182 did this, and #5336 merged the false name into the living spec. - `StageSpec` gets `renamed` (`from_name`, `to_name`) and `removed` (`name`, `reason`, optional `migration`). `spec_file` writes them in the OpenSpec form that the repository already uses. - The spec-delta gate refuses a rename or a removal on a new capability, and a base name that `openspec archive` refuses. - The scenario copy, the stale-command check and the moved-spec check of plan-check read a renamed requirement under its old name. - The plan reader reads both sections back (#5205, the reader part of #5256). - The stage prompt tells when to rename and remove, and the review prompt makes a name that no longer fits its text a spec_delta_wrong finding.
A live run of openspec validate --strict with the base spec passes a rename that openspec archive refuses: it gives only the first such rename as an INFO line. It gives no line for a removed name that the base spec does not have, and the archive skips that removal with a warning. The gate text said that validate does not compare the names and that the archive refuses all of them. Both were false.
Evidence and checksPremise. At Fail-to-pass. Fixtures from real plans. The live OpenSpec tests in Review fix (commit
So the gate is still necessary (it reports each refused rename at once, and it is the only check for an unknown removal). The fix corrects the text in the docstring, the message comment, Checks on the final head (rebased on
Render diff. The change touches no Release and roll-outA release is necessary. The stage job, fix-plan and plan-check run from the devops-cli image, so the fix takes effect after the next release and the image roll-out of the Service and the runner. No ConfigMap or setting changes. No restart is necessary other than the image roll-out. Notes
|
The plan reader tests read two byte copies of archived spec deltas under tests/fixtures/roadmap/spec_deltas/. The document invariant counts each Markdown file there as a hand-written document that no link from AGENTS.md reaches, so shard 2 of Tests & Coverage failed. The tests now read the files of the archived change folders, which the repository keeps as records.
Archive 5340-stage-renamed-removed-deltas into the living specs. The delta renames two requirements of roadmap-stage/spec-delta and modifies them under the new names. The text of the stale-command requirement is shorter than the delta of the first commit, so it stays in the limit of 500 characters.
24ef620 to
8da8d2b
Compare
Second review fixShard 2 of The two fixtures were byte copies of the archived spec deltas of #4798 and #5150, and the document inventory counted them as hand-written documents that no link from AGENTS.md reaches. Commit Checks on the new head: |
🤖 I have created a release *beep* *boop* --- ## [0.127.1](v0.127.0...v0.127.1) (2026-11-13) ### Bug Fixes * **ci:** alarm at 360 s, one P0 issue, shards by recorded time ([#5377](#5377)) ([2abd6ff](2abd6ff)) * **github:** read the plan diff and the release files from the merge base ([#5401](#5401)) ([c54e14c](c54e14c)) * **infra:** turn off the Ansible color of every playbook run ([#5381](#5381)) ([5bafb1a](5bafb1a)), closes [#5352](#5352) * install-tools --check passes an older openspec binary ([#5355](#5355)) ([625c89d](625c89d)) * **k8s:** allow only the Ingress origins in Open WebUI ([#5357](#5357)) ([fdab229](fdab229)) * **pr:** count only the latest run of each check ([#5393](#5393)) ([634dc91](634dc91)) * **review:** drop the fixed gateway URL of the review dry run ([#5399](#5399)) ([0666d3d](0666d3d)) * **review:** review a pull request at the merge base of its base branch ([#5387](#5387)) ([351ba2a](351ba2a)), closes [#5346](#5346) * **roadmap:** end fix-plan at a time budget with a result line ([#5380](#5380)) ([20468f4](20468f4)), closes [#5363](#5363) * **roadmap:** refine skips an item that changed during the write ([#5392](#5392)) ([a863dda](a863dda)) * **roadmap:** stage writes RENAMED and REMOVED spec deltas ([#5367](#5367)) ([4abbbd2](4abbbd2)) * **roadmap:** title the delivery by the summary of its plan ([#5376](#5376)) ([10e1069](10e1069)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). Co-authored-by: dan-petty-release[bot] <346998822+dan-petty-release[bot]@users.noreply.github.com>
The stage reply can rename and remove base requirements.
StageSpecgetsrenamed(from_name,to_name) andremoved(name,reason, optionalmigration).spec_filewrites them as## RENAMED RequirementsFROM and TO lines and## REMOVED Requirementsblocks, as OpenSpec 1.17.0 reads them. The gate refuses a rename or a removal that the base spec does not allow. The scenario copy and plan-check read a renamed requirement under its old name, because the archive renames before it modifies. The plan reader reads both sections back, so fix-plan keeps them.The stage prompt says when to rename or remove. The review reports a modified requirement whose name no longer fits its text as
spec_delta_wrong.Before, a plan could only keep the old name above the new text. Plan #5182 did that, and #5336 merged a requirement whose name says the opposite of its text.
Refs #5256
Closes #5340
Change:
openspec/changes/archive/2026-11-13-5340-stage-renamed-removed-deltas/