chore: ruff auto-fix E303 — too-many-blank-lines - #42036
Closed
wesleysimplicio wants to merge 1 commit into
Closed
wesleysimplicio wants to merge 1 commit into
wesleysimplicio wants to merge 1 commit into
Conversation
Collaborator
|
Coordination note (all 4 ruff PRs: #42037, #42036, #42034, #42035) These four mechanical ruff auto-fixes are all valid — no logic changes, just W391/E303/F541/PIE807 cleanup. However they share overlapping files and will create merge conflicts if landed independently:
Request: Could you consolidate all four into a single PR (e.g. |
This was referenced Jun 9, 2026
Contributor
Author
|
Closing in favor of consolidated PR (per austinpickett's review request — see consolidated PR replacing this one.) |
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.
What does this PR do?
Adds the
E303rule to pyproject.toml and applies auto-fix across 210 files.Removes excess blank lines between function/class definitions, enforcing the PEP 8 convention of at most two blank lines at the top level and at most one blank line inside methods.
Root cause
The codebase accumulated extra blank lines during normal development. PEP 8 (E303) specifies that the maximum blank line count is 2 at the module level and 1 inside functions — this rule enforces that.
Fix
E303to[tool.ruff.lint] selectinpyproject.toml.ruff check --select E303 --preview --fix .— 375 errors fixed across 210 files.Why this shape
Same per-rule pattern as the existing ruff PRs (#31825–#32027): one rule, one auto-fix, one commit. Keeps diffs focused and blame history clean.
Tests
ruff checkpasses with zero errors after the fix (rule is active in config).Related PRs / issues