{"record":{"id":"bb91f0297a04156c","repo":"Fission-AI/OpenSpec","slug":"rewrote-seen-of-totalhexliterals-64-hex-lite","errorCode":null,"errorMessage":"Rewrote ${seen} of ${totalHexLiterals} 64-hex literals in ${sourceLabel}.\nEvery one is assumed to be a pinned hash, so the two counts must agree. Either:\n  - a pinned hash is formatted in a way the patterns here do not match, and would have been left stale without warning: widen them; or\n  - the file gained a 64-hex literal that is not a pin: narrow the count above so it stops being mistaken for one.","messagePattern":"Rewrote (.+?) of (.+?) 64-hex literals in (.+?)\\.\nEvery one is assumed to be a pinned hash, so the two counts must agree\\. Either:\n  - a pinned hash is formatted in a way the patterns here do not match, and would have been left stale without warning: widen them; or\n  - the file gained a 64-hex literal that is not a pin: narrow the count above so it stops being mistaken for one\\.","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"scripts/parity-hash-shared.mjs","lineNumber":84,"sourceCode":"    }\n    if (next !== previous) moved.push(name);\n    seen += 1;\n    return `${indent}${name}: '${next}'${comma}`;\n  });\n\n  rewritten = rewritten.replace(CONTENT_PIN, (_match, indent, dirName, previous, comma) => {\n    const next = resolveContentHash(dirName);\n    if (next === undefined) {\n      throw new Error(`'${dirName}' is pinned in the parity test but not returned by getSkillTemplates()`);\n    }\n    if (next !== previous) moved.push(dirName);\n    seenContentKeys.add(dirName);\n    seen += 1;\n    return `${indent}'${dirName}': '${next}'${comma}`;\n  });\n\n  if (seen !== totalHexLiterals) {\n    throw new Error(\n      `Rewrote ${seen} of ${totalHexLiterals} 64-hex literals in ${sourceLabel}.\\n` +\n        'Every one is assumed to be a pinned hash, so the two counts must agree. Either:\\n' +\n        '  - a pinned hash is formatted in a way the patterns here do not match, and ' +\n        'would have been left stale without warning: widen them; or\\n' +\n        '  - the file gained a 64-hex literal that is not a pin: narrow the count above ' +\n        'so it stops being mistaken for one.'\n    );\n  }\n\n  // The checks above only see pins that exist. A workflow added to the registry\n  // but never pinned is invisible to them AND to the parity test, which compares\n  // only the entries it already lists - so it would ship with no golden hash at\n  // all while this reported success. Compare the other direction too.\n  const unpinned = [...knownContentKeys].filter((key) => !seenContentKeys.has(key));\n  if (unpinned.length > 0) {\n    throw new Error(\n      `getSkillTemplates() returns ${unpinned.length} skill(s) with no pinned hash in ${sourceLabel}:\\n` +\n        unpinned.map((key) => `  ${key}`).join('\\n') +","sourceCodeStart":66,"sourceCodeEnd":102,"githubUrl":"https://github.com/Fission-AI/OpenSpec/blob/6926ccb18afa4ff621112813e9968334576ee11a/scripts/parity-hash-shared.mjs#L66-L102","documentation":"Error \"Rewrote ${seen} of ${totalHexLiterals} 64-hex literals in ${sourceLabel}.\nEvery one is assumed to be a pinned hash, so the two counts must agree. Either:\n  - a pinned hash is formatted in a way the patterns here do not match, and would have been left stale without warning: widen them; or\n  - the file gained a 64-hex literal that is not a pin: narrow the count above so it stops being mistaken for one.\" thrown in Fission-AI/OpenSpec.","triggerScenarios":"Thrown at scripts/parity-hash-shared.mjs:84 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"}