Skip to content

[py] Fix example WebDriverWait import in docstring#17735

Merged
cgoldberg merged 1 commit into
SeleniumHQ:trunkfrom
cgoldberg:py-import-example
Jun 30, 2026
Merged

[py] Fix example WebDriverWait import in docstring#17735
cgoldberg merged 1 commit into
SeleniumHQ:trunkfrom
cgoldberg:py-import-example

Conversation

@cgoldberg

Copy link
Copy Markdown
Member

🔗 Related Issues

Fixes #17734

💥 What does this PR do?

This PR updates the examples in WebDriverWait to make them more consistent in API docs.

🤖 AI assistance

  • No substantial AI assistance used

🔄 Types of changes

  • Cleanup (formatting, renaming)

@cgoldberg cgoldberg self-assigned this Jun 30, 2026
@cgoldberg cgoldberg added the C-py Python Bindings label Jun 30, 2026
@selenium-ci selenium-ci added the B-support Issue or PR related to support classes label Jun 30, 2026
@selenium-ci

Copy link
Copy Markdown
Member

Thank you, @cgoldberg for this code suggestion.

The support packages contain example code that many users find helpful, but they do not necessarily represent
the best practices for using Selenium, and the Selenium team is not currently merging changes to them.

After reviewing the change, unless it is a critical fix or a feature that is needed for Selenium
to work, we will likely close the PR.

We actively encourage people to add the wrapper and helper code that makes sense for them to their own frameworks.
If you have any questions, please contact us

@qodo-code-review

Copy link
Copy Markdown
Contributor

PR Summary by Qodo

Fix WebDriverWait docstring example import path

📝 Documentation 🐞 Bug fix 🕐 Less than 5 minutes

Grey Divider

AI Description

• Fix WebDriverWait import path in until/until_not docstring examples.
• Align API docs snippets with the actual selenium.webdriver.support.wait module.
High-Level Assessment

The minimal docstring correction is the best approach here; no architectural changes are warranted. Considered adding/keeping a re-export in support.ui, but that would increase API surface and isn’t needed to fix the documentation example.

Files changed (1) +2 / -2

Documentation (1) +2 / -2
wait.pyCorrect WebDriverWait import in docstring examples +2/-2

Correct WebDriverWait import in docstring examples

• Updates the 'until' and 'until_not' docstring examples to import 'WebDriverWait' from 'selenium.webdriver.support.wait' instead of 'selenium.webdriver.support.ui', keeping the documentation consistent with the implementation/module location.

py/selenium/webdriver/support/wait.py

@cgoldberg cgoldberg merged commit c6e9c20 into SeleniumHQ:trunk Jun 30, 2026
10 checks passed
@cgoldberg cgoldberg deleted the py-import-example branch June 30, 2026 23:43
@qodo-code-review

Copy link
Copy Markdown
Contributor

Code Review by Qodo

🐞 Bugs (0) 📘 Rule violations (0) 📎 Requirement gaps (0)

Grey Divider

Great, no issues found!

Qodo reviewed your code and found no material issues that require review

Grey Divider

Qodo Logo

This was referenced Jul 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

B-support Issue or PR related to support classes C-py Python Bindings

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[🐛 Bug]: selenium.webdriver.support.ui.WebDriverWait vs selenium.webdriver.support.wait.WebDriverWait

2 participants