Skip to content
This repository has been archived by the owner on Oct 30, 2020. It is now read-only.

Support modern browsers, not just PhantomJS #7

Open
bergie opened this issue Mar 6, 2016 · 6 comments
Open

Support modern browsers, not just PhantomJS #7

bergie opened this issue Mar 6, 2016 · 6 comments
Milestone

Comments

@bergie
Copy link
Member

bergie commented Mar 6, 2016

PhantomJS 2, uses WebKit 538.1, which was released in November 2013.
Significant improvements have been done in browsers in these 2+ years. Both in terms of performance, new HTML apis (not so relevant for us) and new language support (ES6/ES2015 etc).
Because Qt Project deprecated the QtWebkit they use in favor of Blink-based QtWebEngine, a more modern version would only come with (yet unplanned) PhantomJS 3 which would rewrite this...

The challenge is to have a headless setup suitable for running in production.

Alternatives

  • Chromium (Blink). Communicate through WebDriver/Selenium, or run-headless-chrome
  • Firefox (Gecko). Communicate through WebDriver/Selenium, or SlimerJS
  • Servo. Communicate/setup through??
    Fast but highly experiemental webengine, part of Mozilla's Rust project

Headless approaches

  • Get xfvb-run (virtual X11) to work on Heroku. Possible but not easy
  • Use some virtual/headless Wayland compositor instead of X11. Weston headless. But neither Firefox nor Chromium has good mainline support yet.
  • Use the native headless support in Servo
  • Maybe try Ozone headless support in Chromium Content Shell. Looks not very mature
  • Run Docker images with virtual X11. On Amazon AWS ECS or similar, instead of Heroku.
  • Build our own headless browser shell, for instance based on QtWebEngine or Chromium Embedding framework
  • Native headless backend for Firefox or for Chromium. Large undertaking

Related to #6

@jonnor jonnor changed the title Modern browser instead of PhantomJS Support modern browsers, not just PhantomJS Mar 7, 2016
@jonnor jonnor modified the milestone: 2.x Mar 8, 2016
@jonnor
Copy link
Member

jonnor commented Jun 5, 2016

Chromium headless looks to have been worked on actively the last couple of months. Instructions on how to build here: https://chromium.googlesource.com/chromium/src/+/master/headless/README.md

It will require a custom build Chromium for foreseeable future, since graphics backend is compile time choice and Linux builds use X11 or Wayland probably.

@jonnor
Copy link
Member

jonnor commented Jan 9, 2017

Looks like QtWebkit has been resurrected, with ES2015 etc coming to PhantomJS 2.5:
https://groups.google.com/forum/m/#!topic/phantomjs/AefOuwkgBh0

@bergie
Copy link
Member Author

bergie commented Apr 13, 2017

Chrome headless will be shipping in 59 for all platforms:

https://www.chromestatus.com/features/5678767817097216

@jonnor
Copy link
Member

jonnor commented Apr 13, 2017

And the PhantomJS maintainer stepped down, https://groups.google.com/forum/#!topic/phantomjs/9aI5d-LDuNE

@jonnor
Copy link
Member

jonnor commented Aug 16, 2017

Headless API for Chrome, by official Chrome team and using a standard binary build of Chrome: https://github.com/GoogleChrome/puppeteer

@jonnor
Copy link
Member

jonnor commented Aug 16, 2017

Some work is still going on in PhantomJS, moving towards a 2.5 release: ariya/phantomjs#14458

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

No branches or pull requests

2 participants