[Bug] Stop hook fails with ENOENT: posix_spawn /bin/sh in sandboxed context

Resolved 💬 2 comments Opened Feb 10, 2026 by aezizhu Closed Feb 10, 2026

Bug Description
The error is related to yourteammate mode setting. You have "teammateMode":
"tmux" configured in your settings, and the sto p hook is trying to use /bin/sh
via posix_spawn to run a tmux-related command.

Even though /bin/sh exists on your system, the issue is likely that the hook
is running in a sandboxed context where /bin/sh is not accessible. This is a
known behavior when Claude Code's sandbox can't reach the shell.

The error itself is non-blocking (it says "Failed with non-blocking status
code"), so it doesn't prevent anything from working — it's just a warning.

Environment Info

  • Platform: darwin
  • Terminal: tmux
  • Version: 2.1.38
  • Feedback ID: 9deb8742-3987-4459-a32c-d56554f65cbe

Errors

[{"error":"Error: ENOENT: no such file or directory, open '/Users/aezi/.claude/remote-settings.json'\n    at openSync (unknown)\n    at <anonymous> (/$bunfs/root/claude:12:947)\n    at AC (/$bunfs/root/claude:11:49917)\n    at readSync (/$bunfs/root/claude:12:875)\n    at BC (/$bunfs/root/claude:6131:113)\n    at J5 (/$bunfs/root/claude:6133:226)\n    at h9A (/$bunfs/root/claude:178:8273)\n    at S7R (/$bunfs/root/claude:178:8436)\n    at iUD (/$bunfs/root/claude:179:1202)\n    at eAT (/$bunfs/root/claude:179:2080)","timestamp":"2026-02-10T10:59:36.713Z"},{"error":"Error: NON-FATAL: Lock acquisition failed for /Users/aezi/.local/share/claude/versions/2.1.38 (expected in multi-process scenarios)\n    at QVR (/$bunfs/root/claude:3622:2098)\n    at yMA (/$bunfs/root/claude:3622:1209)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-02-10T10:59:36.772Z"},{"error":"Error: Failed to initialize LSP server plugin:kotlin-lsp:kotlin-lsp: LSP server 'plugin:kotlin-lsp:kotlin-lsp': startupTimeout is not yet implemented. Remove this field from the configuration.\n    at _ (/$bunfs/root/claude:2113:32616)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-02-10T10:59:41.857Z"},{"error":"Error: Failed to initialize LSP server plugin:jdtls-lsp:jdtls: LSP server 'plugin:jdtls-lsp:jdtls': startupTimeout is not yet implemented. Remove this field from the configuration.\n    at _ (/$bunfs/root/claude:2113:32616)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-02-10T10:59:41.860Z"},{"error":"Error: LSP server plugin:typescript-lsp:typescript failed to start: Executable not found in $PATH: \"typescript-language-server\"\n    at start (/$bunfs/root/claude:2113:22315)\n    at async H (/$bunfs/root/claude:2113:24763)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-02-10T10:59:41.861Z"},{"error":"Error: LSP server plugin:gopls-lsp:gopls failed to start: Executable not found in $PATH: \"gopls\"\n    at start (/$bunfs/root/claude:2113:22315)\n    at async H (/$bunfs/root/claude:2113:24763)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-02-10T10:59:41.861Z"},{"error":"Error: Executable not found in $PATH: \"typescript-language-server\"\n    at spawn (unknown)\n    at spawn (node:child_process:667:35)\n    at spawn (node:child_process:14:39)\n    at start (/$bunfs/root/claude:2113:20845)\n    at H (/$bunfs/root/claude:2113:24763)\n    at _ (/$bunfs/root/claude:2113:32525)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-02-10T10:59:41.861Z"},{"error":"Error: Executable not found in $PATH: \"gopls\"\n    at spawn (unknown)\n    at spawn (node:child_process:667:35)\n    at spawn (node:child_process:14:39)\n    at start (/$bunfs/root/claude:2113:20845)\n    at H (/$bunfs/root/claude:2113:24763)\n    at _ (/$bunfs/root/claude:2113:32525)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-02-10T10:59:41.861Z"},{"error":"Error: Failed to start LSP server plugin:typescript-lsp:typescript: Executable not found in $PATH: \"typescript-language-server\"\n    at <anonymous> (/$bunfs/root/claude:2113:32547)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-02-10T10:59:41.862Z"},{"error":"Error: Failed to start LSP server plugin:gopls-lsp:gopls: Executable not found in $PATH: \"gopls\"\n    at <anonymous> (/$bunfs/root/claude:2113:32547)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-02-10T10:59:41.862Z"}…

Note: Content was truncated.

View original on GitHub ↗

This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗