Repository navigation
chore: fix findings of ruff 0.17 - #55
Merged
Merged
Conversation
Lint CI runs the latest ruff, which added rules since main last passed, so every new PR failed on code it did not touch. - RUF036: move None to the end of type unions (split, openslide_tile_reader) - BLE001: keep the broad except in MemMap.close() (best-effort cleanup that also runs from __del__) and mark it with noqa - ruff format, including the code blocks in the Markdown docs Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars. ⚙️ Run configuration
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Contributor
Documentation PreviewPreview URL: https://RationAI.github.io/ratiopath/claude-ruff-cleanup/ |
Adames4
approved these changes
Oct 13, 2026
matejpekar
approved these changes
Oct 13, 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.
The lint workflow (
RationAI/.github→python-lint.yml) runsuvx ruffwithout a version, so it always gets the latest ruff. Sincemainlast passed in July, ruff added rules, and now every new PR fails the Ruff job on code it doesn't touch (e.g. #54). This PR makesmainpass with ruff 0.17.0 again.Changes (no behaviour change)
Nonemoved to the end of type unions inmodel_selection/split.pyandtorch/data/openslide_tile_reader.py.except ExceptioninMemMap.close()stay. It's best-effort cleanup that also runs from__del__, so they are now marked withnoqaand a reason.ruff format: ruff 0.17 also formats Python code blocks in Markdown, which is why some docs pages changed. Only code blocks in them changed.Checks (local)
ruff checkandruff format --checkwith 0.17.0: clean.mypy .: clean.pytest: 373 passed.mkdocs build --strict: passes.A separate PR in
RationAI/.githubwill pin the ruff version in the shared workflow, so a ruff release no longer breaks every repo at once. Please merge this one before #54.🤖 Generated with Claude Code