Fonctionnement Selenium avec Firefox

-
Bonjour, j'aurais besoin d'aide concernant un petit projet que je fais. Voilà, je suis entrain d'essayer de relier mon poste vers un Selenium Grid qui se trouve en Docker sur une VM. J'ai réussi à faire cette liaison mais je n'arrive pas a lancer un test simple pour Firefox en python. Quelqu'un aurait-il déjà vécu ce genre de problème ?



Commande pour Gecko + Selenium :
java -Dwebdriver.gecko.driver="C:\Users\Desktop\Flavien\Travail\PiloterFire&ChromDist\Firefox\gecko0.25.0\geckodriver.exe -b "C:\Users\Downloads\FirefoxPortable_57.0_En\FirefoxPortable\FirefoxPortable.exe" --host=monip --port=5566" -jar "C:\Users\Desktop\Flavien\Travail\PiloterFire&ChromDist\Firefox\selenium-server-standalone-3.141.59.jar" -role webdriver -hub http://ipgrid:4444/grid/register -port 5566



Test python :
from time import sleep
from selenium import webdriver
from selenium.webdriver.common.desired_capabilities import DesiredCapabilities

driver = webdriver.Remote(
        desired_capabilities=DesiredCapabilities.FIREFOX,
        command_executor="http://<ital>ipgrid</ital>:4444/wd/hub")

print(driver)

sleep(2)

driver.quit()




erreur :
Traceback (most recent call last):
File "C:\Users\Desktop\Flavien\Travail\PiloterFire&ChromDist\firefox_monPoste.py", line 7, in <module>
command_executor="http://ipgrid:4444/wd/hub")
File "C:\Users\AppData\Local\Programs\Python\Python37\lib\site-packages\selenium-3.141.0-py3.7.egg\selenium\webdriver\remote\webdriver.py", line 157, in __init__
self.start_session(capabilities, browser_profile)
File "C:\Users\AppData\Local\Programs\Python\Python37\lib\site-packages\selenium-3.141.0-py3.7.egg\selenium\webdriver\remote\webdriver.py", line 252, in start_session
response = self.execute(Command.NEW_SESSION, parameters)
File "C:\Users\AppData\Local\Programs\Python\Python37\lib\site-packages\selenium-3.141.0-py3.7.egg\selenium\webdriver\remote\webdriver.py", line 321, in execute
self.error_handler.check_response(response)
File "C:\Users\AppData\Local\Programs\Python\Python37\lib\site-packages\selenium-3.141.0-py3.7.egg\selenium\webdriver\remote\errorhandler.py", line 242, in check_response
raise exception_class(message, screen, stacktrace)
selenium.common.exceptions.SessionNotCreatedException: Message: Unable to create new service: GeckoDriverService
Build info: version: '3.141.59', revision: 'e82be7d358', time: '2018-11-14T08:25:53'
System info: host: 'Flavien', ip: 'monip', os.name: 'Windows 10', os.arch: 'amd64', os.version: '10.0', java.version: '1.8.0_221'
Driver info: driver.version: unknown
Stacktrace:
at org.openqa.selenium.grid.session.remote.ServicedSession$Factory.lambda$get$0 (ServicedSession.java:135)
at org.openqa.selenium.grid.session.remote.ServicedSession$Factory.apply (ServicedSession.java:152)
at org.openqa.selenium.remote.server.ActiveSessionFactory.lambda$apply$12 (ActiveSessionFactory.java:180)
at java.util.stream.ReferencePipeline$3$1.accept (ReferencePipeline.java:193)
at java.util.stream.ReferencePipeline$11$1.accept (ReferencePipeline.java:373)
at java.util.stream.ReferencePipeline$2$1.accept (ReferencePipeline.java:175)
at java.util.Spliterators$ArraySpliterator.tryAdvance (Spliterators.java:958)
at java.util.stream.ReferencePipeline.forEachWithCancel (ReferencePipeline.java:126)
at java.util.stream.AbstractPipeline.copyIntoWithCancel (AbstractPipeline.java:499)
at java.util.stream.AbstractPipeline.copyInto (AbstractPipeline.java:486)
at java.util.stream.AbstractPipeline.wrapAndCopyInto (AbstractPipeline.java:472)
at java.util.stream.FindOps$FindOp.evaluateSequential (FindOps.java:152)
at java.util.stream.AbstractPipeline.evaluate (AbstractPipeline.java:234)
at java.util.stream.ReferencePipeline.findFirst (ReferencePipeline.java:464)
at org.openqa.selenium.remote.server.ActiveSessionFactory.apply (ActiveSessionFactory.java:183)
at org.openqa.selenium.remote.server.NewSessionPipeline.lambda$null$2 (NewSessionPipeline.java:66)
at java.util.stream.ReferencePipeline$3$1.accept (ReferencePipeline.java:193)
at java.util.stream.ReferencePipeline$2$1.accept (ReferencePipeline.java:175)
at java.util.Collections$2.tryAdvance (Collections.java:4719)
at java.util.stream.ReferencePipeline.forEachWithCancel (ReferencePipeline.java:126)
at java.util.stream.AbstractPipeline.copyIntoWithCancel (AbstractPipeline.java:499)
at java.util.stream.AbstractPipeline.copyInto (AbstractPipeline.java:486)
at java.util.stream.AbstractPipeline.wrapAndCopyInto (AbstractPipeline.java:472)
at java.util.stream.FindOps$FindOp.evaluateSequential (FindOps.java:152)
at java.util.stream.AbstractPipeline.evaluate (AbstractPipeline.java:234)
at java.util.stream.ReferencePipeline.findFirst (ReferencePipeline.java:464)
at org.openqa.selenium.remote.server.NewSessionPipeline.lambda$createNewSession$3 (NewSessionPipeline.java:69)
at java.util.stream.ReferencePipeline$3$1.accept (ReferencePipeline.java:193)
at java.util.stream.ReferencePipeline$3$1.accept (ReferencePipeline.java:193)
at java.util.stream.ReferencePipeline$3$1.accept (ReferencePipeline.java:193)
at java.util.stream.DistinctOps$1$2.accept (DistinctOps.java:175)
at java.util.stream.ReferencePipeline$2$1.accept (ReferencePipeline.java:175)
at java.util.stream.ReferencePipeline$3$1.accept (ReferencePipeline.java:193)
at java.util.stream.ReferencePipeline$2$1.accept (ReferencePipeline.java:175)
at java.util.stream.Streams$StreamBuilderImpl.tryAdvance (Streams.java:405)
at java.util.stream.Streams$ConcatSpliterator.tryAdvance (Streams.java:728)
at java.util.stream.ReferencePipeline.forEachWithCancel (ReferencePipeline.java:126)
at java.util.stream.AbstractPipeline.copyIntoWithCancel (AbstractPipeline.java:499)
at java.util.stream.AbstractPipeline.copyInto (AbstractPipeline.java:486)
at java.util.stream.AbstractPipeline.wrapAndCopyInto (AbstractPipeline.java:472)
at java.util.stream.FindOps$FindOp.evaluateSequential (FindOps.java:152)
at java.util.stream.AbstractPipeline.evaluate (AbstractPipeline.java:234)
at java.util.stream.ReferencePipeline.findFirst (ReferencePipeline.java:464)
at org.openqa.selenium.remote.server.NewSessionPipeline.createNewSession (NewSessionPipeline.java:72)
at org.openqa.selenium.remote.server.commandhandler.BeginSession.execute (BeginSession.java:65)
at org.openqa.selenium.remote.server.WebDriverServlet.lambda$handle$0 (WebDriverServlet.java:235)
at java.util.concurrent.Executors$RunnableAdapter.call (Executors.java:511)
at java.util.concurrent.FutureTask.run (FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker (ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run (ThreadPoolExecutor.java:624)
at java.lang.Thread.run (Thread.java:748)
Afficher la suite