Skip to content

ci(dylint): Dylint job is red on main — alias-loop workaround fails, so NO custom lints are enforced #964

Description

@zackees

Context

The Dylint workflow check is failure on main HEAD (and on every PR — I saw it fail on #946, #948, #949, #956, #958, #961, #963). The "Run dylint over workspace" step exhausts its retry loop:

Error: Could not find `.../target/dylint/libraries/nightly-2026-03-26-x86_64-unknown-linux-gnu/release/libban_bare_reqwest@nightly-2026-03-26-x86_64-unknown-linux-gnu.so` despite successful build
... (same for ban_raw_subprocess, ban_manual_slash_normalize, ban_print_in_production, ban_raw_path_prefix_compare, and the rest)
echo "::error::cargo dylint did not succeed after ${max_attempts} attempts"

The workaround loop in .github/workflows/dylint.yml (aliasing cargo's bare <name>.<ext> to the <name>@<toolchain>.<ext> cargo-dylint 5.0.0 expects) is not converging — every lint library fails the @<toolchain> lookup "despite successful build", across all ~24 lints.

Impact

None of the custom dylints are actually enforced in CI. They compile and their unit tests pass, but the workspace-wide cargo dylint --all run never completes green, so a violation would not fail CI. The guardrails (ban_raw_subprocess, ban_std_pathbuf, ban_manual_slash_normalize, the new ban_raw_path_prefix_compare, etc.) are dormant.

Proposal

  • Diagnose why the alias loop doesn't converge under the pinned cargo-dylint 5.0.0 + custom driver (does cargo-dylint rebuild and re-emit bare names each attempt, wiping the aliases? is the library dir path wrong?).
  • Likely fixes: bump cargo-dylint to a version that emits @<toolchain>-suffixed libraries natively, or alias once up-front and prevent the rebuild, or point --library-path at the aliased copies.

Acceptance criteria

  • Dylint check is green on main.
  • A deliberate violation of any lint (e.g. a raw Command::spawn or Path::starts_with added to a crates/*/src file) fails the Dylint check.

Decisions

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    Status
    Triage

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions