{"record":{"id":"0619f3e74d31408a","repo":"ruvnet/ruflo","slug":"unsupported-flywheel-anchor-manifest-schema-man","errorCode":null,"errorMessage":"unsupported flywheel anchor manifest schema: ${manifest.schemaVersion}","messagePattern":"unsupported flywheel anchor manifest schema: (.+?)","errorType":"validation","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"v3/@claude-flow/cli/src/services/harness-project-anchor.ts","lineNumber":159,"sourceCode":"  options: LoadFlywheelAnchorOptions = {},\n): FlywheelAnchorSelection {\n  const root = resolve(projectRoot);\n  if (!!options.anchorPath !== !!options.anchorHash) {\n    throw new Error('anchorPath and anchorHash must be supplied together');\n  }\n  if (options.anchorPath && options.anchorHash) {\n    return toSelection(containedPath(root, options.anchorPath), options.anchorHash);\n  }\n\n  const manifestCandidate = options.manifestPath ?? DEFAULT_PROJECT_ANCHOR_MANIFEST;\n  const manifestPath = isAbsolute(manifestCandidate)\n    ? manifestCandidate\n    : resolve(root, manifestCandidate);\n  if (existsSync(manifestPath)) {\n    const containedManifest = containedPath(root, manifestPath);\n    const manifest = JSON.parse(readFileSync(containedManifest, 'utf8')) as ProjectAnchorManifest;\n    if (manifest.schemaVersion !== PROJECT_ANCHOR_MANIFEST_SCHEMA) {\n      throw new Error(`unsupported flywheel anchor manifest schema: ${manifest.schemaVersion}`);\n    }\n    if (typeof manifest.path !== 'string' || typeof manifest.sha256 !== 'string') {\n      throw new Error('flywheel anchor manifest requires path and sha256');\n    }\n    // Manifest-relative paths are easier to relocate while remaining\n    // repository-contained; project-relative paths remain supported.\n    const manifestRelative = resolve(dirname(containedManifest), manifest.path);\n    const requested = existsSync(manifestRelative) ? manifestRelative : resolve(root, manifest.path);\n    return toSelection(containedPath(root, requested), manifest.sha256);\n  }\n\n  if (isRufloRepository(root) || process.env.RUFLO_FLYWHEEL_ALLOW_BUILTIN_ANCHOR === '1') {\n    const frozen = loadFrozenHumanEval();\n    return {\n      version: frozen.version,\n      anchorRef: FROZEN_HUMAN_EVAL_HASH,\n      source: 'ruflo-built-in',\n      tasks: frozen.tasks.map((task) => ({","sourceCodeStart":141,"sourceCodeEnd":177,"githubUrl":"https://github.com/ruvnet/ruflo/blob/6b01dc5a687b26b3e218f796de45ec51f8fa9e8c/v3/@claude-flow/cli/src/services/harness-project-anchor.ts#L141-L177","documentation":"Thrown when the manifest file (default .claude/eval/flywheel-anchor.manifest.json) exists and parses as JSON, but its schemaVersion field does not equal 'ruflo.flywheel-anchor-manifest/v1' (PROJECT_ANCHOR_MANIFEST_SCHEMA). Note this check is strict equality (no optionality) — unlike the task anchor's optional schemaVersion, the manifest REQUIRES the exact schema string. The manifest is the small pointer file that pins a path+sha256 to a tasks JSON.","triggerScenarios":"A manifest file is present but its schemaVersion is missing, misspelled, or from a different version (e.g. 'v2', 'ruflo.flywheel-anchor/v1' which is the TASK schema not the MANIFEST schema). A common confusion is putting the task-anchor schema constant into the manifest file.","commonSituations":"Hand-authoring a manifest and copying the wrong schema string (the task schema instead of the manifest schema); a doc example that used a placeholder; upgrading the library when the manifest schema constant changed.","solutions":["Set the manifest's schemaVersion to exactly \"ruflo.flywheel-anchor-manifest/v1\".","Double-check you are editing the MANIFEST file (.claude/eval/flywheel-anchor.manifest.json), not the TASKS file it points at — they use different schema constants.","Re-generate the manifest via the project scaffolding so the constant is written verbatim."],"exampleFix":"// before — .claude/eval/flywheel-anchor.manifest.json\n{ \"schemaVersion\": \"ruflo.flywheel-anchor/v1\", \"path\": \"tasks.json\", \"sha256\": \"sha256:...\" }\n// after — use the MANIFEST schema constant\n{ \"schemaVersion\": \"ruflo.flywheel-anchor-manifest/v1\", \"path\": \"tasks.json\", \"sha256\": \"sha256:...\" }","handlingStrategy":"validation","validationCode":"import { PROJECT_ANCHOR_MANIFEST_SCHEMA } from './harness-project-anchor.js';\nimport { readFileSync } from 'fs';\nfunction assertManifestSchema(path: string): void {\n  const m = JSON.parse(readFileSync(path, 'utf8'));\n  if (m.schemaVersion !== PROJECT_ANCHOR_MANIFEST_SCHEMA) {\n    throw new Error(`manifest schema ${m.schemaVersion} != ${PROJECT_ANCHOR_MANIFEST_SCHEMA}`);\n  }\n}","typeGuard":"function hasValidManifestSchema(manifest: unknown): boolean {\n  return typeof manifest === 'object' && manifest !== null\n    && (manifest as { schemaVersion?: unknown }).schemaVersion === 'ruflo.flywheel-anchor-manifest/v1';\n}","tryCatchPattern":"try {\n  loadEffectiveFlywheelAnchor(root, opts);\n} catch (e) {\n  if (e instanceof Error && /unsupported flywheel anchor manifest schema/.test(e.message)) {\n    // set manifest.schemaVersion to 'ruflo.flywheel-anchor-manifest/v1' (NOT the task schema)\n  }\n  throw e;\n}","preventionTips":["Distinguish the MANIFEST schema constant from the TASK schema constant — they differ.","Generate the manifest with the official scaffolding.","Validate the manifest in CI with a JSON-schema."],"tags":["flywheel-anchor","schema-validation","manifest","configuration","json"],"backgroundTag":null,"analyzedSha":"6b01dc5a687b26b3e218f796de45ec51f8fa9e8c","analyzedAt":"2026-08-12T13:20:50.148Z","schemaVersion":2},"datasetVersion":"2026-08-12T23:17:12.415Z"}