Skip to content

test(e2e): assert the real bundle pull's unmatched-pattern warning on stderr - #2790

Merged
thiras merged 3 commits into
mainfrom
fix/2672-real-pull-unmatched-warning
Oct 31, 2026
Merged

thiras merged 3 commits into
mainfrom
fix/2672-real-pull-unmatched-warning

Conversation

@yigitdot

@yigitdot yigitdot commented Oct 30, 2026 •

Copy link
Copy Markdown
Contributor

A real (non-dry-run) decdn get 'decdn:<hash>/' prints each unmatched --include/--exclude pattern on stderr through EntryFilter::apply_and_warn, called from obtain_manifest. Only the dry-run path had a subprocess test (#2671). This adds an anvil-e2e journey that runs the real path through the binary, with no node and no funds:

  • ChainFixture for the one chain read (PaymentPool.usdc() in BundlePullerBuilder::build) and a fresh, unfunded buyer keystore.
  • --node-id/--provider-address pin a node, so selection reads no CapacityBond registry.
  • The manifest is seeded by hand into the output root's manifest cache, so no manifest fetch happens.

Two runs share one anvil:

  1. --exclude 'metal/*' --exclude '**' keeps no entry. The run ends at report_nothing_to_fetch, exits 0, and adds nothing to the output root.
  2. --exclude 'metal/*' alone keeps both entries: the run that would go on to pay. A --receipt at the path one entry lands at makes guard_selection refuse the run after the filter, before any dial. No entry lands.

Each run asserts that stderr carries warning: --exclude 'metal/*' matched no entries with the did you mean '**/metal/*' hint exactly once, and that stdout carries neither. The CLI runs through tokio::process::Command with kill_on_drop, so the test's overall timeout bounds a regression that hangs.

Mutation checks against apply_and_warn: dropping the eprintln! fails run 1, and warning only when the filters keep nothing passes run 1 but fails run 2.

The review found that this test's empty-set exit prints prose under --json. That production bug is filed separately as #2800.

Closes #2672

🤖 Generated with Claude Code

Copilot AI balanced review requested due to automatic review settings October 30, 2026 22:46

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota. Try requesting a review at a lower effort level.

An organization owner can choose the repository organization as the billing source for reviews requested by members with a paid Copilot license. Learn about Copilot code review billing.

@github-code-quality

github-code-quality Bot commented Oct 30, 2026 •

Copy link
Copy Markdown

Code coverage overview

Languages: Rust

Rust / code-coverage/cargo-llvm-cov

main 0bd2393 fix/2672-real-pull-u... 235a3a4 +/-
77% 77% 0%
View coverage of the 4 most impacted files.
File main 0bd2393 fix/2672-real-pull-u... 235a3a4 +/-
crates/client/src/scheduler.rs 95% 94% -1%
crates/node/src...nt/serve_leg.rs 91% 90% -1%
crates/client/src/lib.rs 89% 89% 0%
crates/node/src...gin/pull_leg.rs 84% 84% 0%

ℹ️ Calculations represent line coverage. Results may change as calculations are updated.


Updated October 31, 2026 01:06 UTC

@yigitdot
yigitdot requested a review from thiras October 31, 2026 01:24
@thiras
thiras merged commit 23b559b into main Oct 31, 2026
39 checks passed
@thiras
thiras deleted the fix/2672-real-pull-unmatched-warning branch October 31, 2026 01: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.

test(e2e): assert the real bundle pull's unmatched-pattern warning on stderr

3 participants