[PR #336] [MERGED] fix: restore Clippy compatibility with Rust 1.99 #358

Closed
opened 2026-10-29 14:22:35 +00:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/kvcache-ai/AgentENV/pull/336
Author: @yingdi-shan
Created: 10/1/2026
Status: ✅ Merged
Merged: 10/1/2026
Merged by: @yingdi-shan

Base: main ← Head: fix/rust-1.99-clippy


📝 Commits (1)

  • 1cc9e2f fix: restore Clippy compatibility with Rust 1.99

📊 Changes

2 files changed (+4 additions, -4 deletions)

View changed files

📝 Cargo.lock (+3 -3)
📝 storage/overlaybd/src/download_gate.rs (+1 -1)

📄 Description

What

Fix make clippy failures with Rust 1.99.0 by updating the locked async-trait version from 0.1.89 to 0.1.92 and replacing AtomicI64::fetch_update with try_update in the background download admission gate.

Why

Rust 1.99's clippy::double_must_use diagnoses the redundant #[must_use] attributes emitted by the old async-trait macro, including in generated API traits. Version 0.1.92 no longer emits those attributes. Rust 1.99 also deprecates fetch_update in favor of try_update. Both diagnostics fail the repository's -D warnings check.

None; small toolchain compatibility fix.

Scope and non-goals

Only the async-trait lockfile entry and one atomic method call change. No generated code edits, lint suppressions, unrelated dependency updates, or toolchain pinning.

Design and behavior changes

The atomic operation retains the same closure, memory orderings, and result handling. The dependency update removes the redundant macro-generated attribute and uses the already-locked syn 3.0.4.

Compatibility and operations

  • Public API or generated protocol: unchanged.
  • Configuration or defaults: unchanged; the toolchain continues to track stable.
  • Snapshot manifest, artifact layout, or storage format: unchanged.
  • Upgrade and rollback: ordinary rebuild; no state migration. Validated with Rust 1.99.0.
  • Host requirements, permissions, ports, or dependencies: async-trait updates to 0.1.92; no additional locked packages.

Validation

  • make fmt
  • make clippy
  • make test-unit
  • Relevant Rust integration tests
  • make -C services test (required when services/ changes)
  • Generated clients/server regenerated with the documented make target
  • Documentation updated
  • Benchmarks or performance comparison completed

Commands and results:

make fmt CARGO='cargo +1.99.0'                         PASS
make clippy CARGO='cargo +1.99.0'                      PASS
cargo +1.99.0 test -p overlaybd --lib download_gate::tests  PASS (7 tests)

Clippy checked the whole workspace with all targets/features and -D warnings. Cargo still reports an existing future-incompatibility notice for proc-macro-error2 2.0.1; it does not fail the target.

Skipped checks and reasons:

Full unit/capability and VM integration suites were not run for this dependency/atomic API compatibility patch. The existing download-gate unit tests cover the changed call; Clippy compiles all workspace targets. Go checks, code generation, documentation changes, and benchmarks are not applicable.

Risks and reviewer notes

The dependency update affects async-trait expansions across the workspace. All targets compile under the strict Clippy check. The atomic rename preserves admission behavior and sequentially consistent ordering.

Checklist

  • The PR contains one coherent change and no unrelated formatting or refactoring.
  • New behavior is covered by tests, or I explained why testing is impractical.
  • Logs and examples contain no credentials, tokens, or private registry information.
  • I did not manually edit generated code without updating its source and regenerating it.

🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/kvcache-ai/AgentENV/pull/336 **Author:** [@yingdi-shan](https://github.com/yingdi-shan) **Created:** 10/1/2026 **Status:** ✅ Merged **Merged:** 10/1/2026 **Merged by:** [@yingdi-shan](https://github.com/yingdi-shan) **Base:** `main` ← **Head:** `fix/rust-1.99-clippy` --- ### 📝 Commits (1) - [`1cc9e2f`](https://github.com/kvcache-ai/AgentENV/commit/1cc9e2f2ac9b5df7ee44607023383f1152cc027b) fix: restore Clippy compatibility with Rust 1.99 ### 📊 Changes **2 files changed** (+4 additions, -4 deletions) <details> <summary>View changed files</summary> 📝 `Cargo.lock` (+3 -3) 📝 `storage/overlaybd/src/download_gate.rs` (+1 -1) </details> ### 📄 Description ## What Fix `make clippy` failures with Rust 1.99.0 by updating the locked `async-trait` version from 0.1.89 to 0.1.92 and replacing `AtomicI64::fetch_update` with `try_update` in the background download admission gate. ## Why Rust 1.99's `clippy::double_must_use` diagnoses the redundant `#[must_use]` attributes emitted by the old `async-trait` macro, including in generated API traits. Version 0.1.92 no longer emits those attributes. Rust 1.99 also deprecates `fetch_update` in favor of `try_update`. Both diagnostics fail the repository's `-D warnings` check. ## Related issue None; small toolchain compatibility fix. ## Scope and non-goals Only the async-trait lockfile entry and one atomic method call change. No generated code edits, lint suppressions, unrelated dependency updates, or toolchain pinning. ## Design and behavior changes The atomic operation retains the same closure, memory orderings, and result handling. The dependency update removes the redundant macro-generated attribute and uses the already-locked syn 3.0.4. ## Compatibility and operations - Public API or generated protocol: unchanged. - Configuration or defaults: unchanged; the toolchain continues to track stable. - Snapshot manifest, artifact layout, or storage format: unchanged. - Upgrade and rollback: ordinary rebuild; no state migration. Validated with Rust 1.99.0. - Host requirements, permissions, ports, or dependencies: async-trait updates to 0.1.92; no additional locked packages. ## Validation - [x] `make fmt` - [x] `make clippy` - [ ] `make test-unit` - [ ] Relevant Rust integration tests - [ ] `make -C services test` (required when `services/` changes) - [ ] Generated clients/server regenerated with the documented `make` target - [ ] Documentation updated - [ ] Benchmarks or performance comparison completed Commands and results: ```text make fmt CARGO='cargo +1.99.0' PASS make clippy CARGO='cargo +1.99.0' PASS cargo +1.99.0 test -p overlaybd --lib download_gate::tests PASS (7 tests) ``` Clippy checked the whole workspace with all targets/features and `-D warnings`. Cargo still reports an existing future-incompatibility notice for proc-macro-error2 2.0.1; it does not fail the target. Skipped checks and reasons: Full unit/capability and VM integration suites were not run for this dependency/atomic API compatibility patch. The existing download-gate unit tests cover the changed call; Clippy compiles all workspace targets. Go checks, code generation, documentation changes, and benchmarks are not applicable. ## Risks and reviewer notes The dependency update affects async-trait expansions across the workspace. All targets compile under the strict Clippy check. The atomic rename preserves admission behavior and sequentially consistent ordering. ## Checklist - [x] The PR contains one coherent change and no unrelated formatting or refactoring. - [x] New behavior is covered by tests, or I explained why testing is impractical. - [x] Logs and examples contain no credentials, tokens, or private registry information. - [x] I did not manually edit generated code without updating its source and regenerating it. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-29 14:22:35 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
kvcache-ai/AgentENV#358
No description provided.