You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When trying to start storybook, I'm getting this error:
Error: spawn UNKNOWN at ChildProcess.spawn (node:internal/child_process:412:11) at Object.spawn (node:child_process:698:9) at module.exports (C:\Users\{User}\Downloads\{react-project-name}\node_modules\better-opn\node_modules\open\index.js:175:34) { errno: -4094, code: 'UNKNOWN', syscall: 'spawn' }
After a bit of debugging, I came to know that System32/WindowsPowerShell/v1.0/powershell.exe is blocked by my organization,
which this library is clearly trying to access:
FYI: system does allow Powershell (x86) to open through SysWOW64\WindowsPowerShell\v1.0
Can we add some conditions in command variable to check whether the system is x64-based or not ?
The text was updated successfully, but these errors were encountered:
…rs on Windows (#23287)
# Why
Fixes#23252
# How
- `open` has a bug on Windows, where it [uses
`process.env.SYSTEMROOT`](https://github.com/sindresorhus/open/blob/main/index.js#L173)
instead of
[`process.env.SystemRoot`](https://en.wikipedia.org/wiki/Environment_variable#:~:text=The%20%25SystemRoot%25%20variable%20is%20a,including%20the%20drive%20and%20path.)
- This causes the executed command to run with `undefined\\...`
- There has been no fix yet, and due to `open` being fully ESM now, we
probably can't upgrade too
> See various issues
[#300](sindresorhus/open#300),
[#292](sindresorhus/open#292),
[#270](sindresorhus/open#270), or
[#205](sindresorhus/open#205)
This basically sets the missing `SYSTEMROOT` when trying to open a
browser on Windows. It's fixed in both `@expo/cli` as well as
`@expo/dev-server` (to open the Chrome DevTools).
# Test Plan
This has to be tested on Windows.
- `$ yarn create expo ./test-browser -t tabs@beta`
- `$ cd ./test-browser`
- `$ yarn start`
- Try pressing the following keys:
- `j` -> to open the Chrome DevTools, after connecting a device. Should
work as expected.
- `w` -> to open the browser with Metro web. Should work as expected.
# Checklist
<!--
Please check the appropriate items below if they apply to your diff.
This is required for changes to Expo modules.
-->
- [ ] Documentation is up to date to reflect these changes (eg:
https://docs.expo.dev and README.md).
- [ ] Conforms with the [Documentation Writing Style
Guide](https://github.com/expo/expo/blob/main/guides/Expo%20Documentation%20Writing%20Style%20Guide.md)
- [ ] This diff will work correctly for `npx expo prebuild` & EAS Build
(eg: updated a module plugin).
---------
Co-authored-by: Expo Bot <34669131+expo-bot@users.noreply.github.com>
…rs on Windows (#23287)
# Why
Fixes#23252
# How
- `open` has a bug on Windows, where it [uses
`process.env.SYSTEMROOT`](https://github.com/sindresorhus/open/blob/main/index.js#L173)
instead of
[`process.env.SystemRoot`](https://en.wikipedia.org/wiki/Environment_variable#:~:text=The%20%25SystemRoot%25%20variable%20is%20a,including%20the%20drive%20and%20path.)
- This causes the executed command to run with `undefined\\...`
- There has been no fix yet, and due to `open` being fully ESM now, we
probably can't upgrade too
> See various issues
[#300](sindresorhus/open#300),
[#292](sindresorhus/open#292),
[#270](sindresorhus/open#270), or
[#205](sindresorhus/open#205)
This basically sets the missing `SYSTEMROOT` when trying to open a
browser on Windows. It's fixed in both `@expo/cli` as well as
`@expo/dev-server` (to open the Chrome DevTools).
# Test Plan
This has to be tested on Windows.
- `$ yarn create expo ./test-browser -t tabs@beta`
- `$ cd ./test-browser`
- `$ yarn start`
- Try pressing the following keys:
- `j` -> to open the Chrome DevTools, after connecting a device. Should
work as expected.
- `w` -> to open the browser with Metro web. Should work as expected.
# Checklist
<!--
Please check the appropriate items below if they apply to your diff.
This is required for changes to Expo modules.
-->
- [ ] Documentation is up to date to reflect these changes (eg:
https://docs.expo.dev and README.md).
- [ ] Conforms with the [Documentation Writing Style
Guide](https://github.com/expo/expo/blob/main/guides/Expo%20Documentation%20Writing%20Style%20Guide.md)
- [ ] This diff will work correctly for `npx expo prebuild` & EAS Build
(eg: updated a module plugin).
---------
Co-authored-by: Expo Bot <34669131+expo-bot@users.noreply.github.com>
When trying to start storybook, I'm getting this error:
Error: spawn UNKNOWN at ChildProcess.spawn (node:internal/child_process:412:11) at Object.spawn (node:child_process:698:9) at module.exports (C:\Users\{User}\Downloads\{react-project-name}\node_modules\better-opn\node_modules\open\index.js:175:34) { errno: -4094, code: 'UNKNOWN', syscall: 'spawn' }
After a bit of debugging, I came to know that
System32/WindowsPowerShell/v1.0/powershell.exe
is blocked by my organization,which this library is clearly trying to access:
FYI: system does allow Powershell (x86) to open through
SysWOW64\WindowsPowerShell\v1.0
Can we add some conditions in
command
variable to check whether the system is x64-based or not ?The text was updated successfully, but these errors were encountered: