Skip to content

Update ruff to 0.15.6#7427

Merged
youknowone merged 2 commits intoRustPython:mainfrom
ShaharNaveh:update-ruff-0-15-6
Mar 14, 2026
Merged

Update ruff to 0.15.6#7427
youknowone merged 2 commits intoRustPython:mainfrom
ShaharNaveh:update-ruff-0-15-6

Conversation

@ShaharNaveh
Copy link
Contributor

@ShaharNaveh ShaharNaveh commented Mar 14, 2026

Summary by CodeRabbit

  • Chores
    • Updated Ruff toolchain dependency to version 0.15.6
    • Updated internal infrastructure and AST handling for improved compatibility

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Mar 14, 2026

Caution

Review failed

Pull request was closed or merged during review

📝 Walkthrough

Walkthrough

The PR updates the Ruff toolchain dependency from tag 0.15.5 to 0.15.6 with corresponding git revision updates and adds placeholder support for lazy imports by introducing new is_lazy fields in tokenization and AST statement handling.

Changes

Cohort / File(s) Summary
Dependency Update
Cargo.toml
Bumped Ruff toolchain from 0.15.5 to 0.15.6; updated four Ruff-related git dependencies (ruff_python_parser, ruff_python_ast, ruff_text_size, ruff_source_file) to commit e4c7f357777a2fdd34dbe6a98b1b7d3e7488f675.
Lazy Import Support
crates/stdlib/src/_tokenize.rs, crates/vm/src/stdlib/_ast/statement.rs
Added placeholder support for lazy imports: new match arm for TokenKind::Lazy returning u8::MAX; added is_lazy field (bool) to StmtImport and StmtImportFrom AST nodes, both initialized to false.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related PRs

Suggested reviewers

  • youknowone

Poem

🐰 Lazy hops are on the way,
New fields blooming, fresh today,
Ruff now points to newer ground,
Placeholders hold what's soon to be found,
Version bumps and imports set,
The best improvements yet! 🌟

🚥 Pre-merge checks | ✅ 2 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The pull request title 'Update ruff to 0.15.6' directly aligns with the primary change in Cargo.toml, which bumps the Ruff toolchain from 0.15.5 to 0.15.6. However, the changeset also includes unrelated modifications to token handling and AST structures that are not reflected in the title.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
📝 Coding Plan
  • Generate coding plan for human review comments

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.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions
Copy link
Contributor

📦 Library Dependencies

The following Lib/ modules were modified. Here are their dependencies:

[ ] test: cpython/Lib/test/test_unpack.py (TODO: 1)
[ ] test: cpython/Lib/test/test_unpack_ex.py (TODO: 7)

dependencies:

dependent tests: (no tests depend on unpack)

Legend:

  • [+] path exists in CPython
  • [x] up-to-date, [ ] outdated

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Seems that astral-sh/ruff@8bc437e did great:)

@ShaharNaveh ShaharNaveh marked this pull request as ready for review March 14, 2026 11:14
Copy link
Member

@youknowone youknowone left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@youknowone youknowone merged commit 0c14ad1 into RustPython:main Mar 14, 2026
15 of 16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants