Skip to content

[Agents] Update agents to make sure do linting.#17366

Merged
AutomatedTester merged 4 commits intotrunkfrom
agent-improvements
Apr 21, 2026
Merged

[Agents] Update agents to make sure do linting.#17366
AutomatedTester merged 4 commits intotrunkfrom
agent-improvements

Conversation

@AutomatedTester
Copy link
Copy Markdown
Member

🔗 Related Issues

💥 What does this PR do?

Agents have a bad habit of doing things which don't align with our formatting rules. This change updates the agents to make sure they follow the rules and as added extra run ./go format as that will clean up.

🔧 Implementation Notes

💡 Additional Considerations

🔄 Types of changes

  • Agent Changes

Agents have a bad habit of doing things which don't align with our
formatting rules. This change updates the agents to make sure they
follow the rules and as added extra run `./go format` as that will
clean up.
Copilot AI review requested due to automatic review settings April 21, 2026 10:38
@selenium-ci selenium-ci added C-py Python Bindings C-rb Ruby Bindings C-dotnet .NET Bindings C-java Java Bindings C-nodejs JavaScript Bindings B-build Includes scripting, bazel and CI integrations C-rust Rust code is mostly Selenium Manager B-manager Selenium Manager labels Apr 21, 2026
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the various agent instruction files to better align AI-generated changes with the repo’s formatter/linter expectations, primarily by standardizing on running ./go format after code edits.

Changes:

  • Add “Formatting” guidance to language-specific AGENTS.md files (Rust/Ruby/Python/JS/Java/.NET).
  • Add repo-wide formatting guidance to the root AGENTS.md, and update instructions to prefer ./go format.
  • Update CLAUDE.md, CLAUDE.local.md, and .github/copilot-instructions.md to remind agents to run/suggest ./go format.

Reviewed changes

Copilot reviewed 10 out of 10 changed files in this pull request and generated 4 comments.

Show a summary per file
File Description
rust/AGENTS.md Adds Rust formatting guidance (rustfmt) and ./go format reminder.
rb/AGENTS.md Adds Ruby formatting guidance (RuboCop) and ./go format reminder.
py/AGENTS.md Adds Python formatting/lint guidance (ruff) and ./go format reminder.
javascript/selenium-webdriver/AGENTS.md Adds JS formatting guidance (Prettier) and ./go format reminder.
java/AGENTS.md Adds Java formatting guidance (google-java-format) and ./go format reminder.
dotnet/AGENTS.md Adds .NET formatting guidance (dotnet format) and ./go format reminder.
CLAUDE.md Adds a reminder to run/suggest ./go format after code changes.
CLAUDE.local.md Same as CLAUDE.md, but for local agent instructions.
AGENTS.md Adds a new repo-wide formatting section and updates pre-push guidance to ./go format.
.github/copilot-instructions.md Adds a formatting reminder alongside “read AGENTS.md”.

Comment thread AGENTS.md Outdated
Comment thread AGENTS.md Outdated
Comment thread AGENTS.md Outdated
Comment thread py/AGENTS.md Outdated
AutomatedTester and others added 2 commits April 21, 2026 11:46
- ./go format invokes the Rake :format task directly, not scripts/format.sh
- It auto-fixes in place but does NOT exit non-zero when files are modified;
  CI uses scripts/format.sh (via check-format.sh) for that behaviour
- ./go format --lint does not exist; the correct command is ./go lint
- Add instruction to check git diff after running ./go format

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings April 21, 2026 11:20
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 10 out of 10 changed files in this pull request and generated 3 comments.

Comment thread AGENTS.md Outdated
Comment thread AGENTS.md Outdated
Comment thread java/AGENTS.md Outdated
- ./go format runs all-binding formatters (no change-detection), not
  per-changed-file; pass -<lang> flags to skip specific bindings
- CI check: runs ./go format then git diff --quiet (not scripts/format.sh
  which is only used by Renovate CI jobs)
- google-java-format organizes/sorts imports but does not remove unused
  imports or replace wildcards; correct the bullet point

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@AutomatedTester AutomatedTester merged commit 31ee122 into trunk Apr 21, 2026
25 checks passed
@AutomatedTester AutomatedTester deleted the agent-improvements branch April 21, 2026 14:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

B-build Includes scripting, bazel and CI integrations B-manager Selenium Manager C-dotnet .NET Bindings C-java Java Bindings C-nodejs JavaScript Bindings C-py Python Bindings C-rb Ruby Bindings C-rust Rust code is mostly Selenium Manager

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants