Fission-AI/OpenSpec · error · Error
Main spec ' ' changed while archive was securing it for…
Error message
Main spec '${p.update.id}' changed while archive was securing it for retirement. What it means
Retirement verification guard: while securing a main spec for retirement, its fingerprint (targetMovableFingerprint) no longer matches the displaced copy, indicating a concurrent change to the spec being retired.
Solutions
- Stop concurrent spec edits and re-run the archive
- Manually inspect the displaced backup vs the current spec if the state is unclear
Defensive patterns
Strategy: validation
When it happens
Trigger: Thrown at src/core/archive.ts:1803 when the library encounters an invalid state.
Common situations: See trigger scenarios.
AI-assisted analysis of Fission-AI/OpenSpec@6926ccb18a (2026-08-25).
Data as JSON: /api/errors/7fb8370d17c00cc4.
Report an issue: GitHub.
Appendix: source
Thrown at src/core/archive.ts:1803
(await fingerprintSpecInputs(p.update)) !==
`${p.sourceFingerprint}\n${p.targetFingerprint}`
) {
throw new Error(
`Spec inputs for '${p.update.id}' changed before archive could retire them.`
);
}
mutationAttempts.add(p.update.target);
},
verifyDisplaced: async (displacedPath) => {
await assertRetirementAuthorization(
changeDir,
retirementAuthorizationFingerprint!
);
if (
(await fingerprintMovablePath(displacedPath)) !==
p.targetMovableFingerprint
) {
throw new Error(
`Main spec '${p.update.id}' changed while archive was securing it for retirement.`
);
}
},
...(isStoreSelectedRoot(root) ? { displayPath: p.update.target } : {}),
}
);
if (!retired) continue;
const retirementSnapshot = specSnapshotsByTarget.get(p.update.target);
if (retirementSnapshot === undefined || displacedPath === undefined) {
throw new Error(
`Could not track the displaced main spec for '${p.update.id}' during retirement.`
);
}
retirementSnapshot.displacedPath = displacedPath;
retirementSnapshot.displacedFingerprint = p.targetMovableFingerprint;
wroteAny = true;
// A rename applied on the way to the retirement still happened;View on GitHub (pinned to 6926ccb18a)