Jump to content

Connect SuperML | Leeroopedia MCP: Equip your AI agents with best practices, code verification, and debugging knowledge. Powered by Leeroo — building Organizational Superintelligence. Contact us at founders@leeroo.com.

Implementation:SeleniumHQ Selenium PR Template And Gh CLI

From Leeroopedia
Knowledge Sources
Domains Collaboration, Code_Review, Developer_Experience
Last Updated 2026-02-11 00:00 GMT

Overview

Pattern documentation for submitting pull requests using the Selenium PR template and GitHub CLI.

Description

The PR template at .github/PULL_REQUEST_TEMPLATE.md defines the required sections for every pull request. The template includes five sections: Related Issues (with Fixes #N or Closes #N syntax), What does this PR do? (description of changes), Implementation Notes (reasoning and alternatives), Additional Considerations (decisions needed, follow-up work), and Types of changes (checklist of Cleanup, Bug fix, New feature, or Breaking change).

PRs are squash-merged to trunk by committers, producing a linear commit history. The gh pr create command from GitHub CLI can be used to create PRs from the command line, or the GitHub web UI can be used after pushing a branch. Review feedback should be applied in new fixup commits pushed to the same branch; committers will squash everything at merge time.

Usage

Use gh pr create after pushing your branch, or create the PR through the GitHub web UI. Fill in all template sections. If the reason for the PR is not obvious, consider creating an issue first.

Code Reference

Source Location

  • Repository: Selenium
  • File: .github/PULL_REQUEST_TEMPLATE.md (L1-25)
  • File: CONTRIBUTING.md (L296-364)

Interface Specification

PR Template Structure

### Related Issues
<!-- Example: Fixes #1234 or Closes #5678 -->
<!-- If the reason for this PR is not obvious, consider creating an issue first -->

### What does this PR do?
<!-- Describe what this change includes and how it works -->

### Implementation Notes
<!-- Why did you implement it this way? -->
<!-- What alternatives to this approach did you consider? -->

### Additional Considerations
<!-- Are there any decisions that need to be made before accepting? -->
<!-- Is there any follow-on work needed? (e.g., docs, tests, etc.) -->

### Types of changes
<!-- Delete anything that doesn't apply -->
- Cleanup (formatting, renaming)
- Bug fix (backwards compatible)
- New feature (non-breaking change which adds functionality *and tests!*)
- Breaking change (fix or feature that would cause existing functionality to change)

PR Review Labels

Label Meaning
R-awaiting reviewer Pending code review from maintainer
R-needs code changes Review feedback to address
R-awaiting answer Question awaiting contributor response
R-awaiting merge Approved and ready for committer to merge
R-needs rebase Branch not in sync with trunk, needs rebase
R-blocked on external Waiting on a change in an upstream repo
C-java, C-py, C-rb, etc. Component labels (yellow, C- prefix)
D-* Driver labels (WebDriver implementation affected)

Import

N/A - Pattern documentation

I/O Contract

Inputs

Name Type Required Description
Branch Git branch Yes Feature branch with changes pushed to origin
PR title String Yes Descriptive title (becomes squash commit message on trunk)
PR body Markdown Yes Filled template with all sections completed
Issue reference String No "Fixes #N" or "Closes #N" linking to related issue

Outputs

Name Type Description
Pull request GitHub PR PR ready for review with CI status checks running

Usage Examples

Using GitHub CLI

# Push branch first
git push origin fix-chrome-options

# Create PR using gh CLI
gh pr create \
  --title "Fix ChromeOptions merge behavior" \
  --body "### Related Issues
Fixes #12345

### What does this PR do?
Fixes the merge method in ChromeOptions to properly handle
encoded extensions when merging two ChromeOptions instances.

### Implementation Notes
Modified mergeInPlace() to decode extensions before comparison.
Alternative considered: storing extensions pre-decoded, but this
would break backward compatibility.

### Additional Considerations
This fix applies to Java only. Python and Ruby bindings should
be checked for the same issue.

### Types of changes
- Bug fix (backwards compatible)"

Using GitHub Web UI

# 1. Push branch
git push origin fix-chrome-options

# 2. Navigate to https://github.com/yourusername/selenium
# 3. GitHub shows "Compare & pull request" banner
# 4. Fill in the pre-populated template sections
# 5. Click "Create pull request"

Addressing Review Feedback

# After receiving review comments, make changes and push fixup commits
git add <changed-files>
git commit --fixup=HEAD
git push origin fix-chrome-options

# If rebase needed (R-needs rebase label):
git fetch upstream
git rebase upstream/trunk
git push origin fix-chrome-options --force-with-lease

Remote Build Execution (for maintainers)

# EngFlow RBE can be used for remote builds/tests
bazel build --config=rbe grid
bazel test --config=rbe java/test/...
# Output includes link to EngFlow UI for build progress tracking

Related Pages

Implements Principle

Page Connections

Double-click a node to navigate. Hold to expand connections.
Principle
Implementation
Heuristic
Environment