Skip to content

fix: upgrade agentdb dependency from v2 to v3 (broken exports)#126

Open
a-man-gupta wants to merge 1 commit intoruvnet:mainfrom
a-man-gupta:fix/agentdb-exports-upgrade-v3
Open

fix: upgrade agentdb dependency from v2 to v3 (broken exports)#126
a-man-gupta wants to merge 1 commit intoruvnet:mainfrom
a-man-gupta:fix/agentdb-exports-upgrade-v3

Conversation

@a-man-gupta
Copy link

Summary

  • Upgrades agentdb from ^2.0.0-alpha.3.6 to ^3.0.0-alpha.3 in root package.json
  • The v2 line (2.0.0-alpha.3.7) has 18 broken exports in its package.json — all ./controllers/* and ./cli paths point to ./dist/controllers/ but the TypeScript build outputs to ./dist/src/controllers/
  • The v3 line (3.0.0-alpha.3+, already published to npm) has the correct exports map

Problem

Every consumer of agentic-flow that transitively imports agentdb/controllers hits:

[AgentDB Patch] Controller index not found: node_modules/agentdb/dist/controllers/index.js

Broken paths in agentdb v2 (2.0.0-alpha.3.7)

Export Points to (wrong) Actual file (correct)
./controllers ./dist/controllers/index.js ./dist/src/controllers/index.js
./controllers/HNSWIndex ./dist/controllers/HNSWIndex.js ./dist/src/controllers/HNSWIndex.js
... 16 more ./dist/controllers/* ./dist/src/controllers/*
./cli ./dist/cli/agentdb-cli.js ./dist/src/cli/agentdb-cli.js

Already fixed in agentdb v3 (packages/agentdb/package.json on main)

All exports correctly use ./dist/src/controllers/ paths.

Test plan

  • npm install resolves agentdb@^3.0.0-alpha.3 (latest: 3.0.0-alpha.10)
  • node -e "import('agentdb/controllers')" succeeds without errors
  • All 27 exports in agentdb v3 resolve to existing files
  • No runtime regressions in swarm/memory/hooks commands

🤖 Generated with claude-flow

The v2 line (^2.0.0-alpha.3.6 resolving to 2.0.0-alpha.3.7) has broken
package.json exports — 18 controller and CLI export paths point to
./dist/controllers/ but the actual build output is at ./dist/src/controllers/.

This causes runtime errors:
  [AgentDB Patch] Controller index not found: node_modules/agentdb/dist/controllers/index.js

The v3 line (3.0.0-alpha.3+) already has the correct exports map with all
paths pointing to ./dist/src/. No further v2 patches are planned.

Co-Authored-By: claude-flow <ruv@ruv.net>
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