Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates the repository’s Python linting/formatting approach by moving away from ruff format enforcement and toward a curated Ruff rule selection (including pycodestyle E/W), with accompanying code edits to satisfy the new lint rules and some dependency bumps.
Changes:
- Replace
ruff’sselect = ["ALL"]with an explicit rule set (includingE/W) and adjust ignores to support 2-space indentation. - Disable
ruff formatchecks in pre-commit/lint-staged and in the reusable CI workflow, while keepingruff check. - Apply small code edits across notebooks/examples/datasets to satisfy lint suggestions (Pathlib helpers, encoding, small simplifications).
Reviewed changes
Copilot reviewed 19 out of 19 changed files in this pull request and generated 6 comments.
Show a summary per file
| File | Description |
|---|---|
| solutions/sports/yolo_v8.py | Adds # noqa: SIM113 on step increment. |
| solutions/sports/numbers/resnet.py | Adds # noqa: SIM113 on step increment. |
| pyproject.toml | Updates dev dependency versions (incl. ruff) and adds ty. |
| packages/config/ruff.toml | Switches from ALL to an explicit Ruff select list; adds/adjusts ignores. |
| packages/config/package.json | Bumps JS tooling versions (eslint plugins, oxlint). |
| packages/config/lint-staged.js | Comments out ruff format --check and mypy for staged .py files. |
| notebooks/vision/faster_rcnn.py | Uses Path.write_text/read_text/write_bytes/read_bytes with explicit UTF-8 encoding. |
| notebooks/vision/fashion_mnist.py | Adds # noqa: SIM113 on step increment. |
| notebooks/text/ngram_language_models.py | Replaces slice-copy with .copy(). |
| notebooks/reinforcement_learning/lunar_lander.py | Simplifies deque initialization. |
| notebooks/reinforcement_learning/frozen_lake.py | Minor simplifications (set membership; tuple key style). |
| notebooks/random/color_models.py | Switches to in-place division for normalization. |
| examples/http/_bench/utils.py | Adds explicit UTF-8 encoding when appending results JSON lines. |
| examples/grafana/smartctl/apply.py | Adds explicit UTF-8 encoding for temp JSON file. |
| camp/utils/jupyter_utils.py | Adds lint suppression for _render_traceback_. |
| camp/datasets/soccernet.py | Adds explicit UTF-8 encoding; suppresses “no-self-use” lint. |
| camp/datasets/mnist.py | Refactors parsing/tensor conversion into module-level helpers. |
| camp/datasets/ikcest.py | Renames unused ctor arg from subset to _subset. |
| .github/workflows/verify-py.yml | Disables the format-py job via if: false. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
3e79a98 to
fb63013
Compare
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.
No description provided.