Skip to content

fix(deps): drop unused testcontainers-modules, unblocking the whole cargo column - #840

Merged
hyperpolymath merged 1 commit into
mainfrom
fix/cargo-testcontainers
Sep 22, 2026
Merged

hyperpolymath merged 1 commit into
mainfrom
fix/cargo-testcontainers

Conversation

@hyperpolymath

Copy link
Copy Markdown
Owner

Fixes the dependency resolution failure reported in #838.

What was wrong

integration/Cargo.toml required testcontainers = "0.28" and
testcontainers-modules = "0.15" simultaneously. testcontainers-modules
0.15.0 still requires testcontainers ^0.27, so the pair was unsatisfiable.
Cargo failed at resolution — before compiling a single line.

Because resolution precedes every cargo subcommand, this one pair reddened
five checks that name unrelated subjects. Build AsciiDoc is the clearest
case: it is not an AsciiDoc failure. Step-level breakdown of job
106870727862 shows Build main documentation success, Build PDF documentation success, then Generate Rust API documentation failure.

Removal, not a version bump — stated plainly

There is no version pair that works. As of 2026-09-22, crates.io shows
testcontainers newest = 0.28.0 and testcontainers-modules newest =
0.15.0, which requires testcontainers ^0.27. The modules crate lags.
The only two arms were downgrade testcontainers to 0.27, or remove the
modules crate.

Removal is correct here because the crate was never used:

  • git grep -rn 'testcontainers_modules' returns no hits — no Rust code
    imports it.
  • Dragonfly/Redis is provisioned by integration/compose.test.yaml and
    reached via the DRAGONFLY_URL env var (integration/src/lib.rs:109-110),
    not by testcontainers.
  • The only testcontainers usage, integration/tests/arangodb_test.rs, uses
    stable core API only (GenericImage, AsyncRunner, WaitFor, ImageExt).

So the crate that broke the entire workspace contributed nothing. Keeping
0.28 and dropping the unused dep holds the newest release and shrinks the
trusted base by 8 packages — including ureq, a second HTTP client the
workspace did not need alongside reqwest.

Reviewing the lockfile

.gitattributes:52 sets Cargo.lock text eol=lf -diff, deliberately, so
lockfile churn stays out of review. git diff therefore reports it as
Bin 123167 -> 121105 bytes. Use git diff --text to read it.

Removed (8): ppv-lite86, rand, rand_chacha, rand_core,
testcontainers-modules, ureq, ureq-proto, utf8-zero. Added: none.

The rand removals are duplicate-version removals, not a loss —
rand v0.10.2 and rand_core v0.10.1 remain, and
cargo tree -p hypatia-integration-tests -i rand shows rand v0.10.2 still
required by bollard v0.21.1, ferroid v2.0.0 and this crate directly.
The dropped entries were older duplicates pulled in transitively by
testcontainers-modules and ureq.

Measured locally, in a worktree off origin/main

Before, on origin/main: cargo metadata → rc=101, the resolution error.

After, on this branch — every previously-red gate:

Command rc
cargo metadata --locked 0
cargo check --workspace --all-targets --locked 0
cargo fmt --all --check 0
cargo clippy --workspace --all-targets -- -D warnings 0
cargo test --workspace --all-targets 0
cargo test --workspace --doc 0 (4 passed)
cargo doc --workspace --no-deps --document-private-items 0

The last is the exact command from quality.yml:122 — the step
Build AsciiDoc actually dies in. It now succeeds.

Acceptance criteria from #838

  1. Met — cargo metadata --locked and cargo check --workspace --locked
    both rc=0. Resolved by removing the unusable dep after checking the
    published matrix, not by guessing.
  2. To be evidenced from /commits/<head>/check-runs on this PR, then on
    main after merge.
  3. Build AsciiDoc — cargo doc passes locally; CI will confirm. Any
    residual failure is a different fault and gets its own issue, per the AC.
  4. Half met. Cargo.lock is committed and updated here. The other half —
    making CI pass --locked — is not in this PR: no cargo invocation in
    any workflow currently uses --locked (measured: zero hits across all of
    .github/workflows/), and this session's token lacks the workflow scope,
    so it cannot push workflow edits. Filed as a follow-up rather than left
    silently unticked.
  5. Met, by the pre-existing state. main itself is the mutant: it carries
    the incompatible pair and cargo metadata there returns rc=101 with the
    resolution error, as recorded in The whole red cargo column on main is one unsatisfiable pair: testcontainers ^0.28 vs testcontainers-modules ^0.15 #838 from run 35763405727. The failure
    is at resolution, as required.

Because ACs 2–4 are not fully satisfied by this PR alone, this is Refs #838,
not Closes #838. The issue should close once the cargo column is observed
green on main.

🤖 Generated with Claude Code

https://claude.ai/code/session_0113HQM9LVGkNCzU1WwkJZSV

…argo column

`integration/Cargo.toml` required `testcontainers = "0.28"` and
`testcontainers-modules = "0.15"` together. testcontainers-modules 0.15.0 --
the newest published release as of 2026-09-22 -- still requires
`testcontainers ^0.27`, so the pair was unsatisfiable and cargo failed at
*resolution*, before compiling anything:

    error: failed to select a version for `testcontainers`
      required by package `testcontainers-modules v0.15.0`
      versions that meet the requirements `^0.27.0` are: 0.27.3 ... 0.27.0
      previously selected package `bollard v0.21.0`
        which satisfies dependency `bollard = "^0.21.0"` of `testcontainers v0.28.0`

Because resolution precedes every cargo subcommand, this one pair reddened
five checks that name unrelated subjects: Build AsciiDoc, Cargo check +
clippy + fmt, Check, Clippy and Test. `Build AsciiDoc` in particular is not
an AsciiDoc failure -- both its AsciiDoc steps pass and it dies later, in
"Generate Rust API documentation".

Removed rather than downgraded, because the crate was contributing nothing:

  - `git grep testcontainers_modules` finds no Rust code importing it.
  - Dragonfly/Redis is provisioned by `integration/compose.test.yaml` and
    reached via the `DRAGONFLY_URL` env var (`integration/src/lib.rs:109`),
    not by testcontainers.
  - The only testcontainers use, `integration/tests/arangodb_test.rs`, is
    stable core API (`GenericImage`, `AsyncRunner`, `WaitFor`, `ImageExt`).

Keeping `testcontainers 0.28` and dropping the unused dep is preferable to
downgrading to 0.27: it holds the newest release and shrinks the trusted
base by 8 packages (ppv-lite86, rand, rand_chacha, rand_core,
testcontainers-modules, ureq, ureq-proto, utf8-zero), including a second
HTTP client. The `rand` entries removed were older duplicate versions;
`rand v0.10.2` remains, still required by bollard, ferroid and this crate
directly.

Note for reviewers: `.gitattributes:52` marks `Cargo.lock` as `-diff`, so
`git diff` reports it as binary. Use `git diff --text` to read it.

Refs #838

Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_0113HQM9LVGkNCzU1WwkJZSV
@coderabbitai

coderabbitai Bot commented Sep 22, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

Navigate logical layers of code changes, visualize relationships, and explore their blast radius.

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Advanced

Run ID: 967617af-a66b-401a-8510-92f0ca286575

📥 Commits

Reviewing files that changed from the base of the PR and between c18608e and b88ec5a.

⛔ Files ignored due to path filters (1)
  • Cargo.lock is excluded by !**/*.lock
📒 Files selected for processing (1)
  • integration/Cargo.toml

Included review availability: Your plan provides up to 1 included review per hour; 0 remain after this review.

📜 Recent review details
⏰ Context from checks skipped due to timeout. (25)
  • GitHub Check: Dogfooding compliance summary
  • GitHub Check: governance / Validate Hypatia Baseline
  • GitHub Check: Escript packaging soundness
  • GitHub Check: scan / gitleaks
  • GitHub Check: governance / Exemption ratchet
  • GitHub Check: governance / Well-Known (RFC 9116 + RSR)
  • GitHub Check: governance / Workflow security linter
  • GitHub Check: governance / Code quality + docs
  • GitHub Check: governance / Actions lockfile verify
  • GitHub Check: governance / Trusted-base reduction policy
  • GitHub Check: governance / Guix packaging policy (Nix retired)
  • GitHub Check: governance / Debt ratchet
  • GitHub Check: governance / Licence consistency
  • GitHub Check: governance / Live Actions policy (credentialed advisory)
  • GitHub Check: hypatia / Hypatia Neurosymbolic Analysis
  • GitHub Check: Validate Documentation
  • GitHub Check: Build AsciiDoc
  • GitHub Check: abi-codegen-drift
  • GitHub Check: Clippy
  • GitHub Check: Cargo check + clippy + fmt
  • GitHub Check: zig build test (FFI + wire contract)
  • GitHub Check: Test
  • GitHub Check: Check
  • GitHub Check: Escript packaging soundness
  • GitHub Check: Build AsciiDoc
🔇 Additional comments (1)
integration/Cargo.toml (1)

47-52: LGTM!


📝 Summary

Summary by CodeRabbit

  • Bug Fixes
    • Resolved dependency installation and resolution failures affecting integration test setup.
    • Integration tests continue to connect to the provisioned Dragonfly/Redis service through the configured URL.

Walkthrough

The integration manifest removes the incompatible testcontainers-modules dependency. Its comment documents Dragonfly/Redis provisioning through compose.test.yaml and DRAGONFLY_URL.

Changes

Integration dependency resolution

Layer / File(s) Summary
Dependency declaration
integration/Cargo.toml
Removes testcontainers-modules and documents the incompatible version requirements and the existing Dragonfly/Redis connection path.

Priority: ➖ Normal

Estimated code review effort: 1 (Trivial) | ~5 minutes

Change: Bug fix · Severity of issue fixed: Medium

Merge Risk: ⚪ Minimal · up to b88ec

The dependency removal is safe based on the reachable integration code and documented Compose provisioning path.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Linked Issues check ⚠️ Warning PR #840 fixes the incompatible dependency pair in [#838] by removing the unused testcontainers-modules = "0.15" dependency and retaining testcontainers = "0.28". The reported local checks support … Update the affected CI workflow commands to use --locked. Provide successful check-run evidence for the required workflows. Reintroduce the incompatible dependency pair in a guard branch and confirm that resolution fails. Confirm that the…
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly identifies the main change: removing the unused testcontainers-modules dependency to resolve the Cargo dependency failure.
Description check ✅ Passed The description is directly related to the changeset. It explains the incompatible dependency pair, the reason for removal, the affected checks, and the validation results.
Out of Scope Changes check ✅ Passed The reviewed changes remove the unused incompatible dependency, retain the required testcontainers dependency, update the related dependency explanation, and update the lockfile according to the PR …
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff. Analyzed 0 functions across 0…
Full details: Linked Issues check

Explanation

PR #840 fixes the incompatible dependency pair in [#838] by removing the unused testcontainers-modules = "0.15" dependency and retaining testcontainers = "0.28". The reported local checks support successful resolution and compilation. However, the PR does not update CI commands to use --locked, does not provide the required post-merge check-run evidence, and does not perform the mutant guard verification requested by [#838]. Cargo.lock is an ignored review path, so its committed state cannot be independently verified here.

Resolution

Update the affected CI workflow commands to use --locked. Provide successful check-run evidence for the required workflows. Reintroduce the incompatible dependency pair in a guard branch and confirm that resolution fails. Confirm that the updated Cargo.lock is committed.

  • Fix all pre-merge checks with AI

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

A rabbit checks the cargo nest
One tangled crate has gone to rest
Dragonfly waits by compose’s door
DRAGONFLY_URL shows the route once more
Clean resolutions hop ashore

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

@hyperpolymath
hyperpolymath merged commit 4fa2e39 into main Sep 22, 2026
55 of 57 checks passed
@hyperpolymath
hyperpolymath deleted the fix/cargo-testcontainers branch September 22, 2026 18:26
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.

1 participant