[java] Remove deprecated GET /session/{sessionId}/se/files/{fileName} endpoint - #17982
Merged
Conversation
… endpoint Marked @deprecated in #16844 (Jan 2026) with a note to remove it in Selenium 4.41, 4.42, or 4.43. Trunk is now at 4.49.0-SNAPSHOT, six releases past that target, and none of the four client bindings ever built a request to this path -- they only use the list/POST/DELETE forms of /se/files.
Contributor
Qodo reviews are paused for this user.Troubleshooting steps vary by plan Learn more → On a Teams plan? Using GitHub Enterprise Server, GitLab Self-Managed, or Bitbucket Data Center? |
Spotbugs flagged it as an unused private method after the prior
commit removed the deprecated GET /se/files/{fileName} endpoint,
which was its only caller.
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014kEM1tVUYCgzyhJ5xmseyF
Contributor
Code Review by Qodo
1. Removed route lacks regression test
|
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.
🔗 Related Issues
Follow-up to #16844, which introduced this deprecation, and to the review discussion on #17968.
💥 What does this PR do?
Removes the deprecated
GET /session/{sessionId}/se/files/{fileName}Grid Node endpoint and its client-side command (DriverCommand.GET_DOWNLOADED_FILE). #16844 (January 2026) marked it@Deprecatedwith a note to "Remove it in 4.41, 4.42 or 4.43." Trunk is now at4.49.0-SNAPSHOT, six releases past that target.What changed:
Node.java— removed the route registration forGET /session/{sessionId}/se/files/{fileName}.LocalNode.java— removed the backward-compatibility dispatch branch and bothextractFileNameoverloads that existed only to serve it.DriverCommand.java— removed the@Deprecated GET_DOWNLOADED_FILEconstant.AbstractHttpCommandCodec.java— removed the corresponding command-codec entry and its now-unused import.LocalNodeTest.java— removedextractsFileNameFromRequestUri, which only tested the removed method.The three endpoints every client binding actually uses —
GET /session/{sessionId}/se/files(list),POST /session/{sessionId}/se/files(download via JSON body), andDELETE /session/{sessionId}/se/files(delete) — are untouched.🔧 Implementation Notes
Checked all four bindings (Python, Ruby, JavaScript, .NET): none of them ever built a request to the path-parameter GET form, they only use the three endpoints above (
GET_DOWNLOADED_FILEwas Java-only, unused since 4.40 per its own javadoc). So this removal has no cross-binding impact.Verified with
bazel testthatNodeTest,LocalNodeTest,W3CHttpCommandCodecTest, andJdkHttpClientTestall still pass after the removal, and ran./scripts/format.sh --pre-commitclean.🤖 AI assistance
💡 Additional Considerations
None — this removes dead, already-deprecated code with an existing replacement (
DOWNLOAD_FILE/POST) that all bindings already use.🔄 Types of changes