Skip to content

Worker connection fails on every plugin update #318

@somethingforheheda

Description

@somethingforheheda

Description

I'm experiencing two recurring errors with the claude-mem plugin:

  1. MCP server fails on every plugin update - Race condition with dependency installation
  2. Summary hook fails on every response - Database error after each assistant response

Both errors significantly disrupt the user experience.


Issue 1: MCP Server Fails on Plugin Update

Steps to Reproduce

  1. Have claude-mem plugin installed
  2. Plugin receives an update
  3. Start a new Claude Code session
  4. Check /plugin - MCP server shows "failed" status

Error Log

⚠️ Claude-Mem: First-Time Setup

Dependencies are installing in the background. This only happens once.

📦 Installing dependencies with Bun...
bun install v1.0.18 (36c316a2)
Resolving dependencies
Resolved, downloaded and extracted [837]
warn: incorrect peer dependency "[email protected]"
Saved lockfile
✅ Dependencies installed

Error: Worker service connection failed.

To restart the worker:

  1. Exit Claude Code completely
  2. Open Terminal
  3. Navigate to: ~/.claude/plugins/marketplaces/thedotmack
  4. Run: npm run worker:restart
  5. Restart Claude Code
    at Y (file:///Users//.claude/plugins/cache/thedotmack/claude-mem/7.2.1/scripts/context-hook.js:16:2617)
    at J (file:///Users//.claude/plugins/cache/thedotmack/claude-mem/7.2.1/scripts/context-hook.js:16:3225)
    at process.processTicksAndRejections (node:internal/process/task_queues:95:5)

Node.js v20.19.5

Impact

  • MCP server (claude-mem-search) remains in "failed" state
  • Memory search functionality unavailable for the entire session
  • Requires restart to recover
  • Happens on every plugin update

Issue 2: Summary Hook Fails on Every Response

Steps to Reproduce

  1. Start a Claude Code session
  2. Ask any question and receive a response
  3. Error appears after every assistant response

Error Log

Stop says: Plugin hook error: [2025-12-15 03:17:17.653] [ERROR] [HOOK ] ✗ Failed to generate summary {status=500}
{"error":"undefined is not an object (evaluating 'o.lastInsertRowid')"}
file:///Users//.claude/plugins/cache/thedotmack/claude-mem/7.0.11/scripts/summary-hook.js:20

Error: Failed to request summary from worker: 500 {"error":"undefined is not an object (evaluating 'o.lastInsertRowid')"}
at rt (file:///Users//.claude/plugins/cache/thedotmack/claude-mem/7.0.11/scripts/summary-hook.js:20:814)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async Socket.
(file:///Users//.claude/plugins/cache/thedotmack/claude-mem/7.0.11/scripts/summary-hook.js:20:1388)

Node.js v20.19.5

Impact

  • Error message appears after every response
  • Very disruptive to the reading experience
  • Appears to be a database-related error (lastInsertRowid suggests SQLite issue)

Environment

  • Plugin version: 7.2.1 (also saw 7.0.11 in error logs)
  • Node.js: v20.19.5
  • Bun: v1.0.18
  • Platform: macOS

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions