Medium / phantomjs

NPM wrapper for installing phantomjs
Other
1.42k stars 436 forks source link

Adding support for Phantom 2.5.0 beta #689

Open phawxby opened 7 years ago

phawxby commented 7 years ago

Also fixed the proxy env var to also use the standard env var.

668

phawxby commented 7 years ago

V2.1: 928f78fe-29b3-11e7-9f79-832af397bd0f

V2.5 beta: homepage--en-us--desktop

phawxby commented 7 years ago

Can they continue to use 2.1 until we figure that out? Overall feature support would be vastly improved switching to 2.5

On Tue, 25 Apr 2017, 15:45 Nick Santos, notifications@github.com wrote:

@nicks commented on this pull request.

In lib/util.js https://github.com/Medium/phantomjs/pull/689#discussion_r113215358:

@@ -98,17 +98,14 @@ function getDownloadSpec() { var platform = getTargetPlatform() var arch = getTargetArch() if (platform === 'linux' && arch === 'x64') {

  • downloadUrl += 'linux-x86_64.tar.bz2'
  • checksum = '86dd9a4bf4aee45f1a84c9f61cf1947c1d6dce9b9e8d2a907105da7852460d2f'
  • } else if (platform === 'linux' && arch == 'ia32') {
  • downloadUrl += 'linux-i686.tar.bz2'
  • checksum = '80e03cfeb22cc4dfe4e73b68ab81c9fdd7c78968cfd5358e6af33960464f15e3'
  • downloadUrl += 'beta-linux-ubuntu-trusty-x86_64.tar.gz'

this won't work, because not all linux distros are ubuntu trusty.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/Medium/phantomjs/pull/689#pullrequestreview-34585617, or mute the thread https://github.com/notifications/unsubscribe-auth/ABCkKuMlgYmPcsWWsugKEBB2cbYw2JDuks5rzgb0gaJpZM4NHktg .

nicks commented 7 years ago

That works in a world where no one has dependencies on anyone else. In the world we live in, there are transitive dependencies, and anyone who upgraded would break linux users downstream, which we would then have to support.

If you'd like to try 2.5 for your own purposes, you're free to create a new, separate npm package that just installs 2.5

phawxby commented 7 years ago

@nicks Just testing an update to better handle Linux, would this be any better?

phawxby commented 7 years ago

@nicks you'll have to forgive me on my poor knowledge of Linux. I've now got this working on Ubuntu however it has an OS dependency on libhyphen-dev libwebp-dev gcc-4.9 g++-4.9. What's the best way to signal this dependency to consumers or correct it during install?

nicks commented 7 years ago

ugh : (

There is no good way to signal these dependencies downstream. NPM doesn't have a good mechanism for this.

just to make sure we're on the same page, are you aware that PhantomJS 2.5 might never come out of beta? https://groups.google.com/forum/#!topic/phantomjs/9aI5d-LDuNE

This is why we haven't pushed out a 2.5 installer - I don't want to push a bunch of compatibility/upgrade work onto downstream packages that ends up being a waste of their time.

phawxby commented 7 years ago

Ugh 2, i had missed that announcement. It's a shame the repo is split between github, bitbucket and Google groups.

Well I'm not sure what to do with this PR then.

I'm guessing something like webdriver.io would be a the way forward for new projects or is there a direct integration for Casper into chrome headless?

tommedema commented 6 years ago

@phawxby try https://github.com/LucianoGanga/simple-headless-chrome