Repository navigation
chore(deps): bump tokio to 1.54.1 - #11946
Merged
Merged
Conversation
tokio 1.54.0 (yanked) has a race between `Interval::poll_tick` and the multi-threaded runtime's time driver that can drop a timer entry the driver is still firing: a use-after-free in safe Rust (GHSA-5wjr-9356-4wc8). 1.54.1 reverts the change that introduced it (tokio-rs/tokio#8692). The floor is raised in Cargo.toml and bazel/rust.MODULE.bazel so that neither build can resolve 1.54.0 again. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Contributor
There was a problem hiding this comment.
🟢 Approval recommended
The focused patch upgrade is consistent across both build systems, with no blocking issues identified.
No open issues 🎉
What changed in this PR
Updates Tokio from 1.54.0 to 1.54.1 across Cargo and Bazel to address the interval timer race described in GHSA-5wjr-9356-4wc8.
Changes:
- Raises the minimum Tokio version in both build configurations.
- Synchronizes lockfile versions, checksums, and Bazel dependency references without changing features or unrelated dependencies.
| File | Description |
|---|---|
| Cargo.toml | Raises the workspace Tokio requirement to 1.54.1. |
| Cargo.lock | Updates Tokio’s locked version and checksum. |
| Cargo.Bazel.toml.lock | Updates Bazel’s Cargo lock entry for Tokio. |
| Cargo.Bazel.json.lock | Refreshes Tokio references, download metadata, and configuration checksum. |
| bazel/rust.MODULE.bazel | Raises Bazel’s Tokio requirement to 1.54.1. |
Review effort: Balanced
basvandijk
marked this pull request as ready for review
October 26, 2026 09:09
basvandijk
added a commit
that referenced
this pull request
Oct 26, 2026
Resolve the conflict with #11946 (tokio 1.54.1). Both PRs rewrote the top-level "checksum" line of Cargo.Bazel.json.lock; the rest of that file and the other lockfiles merged cleanly. `./bin/bazel-pin.sh` recomputed the checksum and changed nothing else. Co-Authored-By: Claude Opus 5.5 <[email protected]>
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.
Summary
Resolves the 2 open cargo Dependabot alerts for GHSA-5wjr-9356-4wc8 (medium), filed against
Cargo.lockandCargo.Bazel.toml.lock.Notes:
tokio::time::Interval::poll_tick(including.tick().await) can drop an internal timer entry while the multi-threaded runtime's time driver is firing it. That is a data race and use-after-free on the timer's waker and task state, which shows up as assertion panics, task ref-count corruption or heap corruption.SleepandTimeoutare not affected.tokio::time::intervalin p2p (consensus_manager's sender,peer_manager,state_sync_manager) and innns_delegation_manager, among others.rc--2026-10-23_03-29,rc--2026-10-24_03-27,rc--2026-10-25_03-29andrc--2026-10-26_03-33all contain it, and the earlier RCs do not. Release owners may want to avoid electing those four.cargo update -p tokio --precise 1.54.1also re-resolves unrelated multi-version edges onto versions that are already locked:hyper-util,quinnandquinn-udpmove from socket2 0.5.10 to 0.6.3, and several windows-sys edges move too. Master's lockfile is stable undercargo update --workspace, so the tokio unlock alone triggers this.Cargo.lockchanges just tokio'sversionandchecksum, and the checksum matches crates.io.cargo update --workspaceleaves that lockfile untouched ("Locking 0 packages"), andcargo fetch --lockedaccepts it.Cargo.tomlandbazel/rust.MODULE.bazel, so neither build can resolve 1.54.0 again.How regenerated
Test plan
cargo update --workspace && ./bin/bazel-pin.shis a no-op ("Locking 0 packages", "Nothing to repin."). This mirrors CI's lock-generate.cargo fetch --lockedbazel run //bazel:buildifier.checkbazel teston tokio 1.54.1 (confirmed in the query graph) for theIntervalusers above, 7/7 passed://rs/http_endpoints/nns_delegation_manager:nns_delegation_manager_test;//rs/p2p/consensus_manager,//rs/p2p/peer_managerand//rs/p2p/state_sync_manager.CI_ALL_BAZEL_TARGETS. That includesrust-lint.sh, which CI runs on*.toml/*.lockchanges.Cargo.Bazel.toml.lockalert closes oncebazel-dependency-submissionhas run on master.🤖 Generated with Claude Code