[Python] Selenium takes time to load the first page

Discussão em 'Python' iniciado por Stack, Março 5, 2025.

  1. Stack

    Stack Membro Participativo

    With the following simple script, I'm trying to load a web page using Selenium on MacOS :

    from selenium import webdriver

    service = webdriver.firefox.service.Service('/Path to geckodriver', port=56009)
    driver = webdriver.Firefox(service=service)


    Firefox launches correctly, but takes about 2 minutes to load the first page. After that, I can navigate normally.

    What I tried:

    • use Chrome driver
    • use a downloaded geckodriver instead of the one given by Selenium
    • add a port number
    • simply launch firefox without doing any “get” afterwards

    Unfortunately, the problem remains.

    Thank you very much for your help

    Continue reading...

Compartilhe esta Página