RIDE can't find firefox geckodriver while running screen-test

84 Views Asked by At

I have a 'hello world' test to open a browser using firefox. The test runs fine on the commandline ($ robot hai_world.robot). But it fails when I run the test in RIDE. It reports: WebDriverException: Message: 'geckodriver' executable needs to be in PATH. Does RIDE have its own PATH-setting? It runs on ubuntu 20.04 in RIDE v2.0b1 on Python 3.8.10

1

There are 1 best solutions below

1
Helio On

Because your geckodriver is in a location defined in PATH only for your user, RIDE does not know of this when started from the shortcut.

I see (at least) two options to fix this:

  • Create a link to geckodriver in a global PATH location, for example:

    sudo ln -s /home/hobijn/.local/share/WebDriverManager/bin/geckodriver /usr/local/bin/geckodriver

  • Modify the launcher script of RIDE to have PATH updated:

    export PATH=$PATH:/home/hobijn/.local/share/WebDriverManager/bin ; python3 -m robotide.__init__ $*