forcedotcom / lwc-dev-server-feedback

LWC Local Development
BSD 3-Clause "New" or "Revised" License
45 stars 10 forks source link

Ventura installation not working (EACCES) #153

Open dschibster opened 1 year ago

dschibster commented 1 year ago

Describe the bug Trying to install the lwc-dev-server plugin using sfdx, I am running into errors with yarn or node-gyp, not 100% precise on what it actually is. If I follow the stack traces correctly, it would come down to EACCES, which at first was limited to a yarn.lock file which didn't even exist (?), and now focuses on something else entirely.

I'm well aware that this probably a local issue. I have also tried all troubleshooting steps suggested in other forums, but would appreciate any and all help to troubleshoot this.

To Reproduce I have tried to run both sfdx plugins:install @salesforce/lwc-dev-server and yarn add @salesforce/lwc-dev-server@latest --non-interactive --mutex=file:/Users/username/.local/share/sfdx/yarn.lock --preferred-cache-folder=/Users/username/Library/Caches/sfdx/yarn --check-files.

Expected behavior Plugin installation should throw warnings, but no errors that prevent the install from going through.

Desktop (please complete the following information):

Stack traces

This is the stack trace I receive when running sfdx plugins:install

Installing plugin @salesforce/lwc-dev-server... ⣯ [4/4] Building fresh packages...
error /Users/username/.local/share/sfdx/node_modules/fibers: Command failed.
Exit code: 127
Command: node build.js || nodejs build.js
Arguments: 
Directory: /Users/username/.local/share/sfdx/node_modules/fibers
Output:
gyp info it worked if it ends with ok
gyp info using node-gyp@9.3.1
gyp info using node@19.8.1 | darwin | arm64
gyp info find Python using Python version 3.10.5 found at "/Library/Frameworks/Python.framework/Versions/3.10/bin/python3"
gyp info spawn /Library/Frameworks/Python.framework/Versions/3.10/bin/python3
gyp info spawn args [
gyp info spawn args   '/opt/homebrew/Cellar/node/19.8.1/libexec/lib/node_modules/npm/node_modules/node-gyp/gyp/gyp_main.py',
gyp info spawn args   'binding.gyp',
gyp info spawn args   '-f',
gyp info spawn args   'make',
gyp info spawn args   '-I',
gyp info spawn args   '/Users/username/.local/share/sfdx/node_modules/fibers/build/config.gypi',
gyp info spawn args   '-I',
gyp info spawn args   '/opt/homebrew/Cellar/node/19.8.1/libexec/lib/node_modules/npm/node_modules/node-gyp/addon.gypi',
gyp info spawn args   '-I',
gyp info spawn args   '/Users/username/Library/Caches/node-gyp/19.8.1/include/node/common.gypi',
gyp info spawn args   '-Dlibrary=shared_library',
gyp info spawn args   '-Dvisibility=default',
gyp info spawn args   '-Dnode_root_dir=/Users/username/Library/Caches/node-gyp/19.8.1',
gyp info spawn args   '-Dnode_gyp_dir=/opt/homebrew/Cellar/node/19.8.1/libexec/lib/node_modules/npm/node_modules/node-gyp',
gyp info spawn args   '-Dnode_lib_file=/Users/username/Library/Caches/node-gyp/19.8.1/<(target_arch)/node.lib',
gyp info spawn args   '-Dmodule_root_dir=/Users/username/.local/share/sfdx/node_modules/fibers',
gyp info spawn args   '-Dnode_engine=v8',
gyp info spawn args   '--depth=.',
gyp info spawn args   '--no-parallel',
gyp info spawn args   '--generator-output',
gyp info spawn args   'build',
gyp info spawn args   '-Goutput_dir=.'
gyp info spawn args ]
gyp info spawn make
gyp info spawn args [ 'BUILDTYPE=Release', '-C', 'build' ]
  CXX(target) Release/obj.target/fibers/src/fibers.o
../src/fibers.cc:27:65: error: no member named 'kFinalizer' in 'v8::WeakCallbackType'
                handle.SetWeak(val, WeakCallbackShim<F, P>, WeakCallbackType::kFinalizer);
                                                            ~~~~~~~~~~~~~~~~~~^
1 error generated.
make: *** [Release/obj.target/fibers/src/fibers.o] Error 1
gyp ERR! build error 
gyp ERR! stack Error: `make` failed with exit code: 2
gyp ERR! stack     at ChildProcess.onExit (/opt/homebrew/Cellar/node/19.8.1/libexec/lib/node_modules/npm/node_modules/node-gyp/lib/build.js:203:23)
gyp ERR! stack     at ChildProcess.emit (node:events:512:28)
gyp ERR! stack     at ChildProcess._handle.onexit (node:internal/child_process:293:12)
gyp ERR! System Darwin 22.4.0
gyp ERR! command "/opt/homebrew/Cellar/node/19.8.1/bin/node" "/opt/homebrew/Cellar/node/19.8.1/libexec/lib/node_modules/npm/node_modules/node-gyp/bin/node-gyp.js" "rebuild" "--release"
gyp ERR! cwd /Users/username/.local/share/sfdx/node_modules/fibers
gyp ERR! node -v v19.8.1
gyp ERR! node-gyp -v v9.3.1
gyp ERR! not ok 
node-gyp exited with code: 1
Please make sure you are using a supported platform and node version. If you
would like to compile fibers on this machine please make sure you have setup your
build environment--
Windows + OS X instructions here: https://github.com/nodejs/node-gyp
Ubuntu users please run: `sudo apt-get install g++ build-essential`
RHEL users please run: `yum install gcc-c++` and `yum groupinstall 'Development Tools'` 
Alpine users please run: `sudo apk add python make g++`
Installing plugin @salesforce/lwc-dev-server... failed
    Error: yarn add @salesforce/lwc-dev-server@latest --non-interactive 
    --mutex=file:/Users/username/.local/share/sfdx/yarn.lock 
    --preferred-cache-folder=/Users/username/Library/Caches/sfdx/yarn --check-files exited with code 127

I tried running the yarn command separately, and also tried going verbose. I have received this as the final message when going verbose:

verbose 29.613947167 Error: EACCES: permission denied, unlink '/Users/username/.local/share/sfdx/node_modules/.bin/adler32' which doesn't look like anything to me.

stale[bot] commented 1 year ago

This issue has been automatically marked as type:bug-p3 because it has not had recent activity.