-
Notifications
You must be signed in to change notification settings - Fork 835
fix: add postinstall script to fix node-pty spawn-helper permissions on macOS #294
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from 1 commit
05dee7e
1b90ff2
e388764
b67bc03
34cf343
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -319,6 +319,29 @@ We welcome contributions! Please follow these guidelines: | |
|
|
||
| ### Common Issues & Solutions | ||
|
|
||
| #### Shell/Terminal Fails with "posix_spawnp failed" (macOS) | ||
| **Problem**: When clicking "Continue in Shell" or starting a terminal session, you see: | ||
| ``` | ||
| Error: posix_spawnp failed. | ||
| ``` | ||
| With a stack trace referencing `node-pty/lib/unixTerminal.js`. | ||
|
|
||
| **Cause**: The `node-pty` package's `spawn-helper` binary may be missing execute permissions after installation. This commonly happens on macOS when: | ||
| - Installing via `npx` or `pnpm` | ||
| - The npm tarball doesn't preserve the execute bit | ||
|
Comment on lines
+331
to
+333
|
||
|
|
||
| **Solution**: Run this command from the project root (or global install location): | ||
| ```bash | ||
| chmod +x node_modules/node-pty/prebuilds/darwin-*/spawn-helper | ||
| ``` | ||
|
|
||
| For Intel Macs, the path is `darwin-x64`. For Apple Silicon (M1/M2/M3), it's `darwin-arm64`. | ||
|
|
||
| **Permanent Fix**: This project includes a `postinstall` script that automatically fixes permissions. If you still encounter the issue: | ||
| 1. Delete `node_modules` and reinstall: `rm -r node_modules && npm install` | ||
amacsmith marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| 2. Verify the fix: `ls -la node_modules/node-pty/prebuilds/darwin-*/spawn-helper` (should show `-rwxr-xr-x`) | ||
|
|
||
| **Related Issues**: [#284](https://github.com/siteboon/claudecodeui/issues/284) | ||
|
|
||
| #### "No Claude projects found" | ||
| **Problem**: The UI shows no projects or empty project list | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.