Skip to content

Continuity causes Node segfaults on Linux (sqlite-vec / vec0) #7

@davidrobertson

Description

@davidrobertson

My agent and I have been working through several issues today when trying to implement your plugins. The biggest being a continuity bug causing the gateway to crash.

Environment
Linux x64, containerized (Unraid environment)
Node.js 22.x
OpenClaw gateway running with plugin allowlist + explicit plugins.load.paths

Continuity: kernel-level Node segfault (native crash)
Symptoms
With Continuity enabled, the gateway intermittently segfaults (kernel log shows segfault ... in node).
User-visible effect: sometimes the web UI shows the response but Discord never receives it (gateway dies mid-send).
Disabling Continuity stops the segfaults immediately.

Likely crash surface
Continuity uses native components:
better-sqlite3 native addon (better_sqlite3.node)
sqlite-vec which loads a native SQLite extension (vec0.so) via db.loadExtension(getLoadablePath())

This looks like a native compatibility / unsafe invocation problem, not a JS exception. A config conflict (memory settings, etc.) would not crash node at the kernel level.

Additional signal: empty-query search calls
We saw Continuity logging search calls like:
Search: intent=false, len=0, query=""
If Continuity is calling into sqlite-vec / vector query paths with an empty query (or similar edge-case), that might be triggering undefined behavior in native code.

Repro steps (Continuity segfault)

  1. Enable Continuity in OpenClaw plugin config (plugins.entries.continuity.enabled = true)
  2. Restart gateway
  3. Ask multiple “old memory” / archive search type questions
  4. Observe intermittent gateway crashes: kernel log shows segfault in node
  5. Disable continuity → crashes stop

Side note: Documentation makes mention of a "Recalled Memories" section in AGENTS.md, but details of what should be added are not specified anywhere

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions