Database Error while closing connection
- Dominant language
- TypeScript
- Stars
- 72.7k
- Forks
- 8.6k
- Avg merge
- 2d 23h
- Merged PRs (30d)
- 83
Description
I am using claude-flow version 3 latest alpha version. after completing tasks if I close claude-flow command, or press Ctrl+C at that time getting below error message
/home/techseria/frappe-bench/node_modules/better-sqlite3/lib/methods/wrappers.js:5
return this[cppdb].prepare(sql, this, false);
^
TypeError: The database connection is not open
at Database.prepare (/home/techseria/frappe-bench/node_modules/better-sqlite3/lib/methods/wrappers.js:5:21)
at HiveMindSessionManager.removeChildPid (file:///home/techseria/frappe-bench/node_modules/claude-flow/src/cli/simple-commands/hive-mind/session-manager.js:932:29)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
Node.js v20.19.5
Contributor guide
Research direction
Start in src/cli/simple-commands/hive-mind/session-manager.js at HiveMindSessionManager.removeChildPid, around line 932, and trace the shutdown path triggered by closing claude-flow or pressing Ctrl+C. Reproduce the failure with the reported Node.js and better-sqlite3 setup. Done means shutdown completes without attempting to prepare a query on a closed database or emitting the TypeError.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- node.js, sqlite, typescript
- Domain
- cli, database
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100