Skip to content

LAB: apr-cli test-target clippy red on main (crux_f_17 unwraps, nf4_classifier unused mut) #5202

Closed as not planned

Description

@noahgift

cargo clippy -p apr-cli --lib --tests -- -D warnings is red on main (reported 2026-10-12):

  • crates/apr-cli/tests/falsification_crux_f_17.rs: unwrap() on json! values (banned by .clippy.toml disallowed-methods).
  • crates/apr-cli/src/commands/nf4_classifier.rs (test module, ~line 273): a let mut closure that needs no mut.

LAB, not GATE. No merge or release path lints apr-cli test targets:

  • sov.lint (ci/vendor/sovereign-ci.yml) runs cargo clippy --all-targets at the workspace root, which lints only the root facade package (no default-members).
  • scripts/check_clippy_cuda.sh lints -p apr-cli --features cuda without --tests/--all-targets, so test code is not in it.
  • scripts/check_clippy_feature_matrix.sh (toolchain-ceiling.yml, scheduled) uses --lib only.
  • release_ready.sh and dogfood.sh clippy rows run at the root facade.
  • No required job sets RUSTFLAGS=-D warnings for an apr-cli test build.

Fix: replace the unwraps with expect("…") and drop the mut, then prove cargo clippy -p apr-cli --lib --tests -- -D warnings clean.

Activity

  1. added this to the 0.71.1 milestone on Oct 12, 2026
  2. noahgift commented on Oct 12, 2026

    @noahgift
    ContributorAuthor

    Owner: aprender-a7n. Fix on branch fix/5202-apr-cli-test-clippy @ 12f199e (branch only; a PR waits for a slot).

    check before after
    cargo clippy --keep-going -p apr-cli --lib --tests -- -D warnings rc 101 (24 targets) rc 0
    planted unwrap() in a json!-header file — refused by clippy::unwrap_used
    cargo test -p apr-cli on the 22 changed targets — 237 passed, 0 failed, 2 ignored
    cargo test -p apr-cli --lib nf4_classifier — 21 passed

    143 test-setup unwrap() → expect("<ID>: test setup"); 137 json! sites covered by a file-level allow(disallowed_methods) + deny(unwrap_used) pair (json! expands to to_value(..).unwrap(); unwrap_used skips external macros, so hand-written unwraps stay refused). LAB ticket: no gate change.

  3. modified the milestones: 0.71.1, 0.72.0 on Oct 14, 2026
  4. noahgift commented on Oct 14, 2026

    @noahgift
    ContributorAuthor

    Folded into #5309 as a checklist row (TRIAGE-100, 2026-10-14): the open-ticket cap is 100, so this ticket is now tracked on that master and closed as not planned. Nothing is lost: reopen it when its work resumes, and an open PR for it reopens it. Pushed branch: fix/5202-apr-cli-test-clippy.

    Agent: aprender-clerk

  5. modified the milestones: 0.72.0, backlog on Oct 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions