Questions tagged [firefox-headless]

44 questions
2
votes
1 answer

The right way to run Firefox in headless mode (Selenium, Python)

I was wondering how to run hidden Firefox window when testing a page in Selenium and came across this solution. It says that I can run Firefox in headless mode like this: from selenium import webdriver import os os.environ['MOZ_HEADLESS'] =…
ibodi
  • 1,543
  • 3
  • 21
  • 40
1
vote
2 answers

Selenium: AttributeError: 'Options' object has no attribute 'set_headless'

I'm wanting to write a python script using Selenium to scrape a website. Following along with the Real Python article on it, I literally copy and pasted the following code into a py file: from selenium.webdriver import Firefox from…
1
vote
1 answer

playwright - get content from multiple pages in parallel

I am trying to get the page content from multiple URLs using playwright in a nodejs application. My code looks like this: const getContent = async (url: string): Promise { const browser = await firefox.launch({ headless: true }); const…
chenny
  • 769
  • 2
  • 17
  • 44
1
vote
1 answer

Selenium browsing with headless isn't working?

I'm trying to use Selenium with a headless browser but when I run this code below it still opens the browser? from selenium import webdriver from selenium.webdriver.firefox.options import Options from selenium.webdriver.common.keys import Keys def…
PythonC
  • 39
  • 2
  • 7
1
vote
1 answer

Puppeteer/Playwright is it possible to set the browser visible when launching as headless

Is it possible to launch Playwright with headless set to true and then later while the browser is still running change headless to false? I could not find anything in the documentation.
user2341534
  • 435
  • 1
  • 4
  • 8
1
vote
2 answers

firefox-headless contol box is missing from screenshot - selenium - linux

I am facing exactly same problem https://github.com/mozilla/geckodriver/issues/1358. Firefox-headless mode screenshots taken from linux are missing input box Question: Do we have any alternative to solve this problem. I am using FF 83
1
vote
1 answer

How to make a headless browser mimic fully fledged browser to run an web application using selenium?

I have a case where the need is to run a web application in a headless browser [either Google Chrome/Mozilla Firefox] but when web application is launched from the headless browser using a selenium + browser driver, our web application treats it as…
1
vote
1 answer

How to add extension in firefox driver in Java using selenium

How to add extension in firefox driver in selenium in Java Have tried below possibilities. 1st tried Solution FirefoxOptions firefoxOptions = new FirefoxOptions(); FirefoxProfile profile = new FirefoxProfile(); profile.addExtension(new…
1
vote
1 answer

How to use headless driver in Python using Selenium

I have the below code from selenium.webdriver import Firefox from selenium.webdriver.firefox.options import Options opts = Options() opts.set_headless() assert opts.headless # Operating in headless mode browser =…
moys
  • 7,747
  • 2
  • 11
  • 42
1
vote
1 answer

Python ImportError after installing Buildpack on Heroku

I try to get Selenium Webdriver with headless Firefox to work on Heroku. I'm using Python 3.6.7 for that. I found out that I can use this buildpack https://github.com/joshuawu/firefox-buildpack for launching my app. So I installed it using Heroku…
1
vote
1 answer

Python Selenium:firefox headless option not working with Firefox 52.8.0 (32-bit)

I want to run firefox in headless mode on server but both options.add_argument("--headless") and options.set_headless(headless=True) are not working. from selenium import webdriver from selenium.webdriver.firefox.options import…
Manvi
  • 1,136
  • 2
  • 18
  • 41
1
vote
1 answer

Chrome Headless - Firefox

I'm working on a monitoring tool for my website to log data. The actual logging is made on server. My goal is to calculate stats based on how long the user stays on the website. Main question: I used chrome headless command…
1
vote
0 answers

Headless Firefox selenium browser

I have this multiCapabilities property in my protractor.conf.js file : multiCapabilities: [ { browserName: 'firefox', firefoxOptions: { args: ['--headless'] }, 'moz:firefoxOptions': { args: […
0
votes
0 answers

I am trying to setup gitlab cicd for webdriverio headless firefox but getting error

I am trying to setup gitlab cicd for firefox but getting error 'ERROR webdriver: Request failed with status 500 due to unknown error: Process unexpectedly closed with status 255' This is my gitlab yml contains: stages: - test webdriverio_chrome: …
0
votes
0 answers

"A content process crashed and MOZ_CRASHREPORTER_SHUTDOWN is set, shutting down" error when starting firefox in headless mode

I'm unable to run a test case which is open up a firefox browser in headless mode. [1674207423848 geckodriver INFO Listening on 127.0.0.1:1025 1674207424164 mozrunner::runner INFO Running command: "/opt/firefox/firefox" "--marionette"…