Skip to content

Add rgit doctor to diagnose corrupt or inconsistent .rgit stores #13

Description

@KumamuKuma

research-git currently has no dedicated store health diagnostic command. When .rgit/graph.db or .rgit/objects/ becomes inconsistent, the failure only appears later through unrelated commands.

Examples observed:

  • rgit doctor is not registered today.
  • Missing proposal diff objects can surface as FileNotFoundError from rgit pending --json.
  • Malformed proposal candidate JSON can surface as JSONDecodeError.
  • Missing feature payload objects can crash rgit features.
  • Missing run artifacts are only reported from rgit provenance.
  • Dangling edges can be inserted with rgit edges --add.
  • One-sided symmetric edges can make graph output misleading.

This makes support and bug reporting harder, because users cannot run a single command to inspect whether the durable .rgit memory store is healthy.

I have already submitted a companion PR to add a read-only rgit doctor command that checks schema metadata, object references, proposal JSON, dangling edges, and symmetric edge invariants: #12. Please help review the fix.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    Priority

    None yet

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions