Questions tagged [firefox-headless]

44 questions
0
votes
1 answer

I get black screen when i record the headless selenium driver with xvfb and ffmpeg

xvfb-run --listen-tcp --server-num 44 -s "-ac -screen 0 1920x1080x24" mvn clean test & export DISPLAY=:44 ffmpeg -f x11grab -video_size 1920x1080 -i :44 -codec:v libx264 -r 12 video.mp4 This is the bash script i am using to run the selenium test…
Saran Raj
  • 86
  • 4
0
votes
1 answer

Error with puppeteer with alpine Docker in chromium headless

I'm trying to use pageres in my bash script for grabbing screenshot in heruko. But running pageres with alpine:latest throws error with puppeteer. Error: Failed to launch the browser process! [0318/133905.228580:FATAL:setuid_sandbox_host.cc(158)]…
0
votes
1 answer

Copy Paste not working with headless browser in python selenium

I am using selenium with python to click a button on a webpage. This copies data in csv format on to the clipboard. Then I use the data on clipboard to create an array, which is used further in the program. Everything works fine until I start the…
0
votes
1 answer

using selenium to run Firefox in headless mode error: 'Options' object has no attribute 'binary'

I just started using selenium and wanted to check the status of a ps5 at Walmart but I get the error 'Options' object has no attribute 'binary' it worked fine before I tried to run it in headless mode. from selenium import webdriver from…
0
votes
1 answer

Pycharm evaluate expression and actual execution are different

I am using the code from this topic to try and get the HTML of a website, using a headless browser. Here is my full code: from selenium import webdriver from selenium.webdriver.firefox.options import Options from…
AvivLevi815
  • 37
  • 11
0
votes
1 answer

Python-Selenium: Clipboard functionality (ctrl + c) not working in Firefox headless mode

I am using ActionChains functions in firefox headless mode, but it is not working. I have this scrolling div code_scroll = driver.find_element_by_class_name('CodeMirror-scroll') I want to double click inside this div and then copy/paste the whole…
0
votes
1 answer

Selenium Firefox Python running in headless mode Timeout on initializing driver

Firefox version: 60.9.0esr (32-bit) Selenium version: 3.141.0 Geckodriver version: 0.24.0 (32-bit) So everything currently works in non-headless mode. But I need to run this python script in a GUI-less linux server (thus need headless mode). For…
0
votes
1 answer

Memory increasing when webdriver running for long time using Selenium java

I am using selenium java to do web page scraping, basically the app creates a WebDriver and use it all the times for all pages required(every 1 or 2 seconds it will do a get() call for a new page and extract the related content). I am using Firefox…
0
votes
1 answer

Is it required to set the DISPLAY for headless firefox browser on linux machine

I want to run the headless browser and below is the code for same. However when i ran it. it shows "Error: no DISPLAY environment variable specified" try { FirefoxProfile profile = new FirefoxProfile(); profile.setPreference("webdriver.log.driver",…
J.vik
  • 103
  • 2
  • 11
0
votes
2 answers

java.net.ConnectException: Failed to connect to localhost/127.0.0.1:xxxx while invoking Firefox browser in Headless mode

I am getting a "java.net.ConnectException: Failed to connect to localhost" error whenever I try to initialize the FirefoxDriver. Any Help? Code and Stack Trace Below: Java Code firefoxBinary = new…
Michela Dennis
  • 101
  • 1
  • 10
0
votes
1 answer

Improve scrapy and selenium with firefox in headless mode

I am scraping a javascript heavy site and I have setup a vagrant instance to check the feasibility ( 1GB RAM ). The system crashes after parsing few urls. I am unable to determine memory requirements for this setup and reason for the crash. However…
sakhunzai
  • 13,900
  • 23
  • 98
  • 159
0
votes
1 answer

Firefox-38 is not working in headless mode on Amazon Linux-2015.03

I am trying to run firefox-38 on Amazon linux-2015.03 release in headless mode with salenium. But its giving me below error: (process:4919): GLib-CRITICAL **: g_slice_set_config: assertion `sys_page_size == 0' failed Error: no display specified I…
ramesh.mimit
  • 9,445
  • 4
  • 21
  • 23
-1
votes
1 answer

What is the correct way of running test cases(in headless firefox) in xvfb and record the test cases using ffmpeg

https://malinowski.dev/recording-headless-selenium-tests-to-mp4.html this is the link i am using but i don't even know how to do all these.I don't know whether i should run all the commands in that as a single script or should i run the xvfb command…
Saran Raj
  • 86
  • 4
-2
votes
1 answer

Firefox's headless screenshot doesn't work

I want to use headless firefox to capture an image of a webpage. In Linux, I use the command /usr/lib64 / firefox/firefox - headless - screenshot/opt/touchyoo/web/xylmweb/screenshot / 201909 / tes1.JPG http://www.baidu.com You can take screensaver…
1 2
3