node-gyp를 install 하는 중 아래와 같이 에러가 발생했다,,, 좀 이전의 버전과 의존성이 있었고 현재 기준 python 버전(3.11.*)과 호환이 되지 않는 문제가 있는 듯했다. (rU 폴더의 이름이 바뀌었던지,,,)
ValueError: invalid mode: 'rU' while trying to load binding.gyp
gyp ERR! configure error
gyp ERR! stack Error: `gyp` failed with exit code: 1
gyp ERR! stack at ChildProcess.onCpExit
...
다행히 해결방법을 어렵게 찾지 않아 쉽게 해결했다.
참고:
Node gyp ERR - invalid mode: 'rU' while trying to load binding.gyp
Getting the following error when running yarn install gyp/bin/node-gyp.js clean configure gyp info it worked if it ends with ok gyp info using node-gyp@5.1.1 gyp info using node@16.18.1 | darwin | ...
stackoverflow.com
ValueError: invalid mode: 'rU' while trying to load binding.gyp (Python 3.9 compatibility issue) · Issue #2219 · nodejs/node-g
Node Version: 13.7.0 Platform: Windows Module: binding.gyp Verbose output (from npm or node-gyp): gyp info it worked if it ends with ok gyp verb cli [ gyp verb cli 'C:\\Program Files\\nodejs\\node....
github.com
현재기준 최신 버전인 pyhton v3.11 버전을 python v3.9 버전으로 downgrading 해서 해결했다. v3.10 까지는 이러한 이슈가 발생하지 않는 것으로 보인다.
하지만 또 다른 이슈가 생겼다... 그건 다른 글에서!
[이슈해결] env: python: No such file or directory (macOS m1)
node-gyp를 install 중 python 버전의 호환성 문제가 있어서 그 부분은 버전을 낮춰 해결은 했으나,,, python을 찾지 못하는 이슈가 또 발생했다. env: python: No such file or directory make: *** [Release/libffi.a] Error 12
jangbageum.tistory.com