-
-
Notifications
You must be signed in to change notification settings - Fork 8.6k
PEP484 type hints for py/selenium/webdriver/chrome/options.py #10212
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
PEP484 type hints for py/selenium/webdriver/chrome/options.py #10212
Conversation
|
Should this be |
|
@colons you have a very different implementation for
|
|
@titusfortner im not sure what difference exactly you're worried about here; the wrapping of optional kwargs with certainly, though, |
|
@colons — I thought everything in Python had a one true way for things. :) |
| android_package: str = "com.android.chrome", | ||
| android_activity: Optional[str] = None, | ||
| device_serial: Optional[str] = None | ||
| ) -> NoReturn: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This needs to be None not NoReturn
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I corrected that and pushed it. Should we be revisiting NoReturn usage in other places such as https://github.com/SeleniumHQ/selenium/blob/trunk/py/selenium/webdriver/firefox/webdriver.py#L186 ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Correcting NoReturn to None
* PEP484 hints for py/selenium/webdriver/chrome/options.py (SeleniumHQ#10212)
Description
This PR adds type hints to
selenium.webdriver.chrome.optionsMotivation and Context
This is an action towards #9480.
Types of changes
Checklist