Open wangyizhuo opened 3 years ago
See the discussion starting here: https://github.com/wbyoung/avn/issues/105#issuecomment-660847541
PR welcome.
I can confirm this critical bug on Ubuntu 20.04.1 LTS with avn
0.2.4 and nvm
0.37.0 (latest).
nvm use default --latest-npm
Now using node v14.15.0 (npm v6.14.8)
avn setup
avn: profile already set up (~/.bash_profile)
avn: profile already set up (~/.zshrc)
/home/redtux/.nvm/versions/node/v14.15.0/lib/node_modules/avn/node_modules/npm/node_modules/graceful-fs/polyfills.js:267
if (cb) cb.apply(this, arguments)
^
TypeError: cb.apply is not a function
at /home/redtux/.nvm/versions/node/v14.15.0/lib/node_modules/avn/node_modules/npm/node_modules/graceful-fs/polyfills.js:267:18
at FSReqCallback.oncomplete (fs.js:184:5)
With node
v10.23.0 it works.
nvm use lts/dubnium --latest-npm
Now using node v10.23.0 (npm v6.14.8)
avn setup
avn: profile already set up (~/.zshrc)
avn: profile already set up (~/.bash_profile)
avn: configuration complete (~/.avnrc)kipping project config: /home/redtux/.npmrc. (matches userconfig)
avn-nvm: installation complete
avn-n: installation complete
PS: Not volunteering for a PR or patch, just for information. :heart:
Any updates on this? I'm still getting this exact error now, running:
@andfaulkner I may have mentioned on other issues that I haven't really worked on this for quite some time. It'd actually be good to find someone interested in maintaining it. But at this point, no progress on this particular issue, but any PR would be welcome.
I'm using n
and I fixed it with:
cd ~/.avn
n auto
(this installed node v4.0)cd && rm -R ~/.avn
npm install -g avn avn-nvm avn-n
avn setup
To get it working with nvm this is what I did.
avn
requires nodejs v4 to run sensibly, this is key.
cd ~/
nvm install 4
npm install -g avn avn-nvm avn-n
avn setup
nvm use default
cd <your project directory>
Please describe your issue clearly and also include all details below.
Details
avn --version
0.2.4node --version
v12.19.0nvm --version
0.35.3n --version
n/azsh --version
zsh 5.8 (x86_64-apple-darwin19.3.0)bash --version
n/aSteps to reproduce
Output
nvm specific
nvm
user I am confirming that I did not install with Homebrew