Commit 3757bf2
Fix remaining lsof crashes in sandbox environments
Added isInSandbox() helper to mcp-server/app/mcp/tools.ts and
wrapped all lsof-dependent code paths to skip in sandbox:
- restart_dev_server MCP tool now returns error in sandbox
- killPortProcess functions in dev-environment.ts skip lsof
The lsof utility doesn't exist in Vercel Sandbox, Docker containers,
and other constrained environments.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>1 parent 92bf8ea commit 3757bf2
2 files changed
+37
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
12 | 25 | | |
13 | 26 | | |
14 | 27 | | |
| |||
3902 | 3915 | | |
3903 | 3916 | | |
3904 | 3917 | | |
| 3918 | + | |
| 3919 | + | |
| 3920 | + | |
| 3921 | + | |
| 3922 | + | |
| 3923 | + | |
| 3924 | + | |
| 3925 | + | |
| 3926 | + | |
| 3927 | + | |
| 3928 | + | |
| 3929 | + | |
| 3930 | + | |
3905 | 3931 | | |
3906 | 3932 | | |
3907 | 3933 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2406 | 2406 | | |
2407 | 2407 | | |
2408 | 2408 | | |
2409 | | - | |
| 2409 | + | |
2410 | 2410 | | |
| 2411 | + | |
| 2412 | + | |
| 2413 | + | |
| 2414 | + | |
2411 | 2415 | | |
2412 | 2416 | | |
2413 | 2417 | | |
| |||
2605 | 2609 | | |
2606 | 2610 | | |
2607 | 2611 | | |
2608 | | - | |
| 2612 | + | |
2609 | 2613 | | |
| 2614 | + | |
| 2615 | + | |
| 2616 | + | |
| 2617 | + | |
| 2618 | + | |
2610 | 2619 | | |
2611 | 2620 | | |
2612 | 2621 | | |
| |||
0 commit comments