Coder Social home page Coder Social logo

Comments (5)

parmegv avatar parmegv commented on August 15, 2024

selenium/webdriver/firefox/webdriver.py, line 67 asks the firefox binary to find its path.

_get_firefox_start_cmd() in FirefoxBinary, in the specific case of linux, looks for "firefox" in the PATH.

from tor-browser-selenium.

parmegv avatar parmegv commented on August 15, 2024

The problem is that in _get_firefox_start_cmd() it is assumed that self._start_cmd is not valid.
In our case, it is and it should return its value.

So a small patch like this in that function makes it work:
if isinstance(self._start_cmd, basestring): return self._start_cmd

from tor-browser-selenium.

gunesacar avatar gunesacar commented on August 15, 2024

Thanks @parmegv, for the test and the analysis.

Just for the record, it seems this is due to a Selenium issue and doesn't affect the our tests at the moment.

But we may run into problems when we have Marionette tests as Selenium will try to use the system Firefox binary instead of the modified binary in the TBB folder. It's a good idea to make sure we run the modified Firefox binary from TBB, not the one installed on the system.

from tor-browser-selenium.

psivesely avatar psivesely commented on August 15, 2024

More specifically the problem is that they run the this seemingly pointless test in this line. It's seemingly pointless because self.binary is supposed to be a FirefoxBinary object and not a basestring or str object; therefore, it will always fail. If you look at line 57 in that same file you can see that you can skip that whole mess by initializing an Options object and passing it to the call super(TorBrowserDiver, self).__init__ in the __init__ method of the TorBrowserDriver object we're initializing. If that didn't quite follow, see this commit where I've implemented the workaround.

The problem with this, at least for me working in the Ubuntu 14.04 server Docker image built from this repo is that TBB is not self-contained, so now it's failing because certain libraries libxul.so (the main Firefox library) is wanting to load are not present on this minimal image. But, that's a whole different and much easier to diagnose problem... PR incoming!

from tor-browser-selenium.

gunesacar avatar gunesacar commented on August 15, 2024

so now it's failing because certain libraries libxul.so (the main Firefox library) is wanting to load are not present on this minimal image.

That's interesting! These libraries are present in TBB's Browser directory but can't be loaded, right?

Do you think this implies that in normal (non-minimal) boxes we load libxul.so and other libs from the system, but not the ones shipped with TBB? This can be serious issue.

from tor-browser-selenium.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.