{"record":{"id":"cf807a899e12318a","repo":"Fission-AI/OpenSpec","slug":"the-metadata-filename-retirement-authorization-cf807a","errorCode":null,"errorMessage":"The ${METADATA_FILENAME} retirement authorization is unavailable.","messagePattern":"The (.+?) retirement authorization is unavailable\\.","errorType":"exception","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"src/core/archive.ts","lineNumber":1776,"sourceCode":"            writeTotals.added += added;\n            writeTotals.modified += modified;\n            writeTotals.removed += removed;\n            writeTotals.renamed += renamed;\n          }\n\n          // Retirements run only after every write has succeeded. If any\n          // later mutation fails, the snapshots below restore every target.\n          for (const p of prepared) {\n            if (p.outcome !== 'retire') continue;\n            const { retired, resolvedPath, displacedPath } = await retireSpec(\n              p.update,\n              mainSpecsDir,\n              {\n                silent: json,\n                deferDelete: true,\n                beforeMutate: async () => {\n                  if (retirementAuthorizationFingerprint === undefined) {\n                    throw new Error(\n                      `The ${METADATA_FILENAME} retirement authorization is unavailable.`\n                    );\n                  }\n                  await assertRetirementAuthorization(\n                    changeDir,\n                    retirementAuthorizationFingerprint\n                  );\n                  if (\n                    (await fingerprintSpecInputs(p.update)) !==\n                    `${p.sourceFingerprint}\\n${p.targetFingerprint}`\n                  ) {\n                    throw new Error(\n                      `Spec inputs for '${p.update.id}' changed before archive could retire them.`\n                    );\n                  }\n                  mutationAttempts.add(p.update.target);\n                },\n                verifyDisplaced: async (displacedPath) => {","sourceCodeStart":1758,"sourceCodeEnd":1794,"githubUrl":"https://github.com/Fission-AI/OpenSpec/blob/6926ccb18afa4ff621112813e9968334576ee11a/src/core/archive.ts#L1758-L1794","documentation":"Error \"The ${METADATA_FILENAME} retirement authorization is unavailable.\" thrown in Fission-AI/OpenSpec.","triggerScenarios":"Thrown at src/core/archive.ts:1776 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"6926ccb18afa4ff621112813e9968334576ee11a","analyzedAt":"2026-08-25T12:29:45.729Z","schemaVersion":2},"datasetVersion":"2026-08-25T16:17:27.014Z"}