Skip to content

Conversation

@hanabi1224
Copy link
Contributor

@hanabi1224 hanabi1224 commented Dec 12, 2025

Summary of changes

Changes introduced in this pull request:

  • bump rust toolchain to 1.92.0
  • fix clippy warnings
  • avoid generating any debug information for dependencies as suggested by the cargo book

Reference issue to close (if applicable)

Closes

Other information and links

https://releases.rs/docs/1.92.0/

Change checklist

  • I have performed a self-review of my own code,
  • I have made corresponding changes to the documentation. All new code adheres to the team's documentation standards,
  • I have added tests that prove my fix is effective or that my feature works (if possible),
  • I have made sure the CHANGELOG is up-to-date. All user-facing changes should be reflected in this document.

Summary by CodeRabbit

  • Chores
    • Updated Rust toolchain to version 1.92.0
    • Optimized build configuration for improved debugging capabilities and reduced dependency debug overhead

✏️ Tip: You can customize this high-level summary in your review settings.

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Dec 12, 2025

Walkthrough

The PR updates the Rust toolchain from 1.91.0 to 1.92.0, adjusts debug profiling settings in Cargo.toml to enable line-table-only debug information in dev builds with unpacked split-debuginfo, suppresses debug info for dependencies, and performs import cleanup in two source files.

Changes

Cohort / File(s) Summary
Build & Toolchain Configuration
Cargo.toml, rust-toolchain.toml
Updates Rust toolchain to 1.92.0; modifies dev profile debug settings to use "line-tables-only" with unpacked split-debuginfo; adds per-package debug control to suppress debug info for all dependencies; updates debugging profile with full debug info and split-debuginfo off.
Import Cleanup
src/chain_sync/tipset_syncer.rs, src/wallet/subcommands/wallet_cmd.rs
Removes unused error import from tracing prelude in tipset_syncer.rs; adjusts clap imports in wallet_cmd.rs to import clap::Subcommand directly instead of named arg import.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~15 minutes

  • Cargo.toml profile changes: Review implications of debug settings on build performance and binary size across three profile sections
  • Rust toolchain bump: Verify compatibility with 1.92.0 and check for any breaking changes
  • Import adjustments: Verify no functionality affected by import reorganization

Possibly related PRs

Suggested labels

rust

Suggested reviewers

  • akaladarshi
  • sudo-shashank
  • LesnyRumcajs

Pre-merge checks and finishing touches

✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'chore: bump rust toolchain to 1.92.0' directly and clearly summarizes the primary change in the PR—updating the Rust toolchain version. However, the changeset includes two additional substantive modifications: Clippy warning fixes and debug info optimization in Cargo.toml, which are not mentioned in the title.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch hm/rust-1.92

📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 8093469 and b542736.

📒 Files selected for processing (4)
  • Cargo.toml (1 hunks)
  • rust-toolchain.toml (1 hunks)
  • src/chain_sync/tipset_syncer.rs (1 hunks)
  • src/wallet/subcommands/wallet_cmd.rs (1 hunks)
🧰 Additional context used
🧠 Learnings (8)
📓 Common learnings
Learnt from: hanabi1224
Repo: ChainSafe/forest PR: 5867
File: src/ipld/util.rs:553-558
Timestamp: 2025-08-08T12:10:45.218Z
Learning: Forest pins Rust toolchain to 1.89.0 via rust-toolchain.toml; features stabilized in 1.88 (e.g., let-chains) are acceptable in this codebase.
Learnt from: hanabi1224
Repo: ChainSafe/forest PR: 5867
File: src/ipld/util.rs:553-558
Timestamp: 2025-08-08T12:10:45.218Z
Learning: Forest project targets Rust stable >=1.89; features stabilized in 1.88 like let-chains are acceptable in this codebase.
Learnt from: hanabi1224
Repo: ChainSafe/forest PR: 5930
File: build.rs:64-77
Timestamp: 2025-08-13T09:43:20.301Z
Learning: hanabi1224 prefers hard compile-time errors in build scripts rather than runtime safeguards or collision detection, believing it's better to fail fast and fix root causes of issues like malformed snapshot names.
Learnt from: hanabi1224
Repo: ChainSafe/forest PR: 6057
File: src/cli/subcommands/f3_cmd.rs:0-0
Timestamp: 2025-09-09T10:37:17.947Z
Learning: hanabi1224 prefers having default timeouts (like 10m for --no-progress-timeout) to prevent commands from hanging indefinitely, even when the timeout flag isn't explicitly provided by users. This fail-fast approach is preferred over requiring explicit flag usage.
📚 Learning: 2025-08-07T13:39:15.107Z
Learnt from: hanabi1224
Repo: ChainSafe/forest PR: 5886
File: interop-tests/src/tests/go_app/gen.go:29-29
Timestamp: 2025-08-07T13:39:15.107Z
Learning: Auto-generated files like those created by rust2go (indicated by "Generated by rust2go. Please DO NOT edit this C part manually." comment) in the Forest project should be skipped during code review as they are not intended for manual editing.

Applied to files:

  • Cargo.toml
📚 Learning: 2025-08-08T12:10:45.218Z
Learnt from: hanabi1224
Repo: ChainSafe/forest PR: 5867
File: src/ipld/util.rs:553-558
Timestamp: 2025-08-08T12:10:45.218Z
Learning: Forest project targets Rust stable >=1.89; features stabilized in 1.88 like let-chains are acceptable in this codebase.

Applied to files:

  • Cargo.toml
  • rust-toolchain.toml
📚 Learning: 2025-10-17T09:36:15.757Z
Learnt from: elmattic
Repo: ChainSafe/forest PR: 6128
File: src/ipld/util.rs:23-30
Timestamp: 2025-10-17T09:36:15.757Z
Learning: Always run `cargo check` or `cargo build` to verify actual compilation errors in the Forest codebase before flagging them as issues. Do not rely solely on documentation or assumptions about trait implementations.

Applied to files:

  • Cargo.toml
📚 Learning: 2025-08-08T12:10:45.218Z
Learnt from: hanabi1224
Repo: ChainSafe/forest PR: 5867
File: src/ipld/util.rs:553-558
Timestamp: 2025-08-08T12:10:45.218Z
Learning: Forest pins Rust toolchain to 1.89.0 via rust-toolchain.toml; features stabilized in 1.88 (e.g., let-chains) are acceptable in this codebase.

Applied to files:

  • Cargo.toml
  • rust-toolchain.toml
📚 Learning: 2025-08-07T13:39:29.732Z
Learnt from: hanabi1224
Repo: ChainSafe/forest PR: 5886
File: interop-tests/src/tests/go_app/gen.go:58-58
Timestamp: 2025-08-07T13:39:29.732Z
Learning: In the Forest project, auto-generated files (like those generated by rust2go tool) should be skipped during code review as they are not meant to be manually edited.

Applied to files:

  • Cargo.toml
📚 Learning: 2025-08-07T13:39:36.962Z
Learnt from: hanabi1224
Repo: ChainSafe/forest PR: 5886
File: interop-tests/src/tests/go_app/gen.go:88-90
Timestamp: 2025-08-07T13:39:36.962Z
Learning: Skip reviewing auto-generated files marked with "Generated by rust2go. Please DO NOT edit this C part manually." as these should not be manually edited and any issues should be addressed in the code generation tool or source templates instead.

Applied to files:

  • Cargo.toml
📚 Learning: 2025-08-08T12:11:55.266Z
Learnt from: hanabi1224
Repo: ChainSafe/forest PR: 5867
File: src/ipld/util.rs:461-487
Timestamp: 2025-08-08T12:11:55.266Z
Learning: Forest (src/ipld/util.rs, Rust): In UnorderedChainStream::poll_next, dropping `extract_sender` (when no more tipsets and the extract queue is empty) is the intended shutdown signal for workers. Any subsequent attempt to enqueue work after this drop is a logic error and should be treated as an error; do not change `send()` to ignore a missing sender.

Applied to files:

  • src/chain_sync/tipset_syncer.rs
⏰ 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). (21)
  • GitHub Check: tests
  • GitHub Check: tests-release
  • GitHub Check: Build forest binaries on Linux AMD64
  • GitHub Check: Coverage
  • GitHub Check: db-migration-checks
  • GitHub Check: Bootstrap checks - Forest
  • GitHub Check: Devnet checks
  • GitHub Check: Diff snapshot export checks
  • GitHub Check: Calibnet no discovery checks
  • GitHub Check: Bootstrap checks - Lotus
  • GitHub Check: Calibnet api test-stateful check
  • GitHub Check: V2 snapshot export checks
  • GitHub Check: Forest CLI checks
  • GitHub Check: State migrations
  • GitHub Check: Calibnet eth mapping check
  • GitHub Check: Calibnet stateless RPC check
  • GitHub Check: Calibnet stateless mode check
  • GitHub Check: Wallet tests
  • GitHub Check: Calibnet kademlia checks
  • GitHub Check: Calibnet check
  • GitHub Check: All lint checks
🔇 Additional comments (4)
src/wallet/subcommands/wallet_cmd.rs (1)

38-38: Import cleanup looks safe; #[arg(...)] doesn’t need clap::arg in scope.

rust-toolchain.toml (1)

2-2: Toolchain bump is reasonable; please verify CI and any downstream MSRV expectations.

src/chain_sync/tipset_syncer.rs (1)

36-36: The import change is safe. No error! macro calls remain in this module after removing it from the tracing import.

Cargo.toml (1)

266-274: Profile settings are appropriate for Linux/macOS targets. The [profile.dev.package."*"] debug override inherits into derived profiles (e.g., profile.profiling), as documented in Cargo's profile inheritance rules—this is expected behavior. The split-debuginfo="unpacked" setting is not supported on Windows, but native Windows builds are not part of the CI matrix (Docker containers are the documented Windows deployment option). The debug="line-tables-only" setting is stable (Rust 1.71+) and well-supported on LLVM-based toolchains used by this project. No changes required.


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

@hanabi1224 hanabi1224 marked this pull request as ready for review December 12, 2025 15:39
@hanabi1224 hanabi1224 requested a review from a team as a code owner December 12, 2025 15:39
@hanabi1224 hanabi1224 requested review from LesnyRumcajs and akaladarshi and removed request for a team December 12, 2025 15:39
@codecov
Copy link

codecov bot commented Dec 12, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 40.09%. Comparing base (8093469) to head (b542736).
⚠️ Report is 2 commits behind head on main.

Additional details and impacted files
Files with missing lines Coverage Δ
src/chain_sync/tipset_syncer.rs 0.00% <ø> (ø)
src/wallet/subcommands/wallet_cmd.rs 0.00% <ø> (ø)

... and 8 files with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 8093469...b542736. Read the comment docs.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

debug = "line-tables-only"
split-debuginfo = "unpacked"

# Avoid generating any debug information for dependencies
Copy link
Member

Choose a reason for hiding this comment

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

Oh cool, I wonder if we could now run the coverage on a regular GH worker?

@hanabi1224 hanabi1224 enabled auto-merge December 12, 2025 16:02
@hanabi1224 hanabi1224 added this pull request to the merge queue Dec 12, 2025
Merged via the queue into main with commit a9fee74 Dec 12, 2025
49 of 50 checks passed
@hanabi1224 hanabi1224 deleted the hm/rust-1.92 branch December 12, 2025 16:34
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.

4 participants