Skip to content

v2.1.1 — Bug fixes

Latest

Choose a tag to compare

@just-cameron just-cameron released this 30 Mar 22:08

Bug Fixes

SDK worker silently fails on macOS/Linux (#42)

spawnSilentWorker() used npx tsx on macOS/Linux, which resolved to a globally cached tsx instance that couldn't find @letta-ai/letta-code-sdk in the plugin's node_modules. Transcripts were never sent to the agent — Sub appeared to work but never received updates.

Fix: Use the plugin's local tsx CLI (node_modules/tsx/dist/cli.mjs) directly via process.execPath, same pattern Windows already used. Falls back to npx if local CLI not found.

session_start crashes when /dev/tty unavailable (#41)

fs.createWriteStream('/dev/tty') returns synchronously but emits ENXIO asynchronously when /dev/tty doesn't exist (non-interactive terminals, certain Linux configurations). Without an error handler, Node crashes the process.

Fix: Added .on('error', () => { tty = null }) handler.

Partial workaround for CLAUDE_PLUGIN_ROOT on Linux (#34)

On Linux with marketplace-installed plugins, CLAUDE_PLUGIN_ROOT may not be set by the Claude Code hooks framework, causing all hooks to fail with "Cannot find module '/hooks/silent-npx.cjs'".

Fix: Two layers of defense:

  • hooks.json now uses ${CLAUDE_PLUGIN_ROOT:-.} (shell default fallback to cwd)
  • silent-npx.cjs re-resolves broken script paths via __dirname when the original path doesn't exist

Note: This is primarily a Claude Code framework bug. The workaround helps when the cwd happens to be the plugin directory, or when silent-npx.cjs is found but the script paths are broken.

Written by Cameron ◯ Letta Code