Repository navigation
chore(lint): remove dead E501 config, fix stale blame-ignore SHAs, note 120 width in CLAUDE.md - #31926
Closed
mateo-berri wants to merge 2 commits into
Closed
chore(lint): remove dead E501 config, fix stale blame-ignore SHAs, note 120 width in CLAUDE.md#31926mateo-berri wants to merge 2 commits into
mateo-berri wants to merge 2 commits into
Conversation
…te 120 width in CLAUDE.md E501 sat in both lint.ignore and lint.extend-select in ruff.toml; ignore wins, so no line length was linted at all (verified: a 130-char line passes ruff check while T201 fires). Remove it from both lists so the config tells the truth: the formatter's wrap width is the only line-length control, matching how the repo has actually behaved since E501 was ignored in Oct 2024 .git-blame-ignore-revs listed the pre-squash PR-head SHAs for the two ruff reformat commits (#31317, #31518), which never landed on the branch, so git blame ignored nothing. Replace them with the squash-merge SHAs that are actually in history Also document in CLAUDE.md that the line length is 120 (ruff.toml), not 88, so agents stop wrapping to the old Black width
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
Merged
3 of 4 tasks
Contributor
Author
|
Moved to #31927 to follow the internal branch naming convention; same commits, closing this one Generated by Claude Code |
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.
Relevant issues
Linear ticket
Pre-Submission checklist
Please complete all items before asking a LiteLLM maintainer to review your PR
@greptileaiand received a Confidence Score of at least 4/5 before requesting a maintainer reviewDelays in PR merge?
If you're seeing a delay in your PR being merged, ping the LiteLLM Team on Slack (#pr-review).
Screenshots / Proof of Fix
Config-only change, so the proof is that each removed piece was demonstrably dead and lint still passes after
E501 was inert before this PR. A 130-char line passes
ruff checkunder the old config while a rule that is genuinely enabled (T201) fires, showing the config loads fine and E501 specifically is suppressed bylint.ignore:After the removal, the full lint run is still clean:
For the blame-ignore fix, the listed SHAs were the PR-head commits of #31317 and #31518, which never landed on this branch because both PRs were squash merged; the commits actually in history are the squash SHAs this PR swaps in (verifiable in the GitHub UI: the old SHAs 430b5b8 and 3dfbeab are not reachable from litellm_internal_staging, while 17bfd41 and 48b5a5a are the commits on the branch)
Type
🧹 Refactoring
Changes
Three small pieces of lint-config housekeeping surfaced while auditing the line-length setup
ruff.toml had E501 in both
lint.ignoreandlint.extend-select. Ignore wins, so no maximum line length has actually been linted since E501 was added to the ignore list back in Oct 2024; the formatter's wrap width (line-length = 120) is the only real control. This PR removes E501 from both lists so the config stops implying an enforcement that does not exist, and updates the Makefile comment that mentioned E501 accordingly. No# noqa: E501directives exist in linted paths, so nothing is orphaned.git-blame-ignore-revs listed the pre-squash PR-head SHAs for the two ruff reformat commits (#31317 and #31518). Since both PRs were squash merged, those SHAs are not ancestors of the branch and git blame (and the GitHub blame UI) ignored nothing for the two largest formatting commits in the repo. They are replaced with the squash-merge SHAs that are actually in history. The prettier entry for #29622 was checked and already points at the real squash commit
CLAUDE.md now states that the Python line length is 120 (ruff.toml being the single source of truth for the formatter and import sorter), not 88, so agents and contributors stop wrapping new code to the old Black width
Generated by Claude Code