QXcbConnection: Could not connect to display
PhantomJS has crashed. Please read the bug reporting guide at
http://phantomjs.org/bug-reporting.html and file a bug report.
[1] 7365 abort phantomjs
from Ubuntu 16.04
can anyone confirm?
Happening here too. Ubuntu 16.04
@fabiancabau @pixiuPL
the steps I used are as follows:
wget https://bitbucket.org/ariya/phantomjs/downloads/phantomjs-2.1.1-linux-x86_64.tar.bz2
bzip2 -d phantomjs-2.1.1-linux-x86_64.tar.bz2
tar -xvf phantomjs-2.1.1-linux-x86_64.tar
cp phantomjs-2.1.1-linux-x86_64/bin/phantomjs /usr/bin/phantomjs
@xhh110 @fabiancabau fix:: use code below to run phantomjs: QT_QPA_PLATFORM=offscreen phantomjs <js-file>. Or for good export QT_QPA_PLATFORM=offscreen, than log out, than back in and use PJS as normal afterwards. Any better now?
For what it's worth I was also having this issue, and setting QT_QPA_PLATFORM worked for me, for phantomjs installed through the ubuntu system package manager. When installing via the tar download, PJS actually complained about that setting (saying the only valid setting was 'phantom', but unsetting that env var worked also). Thanks
@pixiuPL following worked:
export QT_QPA_PLATFORM=offscreen
Thanks..!!!
@betacanis yes Im well awarwe of this. In fact its been merged in one of previous PR (cant remember exactly in which one), but current stable version (2.1.3) have it hardcoded for sure. It works (at least in my dev environment => Ubuntu 16.4 Server/Xeon 3,2GHz/8GB RAM).
@xhh110 Awesome ! Thanks bro
@pixiuPL How to install 2.1.3 source code
Most helpful comment
@fabiancabau @pixiuPL
the steps I used are as follows:
wget https://bitbucket.org/ariya/phantomjs/downloads/phantomjs-2.1.1-linux-x86_64.tar.bz2
bzip2 -d phantomjs-2.1.1-linux-x86_64.tar.bz2
tar -xvf phantomjs-2.1.1-linux-x86_64.tar
cp phantomjs-2.1.1-linux-x86_64/bin/phantomjs /usr/bin/phantomjs