Skip to content

Create doctor bundles for corrupted graph databases#674

Merged
jununfly merged 1 commit into
mainfrom
codex/corrupted-doctor-bundle-v2
Jul 2, 2026
Merged

Create doctor bundles for corrupted graph databases#674
jununfly merged 1 commit into
mainfrom
codex/corrupted-doctor-bundle-v2

Conversation

@jununfly

@jununfly jununfly commented Jul 2, 2026

Copy link
Copy Markdown
Owner

Summary

Completes the roadmap-sliced loop for issue #671: doctor --bundle can now create a local diagnostic bundle even when .zcodegraph/zcodegraph.db is malformed.

  • Adds a corrupted-status fallback inside diagnostic bundle creation so the bundle path does not require opening the broken database.
  • Records replay-safe DB metadata: presence, size, mtime, sanitized open error, diagnostic record availability, graph health, and exact recovery commands.
  • Marks graph stats as unavailable with unavailableReason: "corrupted" and surfaces Graph health: corrupted in the bundle summary.
  • Adds regression coverage for the malformed DB path and privacy constraints.
  • Records the completed roadmap under docs/plans/2026-07-02-corrupted-doctor-bundle-v2-roadmap.*.
  • Adds an Unreleased changelog entry for [cli-status-doctor-semantics] 1-3-2 corrupted diagnostic bundle v2 #671.

Verification

  • npx vitest run __tests__/status-json.test.ts __tests__/rust-hybrid-doctor.test.ts
  • npm run build
  • git diff --check

All passed locally.

Boundaries

  • No release or publish work is included.
  • This does not auto-clean or rebuild corrupted indexes; it only creates a local diagnostic bundle and reports exact recovery commands.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant