Update some deps by ShaharNaveh · Pull Request #6053 · RustPython/RustPython
Walkthrough
Dependency versions were updated across several Cargo.toml files. The root workspace updated bitflags, indexmap, and widestring. The stdlib crate updated bzip2 (with feature adjustments) and gethostname. The vm crate updated which and num_cpus for specific targets. No changes to public APIs or features occurred.
Changes
| Cohort / File(s) | Change Summary |
|---|---|
Workspace Dependency UpdatesCargo.toml |
Updated bitflags (2.4.2 → 2.9.1), indexmap (2.2.6 → 2.10.0), and widestring (1.1.0 → 1.2.0). |
stdlib Dependency Updatesstdlib/Cargo.toml |
Updated bzip2 (0.5 + feature → 0.6, feature removed) and gethostname (1.0.0 → 1.0.2). |
vm Dependency Updatesvm/Cargo.toml |
Updated which (7 → 8) and num_cpus (1.13.1 → 1.17.0) for non-wasm32/wasi targets. |
Estimated code review effort
🎯 1 (Trivial) | ⏱️ ~2 minutes
Poem
🐇
A hop through the fields of versioned code,
Dependencies freshen, lightening the load.
Bitflags and bzip2, all up to date,
Indexmaps widen, the future looks great!
With each gentle nudge, our garden will grow—
Onward we leap, with updates in tow!
🌱✨
Note
⚡️ Unit Test Generation is now available in beta!
Learn more here, or try it out under "Finishing Touches" below.
📜 Recent review details
Configuration used: .coderabbit.yml
Review profile: CHILL
Plan: Pro
⛔ Files ignored due to path filters (1)
Cargo.lockis excluded by!**/*.lock
📒 Files selected for processing (3)
Cargo.toml(3 hunks)stdlib/Cargo.toml(2 hunks)vm/Cargo.toml(2 hunks)
🧰 Additional context used
🧠 Learnings (3)
📓 Common learnings
Learnt from: CR
PR: RustPython/RustPython#0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-07-19T03:16:56.511Z
Learning: Generate documentation with `cargo doc --no-deps --all`
📚 Learning: in cargo build scripts (build.rs), the environment variable cargo_cfg_target_os is guaranteed to exi...
Learnt from: arihant2math
PR: RustPython/RustPython#5790
File: build.rs:2-2
Timestamp: 2025-06-28T16:31:03.991Z
Learning: In Cargo build scripts (build.rs), the environment variable CARGO_CFG_TARGET_OS is guaranteed to exist and is automatically set by Cargo during the build process, making unwrap() safe to use when accessing this variable.
Applied to files:
stdlib/Cargo.tomlvm/Cargo.toml
📚 Learning: applies to **/*.rs : follow rust best practices for error handling and memory management...
Learnt from: CR
PR: RustPython/RustPython#0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-07-19T03:16:56.511Z
Learning: Applies to **/*.rs : Follow Rust best practices for error handling and memory management
Applied to files:
vm/Cargo.toml
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (2)
- GitHub Check: Run snippets and cpython tests (windows-latest)
- GitHub Check: Run rust tests (windows-latest)
🔇 Additional comments (7)
stdlib/Cargo.toml (2)
81-84: Check that removing the explicitlibbz2-rs-sysfeature still links correctly on all targets
bzip2 = "0.6"now enableslibbz2-rs-sysimplicitly.
On some CI images the C library is absent, causing the crate to fall back to the pure-Rust implementation and significantly slow downbz2handling in thebz2module.Please verify that:
- Native
libbz2is available (or intentionally not) on every tier-1 platform you ship binaries for.- The crate still compiles for
wasm32and otherno_std/cross-compile targets.If you rely on the native path, consider pinning
bzip2 = { version = "0.6", default-features = false, features = ["libbz2-rs-sys"] }so future upstream default-feature changes don’t silently alter behaviour.
105-107: Minorgethostnamebump looks safe
gethostname1.0.2 only fixes build warnings; no API changes.
Good to merge.Cargo.toml (3)
165-170:bitflags2.9.1 upgrade – watch for the newserdegatingStarting with 2.8 the
serdefeature was renamed toserde(wasserde_derivepre-2.0) and defaults changed.
Nothing in the workspace opts into that feature today, but if downstream crates rely onSerialize/Deserializeyou may needbitflags = { version = "2.9.1", features = ["serde"] }Otherwise 👍.
178-181:indexmap2.10.0 – confirm MSRV bump2.9 raised the MSRV to 1.70. Ensure the workspace toolchain (currently 1.85) remains ≥ that in CI.
No API breakage, so fine otherwise.
223-226:widestring1.2.0 contains a small API addition onlyNo breaking changes; good to go.
vm/Cargo.toml (2)
109-111:num_cpus1.17.0 – LGTMPatch release, no API changes.
99-103: No deprecated which_in_all usage found; upgrade to which 8 is safe.Ran a repository-wide search for
which_in_all(and found no matches. There are no call‐sites to replace with the iterator API.
✨ Finishing Touches
🧪 Generate unit tests
- Create PR with unit tests
- Post copyable unit tests in a comment
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.
🪧 Tips
Chat
There are 3 ways to chat with CodeRabbit:
- Review comments: Directly reply to a review comment made by CodeRabbit. Example:
I pushed a fix in commit <commit_id>, please review it.Explain this complex logic.Open a follow-up GitHub issue for this discussion.
- Files and specific lines of code (under the "Files changed" tab): Tag
@coderabbitaiin a new review comment at the desired location with your query. Examples:@coderabbitai explain this code block.@coderabbitai modularize this function.
- PR comments: Tag
@coderabbitaiin a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:@coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.@coderabbitai read src/utils.ts and explain its main purpose.@coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.@coderabbitai help me debug CodeRabbit configuration file.
Support
Need help? Create a ticket on our support page for assistance with any issues or questions.
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.
CodeRabbit Commands (Invoked using PR comments)
@coderabbitai pauseto pause the reviews on a PR.@coderabbitai resumeto resume the paused reviews.@coderabbitai reviewto trigger an incremental review. This is useful when automatic reviews are disabled for the repository.@coderabbitai full reviewto do a full review from scratch and review all the files again.@coderabbitai summaryto regenerate the summary of the PR.@coderabbitai generate docstringsto generate docstrings for this PR.@coderabbitai generate sequence diagramto generate a sequence diagram of the changes in this PR.@coderabbitai generate unit teststo generate unit tests for this PR.@coderabbitai resolveresolve all the CodeRabbit review comments.@coderabbitai configurationto show the current CodeRabbit configuration for the repository.@coderabbitai helpto get help.
Other keywords and placeholders
- Add
@coderabbitai ignoreanywhere in the PR description to prevent this PR from being reviewed. - Add
@coderabbitai summaryto generate the high-level summary at a specific location in the PR description. - Add
@coderabbitaianywhere in the PR title to generate the title automatically.
Documentation and Community
- Visit our Documentation for detailed information on how to use CodeRabbit.
- Join our Discord Community to get help, request features, and share feedback.
- Follow us on X/Twitter for updates and announcements.