Release v4.2.8: Critical bugfix for session ID handling

Critical bugfix release.

Problem:
- NOT NULL constraint violations prevented all observations/summaries from being stored
- Worker service could not store any data in database
- System was completely non-functional for new sessions

Root Cause:
- SessionStore.getSessionById() missing claude_session_id in SELECT query
- Worker received undefined for claude_session_id
- Caused database INSERT failures

Fix:
- Added claude_session_id to getSessionById SQL query
- Updated return type to include claude_session_id field
- Session ID now flows correctly: hook → database → worker → SDK

Impact:
- All observation and summary storage now works correctly
- System maintains session consistency throughout lifecycle
- Critical for proper functioning of memory compression

Version Changes:
- package.json: 4.2.7 → 4.2.8
- marketplace.json: 4.2.6 → 4.2.8
- CLAUDE.md: Updated version and added v4.2.8 changelog

Files Changed:
- package.json (version bump)
- .claude-plugin/marketplace.json (version bump)
- CLAUDE.md (version and changelog)
- src/services/sqlite/SessionStore.ts (bugfix)
- plugin/scripts/* (rebuilt with fix)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
Alex Newman
2025-10-24 22:20:07 -04:00
parent 81fdf28347
commit adc5853c73
4 changed files with 26 additions and 5 deletions
+1 -1
View File
@@ -10,7 +10,7 @@
"plugins": [
{
"name": "claude-mem",
"version": "4.2.6",
"version": "4.2.8",
"source": "./plugin",
"description": "Persistent memory system for Claude Code - context compression across sessions"
}
+23 -2
View File
@@ -4,7 +4,7 @@
Claude-mem is a persistent memory compression system that preserves context across Claude Code sessions. It automatically captures tool usage observations, processes them through the Claude Agent SDK, and makes summaries available to future sessions.
**Current Version**: 4.2.7
**Current Version**: 4.2.8
**License**: AGPL-3.0
**Author**: Alex Newman (@thedotmack)
@@ -210,7 +210,28 @@ npm run build && git commit -a -m "Build and update" && git push && cd ~/.claude
## Version History
### v4.2.7 (Current)
### v4.2.8 (Current)
**Breaking Changes**: None (patch version)
**Critical Bugfix**:
- Fixed NOT NULL constraint violation that prevented observations and summaries from being stored
- Root cause: `SessionStore.getSessionById()` was not selecting `claude_session_id` from database
- Worker service received `undefined` for `claude_session_id` when initializing sessions
- Result: Database inserts failed with "NOT NULL constraint failed: sdk_sessions.claude_session_id"
- Fix: Added `claude_session_id` to SELECT query and return type in `getSessionById()`
- Impact: Session ID from hooks now flows correctly: hook → database → worker → SDK agent
- Affects: All observation and summary storage operations
**Technical Details**:
- Updated `src/services/sqlite/SessionStore.ts:711` to include `claude_session_id` in SELECT
- Updated return type signature to include `claude_session_id: string` field
- Worker service now correctly receives and uses `claude_session_id` from database
- System maintains consistency throughout entire session lifecycle
**Files Changed**:
- `src/services/sqlite/SessionStore.ts` (getSessionById method)
### v4.2.7
**Breaking Changes**: None (patch version)
**Improvements**:
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "claude-mem",
"version": "4.2.7",
"version": "4.2.8",
"description": "Memory compression system for Claude Code - persist context across sessions",
"keywords": [
"claude",
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "claude-mem",
"version": "4.2.6",
"version": "4.2.8",
"description": "Persistent memory system for Claude Code - seamlessly preserve context across sessions",
"author": {
"name": "Alex Newman"