Title: `node --run` aborts on filesystem errors · Issue #67269 · nodejs/node · GitHub
Open Graph Title: `node --run` aborts on filesystem errors · Issue #67269 · nodejs/node
X Title: `node --run` aborts on filesystem errors · Issue #67269 · nodejs/node
Description: Version v28.0.0-pre Platform Darwin 25.6.0 arm64 Subsystem fs What steps will reproduce the bug? A node_modules directory in the project (or any parent) that cannot be read: mkdir -p proj && cd proj echo '{"scripts":{"hi":"echo hi"}}' > ...
Open Graph Description: Version v28.0.0-pre Platform Darwin 25.6.0 arm64 Subsystem fs What steps will reproduce the bug? A node_modules directory in the project (or any parent) that cannot be read: mkdir -p proj && cd pro...
X Description: Version v28.0.0-pre Platform Darwin 25.6.0 arm64 Subsystem fs What steps will reproduce the bug? A node_modules directory in the project (or any parent) that cannot be read: mkdir -p proj &&...
Opengraph URL: https://github.com/nodejs/node/issues/67269
X: @github
Domain: github.com
IPv4 address: 140.82.114.4
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"`node --run` aborts on filesystem errors","articleBody":"### Version\n\nv28.0.0-pre\n\n### Platform\n\n```text\nDarwin 25.6.0 arm64\n```\n\n### Subsystem\n\nfs\n\n### What steps will reproduce the bug?\n\n1. A `node_modules` directory in the project (or any parent) that cannot be read:\n\n```sh\nmkdir -p proj && cd proj\necho '{\"scripts\":{\"hi\":\"echo hi\"}}' > package.json\nmkdir node_modules && chmod 000 node_modules\nnode --run hi\n```\n\n2. The current working directory has been removed:\n\n```sh\nmkdir gone && cd gone && rmdir ../gone\nnode --run hi\n```\n\n### How often does it reproduce? Is there a required condition?\n\nAlways\n\n### What is the expected behavior? Why is that the expected behavior?\n\n1. The unreadable `node_modules/.bin` is skipped and the script runs, as it does when `node_modules` has no `.bin`.\n2. A regular error message and exit code 1, like the existing `Can't find package.json` error.\n\n\n### What do you see instead?\n\nThe process aborts with exit code 134:\n\n```\nlibc++abi: terminating due to uncaught exception of type std::__1::__fs::filesystem::filesystem_error: filesystem error: in posix_stat: failed to determine attributes for the specified path: Permission denied [\".../proj/node_modules/.bin\"]\n```\n\n```\nlibc++abi: terminating due to uncaught exception of type std::__1::__fs::filesystem::filesystem_error: filesystem error: in current_path: call to getcwd failed: No such file or directory\n```\n\n### Additional information\n\n_No response_","author":{"url":"https://github.com/jazelly","@type":"Person","name":"jazelly"},"datePublished":"2026-11-05T06:52:02Z","url":"https://github.com/nodejs/node/issues/67269"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:a2d121af-901b-6abf-84b6-8aad3df509e9 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | BFBC:48D18:9BFEEC:C94198:6B0631FE |
| html-safe-nonce | 06c6ffc08290fd685d17c89a196caa80d2a3eaacbbb4a30b58cf5d43d0d11784 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCRkJDOjQ4RDE4OjlCRkVFQzpDOTQxOTg6NkIwNjMxRkUiLCJ2aXNpdG9yX2lkIjoiMTQ2ODk1MzUyMjY2ODk1ODcwIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | c397a31d2f69c452b1de9db3a625aea7c462efdb09671e149f235728952d904a |
| hovercard-subject-tag | issue:6218334402 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/nodejs/node/67269/issue_layout |
| twitter:image | https://opengraph.githubassets.com/1ecc3334e737c00bad494c7f012e30d94f7a558e70a06c53b0cc86aaddffdd5a/nodejs/node/issues/67269 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/1ecc3334e737c00bad494c7f012e30d94f7a558e70a06c53b0cc86aaddffdd5a/nodejs/node/issues/67269 |
| og:image:alt | Version v28.0.0-pre Platform Darwin 25.6.0 arm64 Subsystem fs What steps will reproduce the bug? A node_modules directory in the project (or any parent) that cannot be read: mkdir -p proj && cd pro... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | jazelly |
| hostname | github.com |
| expected-hostname | github.com |
| None | c3584c853cd39700ecff6e2cf8364295ffdb5313e571046c41cd2479270f7df0 |
| turbo-cache-control | no-preview |
| go-import | github.com/nodejs/node git https://github.com/nodejs/node.git |
| octolytics-dimension-user_id | 9950313 |
| octolytics-dimension-user_login | nodejs |
| octolytics-dimension-repository_id | 27193779 |
| octolytics-dimension-repository_nwo | nodejs/node |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 27193779 |
| octolytics-dimension-repository_network_root_nwo | nodejs/node |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 9eb3bb1597d09170a5f282cd38ae376dee1a5ec1 |
| ui-target | canary-1 |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
| Server | github.com |
| Content-Type | text/html; charset=utf-8 |
| Cache-Control | max-age=0, private, must-revalidate |
Viewport: width=device-width