Skip to content

[🐛 Bug]: [py] confusing error when creating webdriver.Remote() without options #15618

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
cgoldberg opened this issue Apr 11, 2025 · 1 comment · Fixed by #15619
Closed
Labels
C-py Python Bindings I-defect Something is not working as intended OS-linux

Comments

@cgoldberg
Copy link
Contributor

cgoldberg commented Apr 11, 2025

Description

In Python, if you try to create a webdriver.Remote() instance without passing a driver options.Options() instance as a keyword argument (options), you get the following error:

AttributeError: 'NoneType' object has no attribute 'to_capabilities'

... which isn't very helpful.

This happens if you try to create it with no arguments or try to create it with options.Options() instance as a positional argument.

Reproducible Code

from selenium import webdriver

driver = webdriver.Remote()

Debugging Logs

N/A
@cgoldberg
Copy link
Contributor Author

#15619 should fix this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-py Python Bindings I-defect Something is not working as intended OS-linux
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant