#1099792 chromium 134.0.6998.35-1~deb12u1 into stable-security has broken python3-selenium on bookworm

#1099792#5
Date:
2025-03-08 09:07:24 UTC
From:
To:
Hi,
there was a recent upload

[2025-03-06] Accepted chromium 134.0.6998.35-1~deb12u1 (source amd64 all) into stable-security (Debian FTP Masters) (signed by: Andres Salomon)

to stable-security which upgraded chromium from 133 to 134. Unfortunately, it
seems that such an upgrade has broken python3-selenium, which hasn't been
upgraded in stable since 4.8.3+dfsg-1, March 2023.

Now when using python3-selenium I get
========
Traceback (most recent call last):
  File "", line , in setUp
    self.selenium = webdriver.Chrome(options=chrome_options)
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/selenium/webdriver/chrome/webdriver.py", line 80, in __init__
    super().__init__(
  File "/usr/lib/python3/dist-packages/selenium/webdriver/chromium/webdriver.py", line 104, in __init__
    super().__init__(
  File "/usr/lib/python3/dist-packages/selenium/webdriver/remote/webdriver.py", line 286, in __init__
    self.start_session(capabilities, browser_profile)
  File "/usr/lib/python3/dist-packages/selenium/webdriver/remote/webdriver.py", line 378, in start_session
    response = self.execute(Command.NEW_SESSION, parameters)
               ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3/dist-packages/selenium/webdriver/remote/webdriver.py", line 440, in execute
    self.error_handler.check_response(response)
  File "/usr/lib/python3/dist-packages/selenium/webdriver/remote/errorhandler.py", line 245, in check_response
    raise exception_class(message, screen, stacktrace)
selenium.common.exceptions.SessionNotCreatedException: Message: session not created
from unknown error: cannot find Chrome binary
=========
while, on the same set up, on March 3 I wasn't getting any error, which to me
suggests that the issue is caused by the upgrade from 133 to 134.

While the bug is due to an upload to stable-security, this isn't reporting a security
issue per se, rather a usability one.

How can a working python3-selenium be restored for bookworm users?

Thanks,
Francesco

#1099792#14
Date:
2025-03-08 09:42:12 UTC
From:
To:
Hello Francesco,

Am 08.03.25 um 11:07 schrieb Francesco Ballarin:

I'd say it's more the other way around.
The current version of python3-selenium isn't compatible any more with
the version of Chromium and also with Firefox. So it's not that the
update of the Chromium package has broken your environment.
This can be easy discovered if one is looking into the Debian CI.

https://ci.debian.net/packages/p/python-selenium/stable/amd64/

A solution for now might be to add a breaks/conflicts in Chromium
against the current version of python3-selenium.
I had to add similar solutions like this to Thunderbird in the past.

Paul Gevers from the RT and I had a conversion about such issues a while
ago. The final solution would be for me to remove python3-selenium from
the archive as it's currently broken and unusable, or someone is
stepping up and tries to provide a fixed version of python3-selenium for
bookworm.

I currently don't have time to look into this, therefore the version in
unstable would need to get an update first. Unfortunately Selenium is a
quickly moving target at the moment and for a while. Upstream is moving
some parts and bindings/dependencies to Rust. My knowledge in this
language is very poor to promise anything.

#1099792#25
Date:
2025-03-08 10:36:24 UTC
From:
To:
Hi Carsten,

Indeed I was unsure whether to file this under selenium or under chromium.

I am happy with whatever solution you come up with, including removing
python3-selenium from the archive if no better solution is available.

Thanks,
Francesco

#1099792#30
Date:
2025-03-08 18:29:02 UTC
From:
To:
Thanks for the report. This is fixed in sid, but it will have to wait
for the next security update to get fixed in bookworm. Given the pace of
releases though, this is likely to be as soon as this Tuesday.

As a workaround, 'apt install chromium' should fix it.