Run Firefox in Backend using Selenium webdriver in Python?

PyVirtualDisplay should let you run it in the background.

Up vote 1 down vote favorite share g+ share fb share tw.

I am working on a website scraping project using Selenium in Python. I am wondering if I can start the firefox in the backend or open Firefox in another workspace in Ubuntu? Is it also possible to pass the user-agent properties though the webdriver()?

Thanks python selenium webdriver web-scraping user-agent link|improve this question asked Nov 28 '11 at 15:45Kiran Chandrashekhar804517 71% accept rate.

PyVirtualDisplay should let you run it in the background. There's a short walkthough here. And yes, you can change the User Agent.

Amazing, Haven't tried the User-Agent part as yet. But your suggestion of PyVirtualDisplay is what I was looking for. Thanks for your time and help.

– Kiran Chandrashekhar Nov 28 '11 at 22:46.

If you're using Gnome you might want to try DevilsPie (or gDevilsPie) to control on which workspace Firefox runs: A simple RAW rule would be: ( if ( begin ( is ( application_name ) "Firefox" ) ) ( begin ( set_workspace 3 ) ( println "match" ) ) ) I use this with Selenium and it works quite well.

Thanks a lot, I will try this. Running Firefox as a background application is not possible then with?ebdriver()? – Kiran Chandrashekhar Nov 28 '11 at 16:17.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions