fix: remove useless f-string prefix from 144 static strings (batch 2) - #52258
Closed
AlexFucuson9 wants to merge 1 commit into
Closed
AlexFucuson9 wants to merge 1 commit into
AlexFucuson9 wants to merge 1 commit into
Conversation
Strings with no {expressions} don't need the f-prefix. The f-prefix
adds unnecessary overhead and confuses readers who expect interpolated
values.
Fixes 144 occurrences in 5 files:
- tools/delegate_tool.py (40)
- hermes_cli/completion.py (39)
- tools/browser_tool.py (25)
- agent/file_safety.py (20)
- gateway/slash_commands.py (20)
Related: batch 2 follow-up to #52254 (batch 1). Disjoint files (this PR: file_safety, slash_commands, completion, browser_tool, delegate_tool); same ruff F541 cleanup. Not a duplicate. |
This was referenced Jun 25, 2026
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.
Problem
Strings with no
{expressions}don't need thefprefix. The f-prefix adds unnecessary overhead and confuses readers who expect interpolated values.Files changed (144 fixes in 5 files)
tools/delegate_tool.pyhermes_cli/completion.pytools/browser_tool.pyagent/file_safety.pygateway/slash_commands.pyFollow-up to PR #52254 (batch 1, 153 fixes in 3 files). Remaining ~480 hits across 40+ files in subsequent batches.