selenium
selenium copied to clipboard
[rb] Ensure server is started with Bazel JDK
User description
Thanks for contributing to Selenium! A PR well described will help maintainers to quickly review and merge it
Before submitting your PR, please check our contributing guidelines. Avoid large PRs, help reviewers by making them as simple and short as possible.
Description
Motivation and Context
Types of changes
- [ ] Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to change)
Checklist
- [ ] I have read the contributing document.
- [ ] My change requires a change to the documentation.
- [ ] I have updated the documentation accordingly.
- [ ] I have added tests to cover my changes.
- [ ] All new and existing tests passed.
Type
enhancement
Description
- Added support for launching Selenium server using Bazel JDK launcher if specified in the environment variable
SELENIUM_BAZEL_SERVER_LAUNCHER. - Updated test configurations to use the Bazel server launcher and modified the relevant environment settings.
- Maintained backward compatibility by using the default Java command if the Bazel launcher is not specified.
Changes walkthrough
| Relevant files | |||||
|---|---|---|---|---|---|
| Enhancement |
| ||||
| Configuration changes |
|
✨ PR-Agent usage: Comment
/helpon the PR to get a list of all available PR-Agent tools and their descriptions
PR Description updated to latest commit (https://github.com/SeleniumHQ/selenium/commit/a57778f89ba58f2217626da639c845d879e85edc)
- [ ] Copy walkthrough table to "Files Changed" Tab
PR Review
| ⏱️ Estimated effort to review [1-5] |
2, because the changes are moderate in size and scope, involving environment variable checks and command construction adjustments. The logic is straightforward, but careful attention is needed to ensure the new environment configurations are handled correctly. |
| 🧪 Relevant tests |
No |
| 🔍 Possible issues |
Possible Bug: The use of |
| 🔒 Security concerns |
No |
✨ Review tool usage guide:
Overview:
The review tool scans the PR code changes, and generates a PR review which includes several types of feedbacks, such as possible PR issues, security threats and relevant test in the PR. More feedbacks can be added by configuring the tool.
The tool can be triggered automatically every time a new PR is opened, or can be invoked manually by commenting on any PR.
- When commenting, to edit configurations related to the review tool (
pr_reviewersection), use the following template:
/review --pr_reviewer.some_config1=... --pr_reviewer.some_config2=...
- With a configuration file, use the following template:
[pr_reviewer]
some_config1=...
some_config2=...
See the review usage page for a comprehensive guide on using this tool.
PR Code Suggestions
| Category | Suggestions | |||||
| Best practice |
Improve code safety by avoiding in-place modification of shared arrays.To avoid potential issues with mutable state, create a new array for rb/lib/selenium/server.rb [245]
| |||||
| Bug |
Prevent duplication of command line arguments in the server command.Ensure that the rb/lib/selenium/server.rb [247]
| Correct the formatting of the path in the environment variable to avoid potential path resolution issues.Ensure that the path specified in
Maintainability |
| Use a local variable instead of modifying an environment variable in-place.Instead of modifying the rb/spec/integration/selenium/webdriver/spec_support/test_environment.rb [39]
Possible issue |
| Add a check to ensure the JAR file path is provided when not using Bazel.To ensure that the server command is correctly constructed regardless of the environment, rb/lib/selenium/server.rb [247]
|
✨ Improve tool usage guide:
Overview:
The improve tool scans the PR code changes, and automatically generates suggestions for improving the PR code. The tool can be triggered automatically every time a new PR is opened, or can be invoked manually by commenting on a PR.
- When commenting, to edit configurations related to the improve tool (
pr_code_suggestionssection), use the following template:
/improve --pr_code_suggestions.some_config1=... --pr_code_suggestions.some_config2=...
- With a configuration file, use the following template:
[pr_code_suggestions]
some_config1=...
some_config2=...
See the improve usage page for a comprehensive guide on using this tool.
CI Failure Feedback
(Checks updated until commit https://github.com/SeleniumHQ/selenium/commit/afaf1c27cdde831b710017be57618b3a4091ccee)
|
Action: Test / All RBE tests |
|
Failure summary: The action failed due to the cancellation of the operation. This is indicated by the log message at |
Relevant error logs:
|
✨ CI feedback usage guide:
The CI feedback tool (/checks) automatically triggers when a PR has a failed check.
The tool analyzes the failed checks and provides several feedbacks:
- Failed stage
- Failed test name
- Failure summary
- Relevant error logs
In addition to being automatically triggered, the tool can also be invoked manually by commenting on a PR:
/checks "https://github.com/{repo_name}/actions/runs/{run_number}/job/{job_number}"
where {repo_name} is the name of the repository, {run_number} is the run number of the failed check, and {job_number} is the job number of the failed check.
Configuration options
enable_auto_checks_feedback- if set to true, the tool will automatically provide feedback when a check is failed. Default is true.excluded_checks_list- a list of checks to exclude from the feedback, for example: ["check1", "check2"]. Default is an empty list.enable_help_text- if set to true, the tool will provide a help message with the feedback. Default is true.persistent_comment- if set to true, the tool will overwrite a previous checks comment with the new feedback. Default is true.final_update_message- ifpersistent_commentis true and updating a previous checks message, the tool will also create a new message: "Persistent checks updated to latest commit". Default is true.
See more information about the checks tool in the docs.
Merged in https://github.com/SeleniumHQ/selenium/commit/b456e6089d626c5575d7756110fbfdad2c9dfef1