Repository navigation
D5: Outdated Selenium patterns page - #2903
Open
AutomatedTester wants to merge 3 commits into
Open
AutomatedTester wants to merge 3 commits into
AutomatedTester wants to merge 3 commits into
Conversation
Add documentation/ai_agents/outdated_patterns.en.md: for each Selenium 2/3 idiom that agents reproduce (DesiredCapabilities, manual drivers, sleep, absolute XPath, find_element_by_*, executable_path, CDP-only calls) show the outdated form, when it was superseded, and the current form referenced from examples/. Add Java and Python relative locator examples, since none existed. The page needs a section directory, so this also renames ai_agents.en.md to ai_agents/_index.en.md unchanged. D1 does the same rename; whichever lands second needs a trivial rebase.
✅ Deploy Preview for selenium-dev ready!
To edit notification comments on pull requests, go to your Netlify project configuration. |
Drop the two new example tests, which were not run and depend on the layout of the login page, and show the relative locator form inline as the Locators page already does.
Member
Author
|
Superseded: the Phase 1 items are being regrouped into one PR per workstream to make the layout easier to review as a whole. This branch's commit is carried over unchanged. Generated by Claude Code |
20 tasks
Member
Author
|
Reopened. Part of the selenium.dev modernisation set; see #2912 for the full list and suggested review order. Generated by Claude Code |
AutomatedTester
marked this pull request as ready for review
October 14, 2026 14:49
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Merge note: D1 and D5 both perform the same rename,
documentation/ai_agents.en.mdtodocumentation/ai_agents/_index.en.md. Here it is an unmodified rename (0 lines changed). Whichever merges second needs a trivial rebase; keep the D1 version of_index.en.md.What changed
website_and_docs/content/documentation/ai_agents/outdated_patterns.en.md(title "Outdated Selenium patterns and their current replacements", linkTitle "Outdated Patterns", weight 2).ai_agents.en.mdtoai_agents/_index.en.md(see merge note).// Outdated — do not useor# Outdated — do not use, and the current form viagh-codeblock:find_element(By...)Serviceexamples/java/src/test/java/dev/selenium/elements/RelativeLocatorTest.javaandexamples/python/tests/elements/test_relative_locators.py(login page,below(username-field)findspassword-field).Why
Plan item D5: a "wrong vs right" reference that the AI agents page (D1) points at, so a reviewer can recognise stale agent output and see the replacement.
Acceptance criteria
examples/withgh-codeblock; every line range checked against the files on this branch.2024/selenium-4-17-released.md(Java no longer acceptsdesiredCapabilitiessession requests).documentation/selenium_manager.en.md.2022/python-locators-se4.md("sometime after Selenium 4.2" for removal) and the upgrade guide (JavafindElementBy*removed).bidi/cdp/_index.en.md("temporary until WebDriver BiDi") and blog2025/remove-cdp-firefox.md(Firefox CDP deprecated in 4.27 and 4.28, removed in 4.29).find_element_by_*) and "4.10" (executable_path) that appear in the existing AI agents rules tabs. The repo's blog and upgrade guide do not confirm those numbers, so this page says "removal announced after 4.2" and "deprecated in Selenium 4" instead. Worth a check by whoever knows the changelog./documentation/ai_agents/outdated_patterns/; sidebar shows "AI Agents" with child "Outdated Patterns".py_compile/read-checked. Please runpytest tests/elements/test_relative_locators.pyandmvn test -Dtest=RelativeLocatorTest; the assertion relies onlogin.htmlhavingusername-fielddirectly abovepassword-field.gh-codeblockfetches from GitHubtrunk, so the two new examples render "not found" in a preview until this branch merges.Translated pages affected
None. The new page is English only.
ai_agentshas no ja/pt-br/zh-cn pages.Checks run
ERRORorWARN.documentation/ai_agents/outdated_patterns/index.html, title as specified, 14 "Outdated — do not use" markers.python3 -m py_compileon the new Python test.options,selenium_manager,waits,locators,service,upgrade_to_selenium_4,bidi/cdp,bidi/w3c, blog python-locators) all resolved byrefduring the build.Disclosure
Prepared with Claude (Anthropic); the author reviewed and edited all content.
Generated by Claude Code