Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

npm error while installing #2483

Closed
MaksSieve opened this issue May 29, 2019 · 12 comments
Closed

npm error while installing #2483

MaksSieve opened this issue May 29, 2019 · 12 comments
Labels

Comments

@MaksSieve
Copy link

MaksSieve commented May 29, 2019

I tried to install sitespeed to Mircosoft Ubuntu but has thi problem

npm ERR! tar.unpack unzip error /tmp/npm-4767-b5dcff7a/github.com/sitespeedio/selenium/archive/v3.6.0.tar.gz
npm WARN excluding symbolic link node_modules/.bin/_mocha -> ../mocha/bin/_mocha
npm WARN excluding symbolic link node_modules/.bin/he -> ../he/bin/he
npm WARN excluding symbolic link node_modules/.bin/jade -> ../jade/bin/jade
npm WARN excluding symbolic link node_modules/.bin/mime -> ../mime/cli.js
npm WARN excluding symbolic link node_modules/.bin/mkdirp -> ../mkdirp/bin/cmd.js
npm WARN excluding symbolic link node_modules/.bin/mocha -> ../mocha/bin/mocha
npm WARN excluding symbolic link node_modules/.bin/promises-aplus-tests -> ../promises-aplus-tests/lib/cli.js
npm WARN excluding symbolic link node_modules/.bin/rimraf -> ../rimraf/bin.js
npm ERR! Linux 4.4.0-17134-Microsoft
npm ERR! argv "/usr/bin/node" "/usr/bin/npm" "install"
npm ERR! node v8.10.0
npm ERR! npm  v3.5.2
npm ERR! code Z_BUF_ERROR
npm ERR! errno -5

npm ERR! unexpected end of file
npm ERR!
npm ERR! If you need help, you may report this error at:
npm ERR!     <https://github.com/npm/npm/issues>

npm ERR! Please include the following file with any support request:
npm ERR!     /home/msitnikov/sitespeed.io/npm-debug.log
@soulgalore
Copy link
Member

Hi @MaksSieve thanks for creating the issue. It seems to fail with the unpack. I think this shouldn't be a specific issue but need to look into it. Any help appreciated since I don't have a Windows machine.

Best
Peter

@drptbl
Copy link

drptbl commented May 31, 2019

@soulgalore Same issue here, inside official node docker image based on debian: node:10.16.0-stretch (+ yarn 1.16.0)

warning sitespeed.io > browsertime > [email protected]: critical bug fixed in v1.8.14 .format API returns UTC offset when value is 0
warning sitespeed.io > webcoach > browsertime > [email protected]: critical bug fixed in v1.8.14 .format API returns UTC offset when value is 0
warning sitespeed.io > webpagetest > mocha > [email protected]: Please use the native JSON object instead of JSON 3
info If you think this is a bug, please open a bug report with the information provided in "/usr/local/share/.config/yarn/global/yarn-error.log".
info Visit https://yarnpkg.com/en/docs/cli/global for documentation about this command.
error An unexpected error occurred: "https://github.com/sitespeedio/selenium/archive/v3.6.0.tar.gz: ENOENT: no such file or directory, open '/usr/local/share/.cache/yarn/v4/.tmp/8418edaec784cc447b4304fc2affe84b/.yarn-tarball.tgz'".

Issue occurs since [email protected].

Fix: downgrading to [email protected] fixes this issue.

@soulgalore
Copy link
Member

Hi @drptbl ah thanks for sharing, let me try reproduce then. Not sure right now though why it started to happen in 9.1.

Best
Peter

@soulgalore
Copy link
Member

Did some searching it seems like a problem that pops up for Yarn now and then, see yarnpkg/yarn#1834

The original problem why we have a hacked version of Selenium could be fixed: The NodeJS version released the alpha of Selenium 4 2018-01-13. That version is broken, I've made an upstream issue because it was broken when refactoring and I think the maintainer that broke it should fix it. So I branched the current 3.6 and added two new methods to talk to the devtools protocol for Chrome. That's why we have our own version. However: someparts in Chromedriver (that Selenium uses) is broken. When you get the trace log from Chrome, it doesn't use the "stop" command that says wait for all the traces that is needed for the navigation. So we also introduced another way of talking to CDP. So ... hehe ... I think since both npm and yarn sometimes has problem with getting the files correctly, we should just switch to the old 3.6 and then at the same time convert how we talk to the CDP inside of Browsertime to avoid using Selenium for that part. Yep that is probably the best longtime solution. I need to look into the code and see how much work that is.

@drptbl
Copy link

drptbl commented May 31, 2019

@soulgalore thanks a lot for looking in to this and for explanation.

Best Regards,
Jakub.

@soulgalore
Copy link
Member

I had a quick look, if everything works out, I'll release a fix on Saturday morning :)

@MaksSieve
Copy link
Author

MaksSieve commented May 31, 2019

@soulgalore thanks a lot for fast fix! everything works on Windows Ubuntu Subsytem!

@MaksSieve
Copy link
Author

@soulgalore but is there any way to run sitespeed on OS without gui?

@soulgalore
Copy link
Member

@MaksSieve not sure exactly how you mean? You mean headless? If you use the npm version you can add --headless and it will work. However then you will not get any video or video metrics. If you setup XVFB you can run "headless". The Docker version do that automatically.

@soulgalore
Copy link
Member

I just released 9.2.1 that should fix this.

@drptbl
Copy link

drptbl commented Jun 3, 2019

@soulgalore Just tested, everything works as expected in 9.2.1. Thanks for fast fix 🙂.

I think this issue can be closed now (OP also verified that it's fixed).

Best Regards,
Jakub.

@soulgalore
Copy link
Member

Great!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants