After using Selenium on macOS, Chrome isn't the same - macos

I installed selenium and used a python program to run chrome using selenium on my MacBook Air. Before there was an error on selenium, and after installing googlechrome drivers for selenium and creating a PATH using terminal, it opened a separate google chrome page that showed Chrome is being controlled by automated test software.
After around 30 minutes of running python and using selenium, I saved and closed out of everything.
In the next 2 minutes, I reopened Google Chrome to search something about web scraping, and the browser was the same one used by selenium. It still showed the Chrome is being controlled by automated test software notice, and there was a Chrome Automation Extension.
I tried:
logging in and syncing, but syncing was not available.
opening Google Chrome from application folder and dock, but nothing changed
deleting Google Chrome and reinstalling, but nothing changed
I don't know how to fix this. Can anyone help me?
Thanks in advance!

Ok, so I found out that the chromedriver was still running in the background. After I closed it using activity monitor, the problem was solved.

Related

VS Code keeps opening code in Chromium instead of Chrome

I'm trying to open my live server in Chrome but it keeps defaulting to Chromium, no idea why or where it even pulls it from since I only have chrome installed.
Chromium was working at first but it doesn't seem to handle CSS-grid and I need that now.

Firefox won't play iMacros via URL?

For the last week or so I've been developing an application to programmatically maintain some stuff online, to do so I need to launch iMacros from Firefox via Python.
Currently I am doing that in Python with this code, it has worked fine for a week:
firefoxpath = '"C:/Program Files (x86)/Mozilla Firefox//firefox.exe"'
macroCommand = firefoxpath + " imacros://run/?m=" + path_to_macro
subprocess.Popen(macroCommand)
There is some other stuff that cleans up processes in there and listens for errors too, but all that really matters right now is launching the macros
Today, after this worked for several hours of coding. I started getting this popup when attempting to launch via Python. (It's the popup Firefox gives when it doesn't know how to handle a file or URL).
Launch Application Popup:
It would seem that Firefox no longer thinks it can launch imacros files directly. However, the files play just find if you click "play" in the iMacros panel.
I've been troubleshooting for an hour and it doesn't seem like anyone online has had this problem before. Any ideas?
UPDATE:
I managed to get this working by completely reinstalling windows on the problem machine. Before doing that, I reinstalled firefox a number of times, tried a portable copy of firefox, deleted firefox's registry entries, disabled multi-process windows in FF, uninstalled all plugins one by one, and tried the same thing as a different user (both with and without admin).
None of that worked, if anyone in the future encounters this bug I recommend just reinstalling windows on the problem machine.
I was using
Windows 10
Firefox 54
iMacros for FF 9.0.3
Python 2.7
God speed to anyone else who encounters this.

How to open browsers in private/incognito mode with selenium?

I'm writing Selenium tests in Ruby to test my website in multiple browsers.
However, the tests won't fire correctly unless the cookies are clear(there are triggers I'm testing that only happen X number of times and is stored in a cookie).
Does anyone know how to have selenium open a browser in its private browsing or incognito mode with Selenium or have another idea on how I might solve the issue?
You can get Chrome to start in incognito by default.
There's a solution for Windows at the bottom of the link below... If you're not using Windows, you can Google how to achieve this for you OS =)
https://productforums.google.com/forum/#!topic/chrome/sYaZkNW8II4

Selenium-webdriver Firefox issue windows 7

I am running Selenium Webdriver locally on my windows home server (windows 7 professional actually) which logs to a site and sends some emails. It's a java program with a single thread running.
I can see Firefox opening up just fine when running through Eclipse and follow the clicks etc as it logs on without problems.
I have set up a Task Scheduler task to start it up every morning though and run the jar. The program runs fine but when Firefox opens it is almost invisible, I can see the grey frames of it but everything else is transparent and invisible and if you drag something in front of it the graphics get stuck.
When clicking on Properties on Task manager I can see that it started with firefox.exe - foreground whereas when I open Firefox normally it says -browser.
The program still does what it should do, it's just Firefox is not visible at all when running through java -jar X.jar etc.
Any ideas why?
Windows 7 Professional
WebDriver 2.32
Firefox 21
I suspect it has something to do with the anonymous Firefox Profiles created each time firefox runs. I usually delete them from Temp once a week.
P.S No idea if it matters but server is headless and I am accessing it through TeamViewer.
Issue solved by deleting firefox profiles and loading from scratch. Weird, not sure yet what caused this and if it happens again.
Perhaps I will create a specific firefox profile and use instead of a anonymous one created each time.

Selenium Server on CentOS 6.2 has no keyboard input while testing

We currently have a problem with SeleniumServer which is troubling me for 2 days, now...hope you can help me.
The Selenium Server is running on a CentOS 6.2, Selenium Server is 2.21 and Firefox is 10.0.4.
When a test is starting up, SeleniumServer launches Firefox but he can not type anything in the form fields or press "Enter" to submit.
Even better, no one (not even me with VNC-Server) can write something in the form field, url bar, menus, press a key like "Enter", etc....it is as the keyboard is not present... It´s like Firefox is locked somehow.
If a start Firefox with Interactive-Mode : selenium-server.jar -interactive & cmd=getNewBrowserSession&1=*firefox&2=http://www.google.com everything is working fine, I can do all the tests manually.
I can also start firefox manually with just typing firefox in the shell and that is working fine, too.
So what is going on in Selenium and how does Selenium starts Firefox? Why is no Keyboard-Input available when running a Selenium-Test with SeleniumServer?
We tested with MacOS and Windows, too and both working fine with the same test.
Any idea would be appreciated.
Greetings from Berlin
Fixed it myself with an older version of Firefox. Firefox 7 worked for me.

Resources