-
Notifications
You must be signed in to change notification settings - Fork 2
Closed
Labels
bugSomething isn't workingSomething isn't workingdogfoodFound during dogfoodingFound during dogfooding
Description
Found during dogfooding v2.5.0
Severity: Critical
Command: codegraph branch-compare main HEAD and import('@optave/codegraph')
Reproduction
npm init -y && npm install @optave/codegraph@2.5.0
npx codegraph branch-compare main HEAD
# ERR_MODULE_NOT_FOUND: Cannot find module '.../src/branch-compare.js'
node --input-type=module -e "import('@optave/codegraph').then(m => console.log(Object.keys(m))).catch(e => console.error(e.code))"
# ERR_MODULE_NOT_FOUNDExpected behavior
branch-compareshould either work or not be registered as a CLI commandimport('@optave/codegraph')should return the programmatic API without crashing
Actual behavior
branch-comparecrashes withERR_MODULE_NOT_FOUND— the filesrc/branch-compare.jsdoes not exist in the source repoimport('@optave/codegraph')crashes becausesrc/index.jsline 9 has a top-level re-export:export { branchCompareData, branchCompareMermaid } from './branch-compare.js'
The second issue is critical — it makes the entire programmatic API unusable.
Root cause
The branch-compare command was registered in cli.js and its exports added to index.js, but the implementation file src/branch-compare.js was never created/committed.
Suggested fix
Remove the branch-compare references from cli.js (lines 826–843) and index.js (line 9) until the implementation exists. The command definition in --help is misleading, and the index.js export makes the entire package unusable programmatically.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingdogfoodFound during dogfoodingFound during dogfooding