Skip to content

Fix unrelated package installation in chroot builds without LocalRepo - #1579

Open
2asoft wants to merge 6 commits into
Morganamilo:masterfrom
2asoft:aasoft/chroot_real_deps
Open

2asoft wants to merge 6 commits into
Morganamilo:masterfrom
2asoft:aasoft/chroot_real_deps

Conversation

@2asoft

@2asoft 2asoft commented Jul 31, 2026

Copy link
Copy Markdown

Fixes #1578.
When Chroot is enabled and LocalRepo is unset, pass only previously built artifacts required by the current package's declared dependency closure.

This preserves AUR build dependencies, including versioned providers and active check dependencies, without installing unrelated earlier build outputs into later chroots.

Tests:

  • cargo fmt --check
  • cargo test --lib
  • cargo build --release
  • Real clean-chroot update with multiple independent and dependent AUR packages

@2asoft
2asoft force-pushed the aasoft/chroot_real_deps branch from cb3bd9a to e13bb07 Compare October 5, 2026 21:05
@2asoft
2asoft force-pushed the aasoft/chroot_real_deps branch from e13bb07 to f460212 Compare October 27, 2026 20:11
Replace both inline chroot argument collections with the same helper. Keep injecting every recorded archive when LocalRepo is disabled. Rename queue_install to describe its existing archive-recording responsibility; retain its implementation and Vec storage unchanged.
Change the extracted archive helpers to record actual package metadata and select only usable dependency archives for each consuming package. Preserve per-consumer resolver preferences and runtime closure; defer unavailable, incompatible, or ambiguous choices to native chroot resolution. Include focused selector and installer regression tests.
Keep old SRCINFO only for fetch decisions, then reload the merged checkout before deriving build requirements. Cover an upgrade that replaces an old dependency with a newly required archive.
Remove nonexistent debug package paths before archive metadata loading. Keep the regression with this independently reviewable behavior change.
Add real chroot coverage for provider isolation, checks, runtime repository dependencies, failed provider fallback, and unsatisfied requirements. Document the unit and live verification commands.
Document optional LocalRepo, injection of usable dependency archives, and normal chroot resolution when an archive is unavailable. Failed build targets remain reported.
@2asoft
2asoft force-pushed the aasoft/chroot_real_deps branch from f460212 to 5ee40ee Compare October 28, 2026 17:23
@Tiagoquix

Copy link
Copy Markdown

CC @pfeifferj - could you please take a look at this? It seems to be an important issue. Thanks.

@pfeifferj

pfeifferj commented Nov 13, 2026 •

Copy link
Copy Markdown
Collaborator

I started looking over the code and noticed a lot of slop comments describing the development process (e.g. before this did x...) which does not belong in comments. pls do a thorough self-review of the PR first

no offense but I don't feel good about investing time into reviews if my comments just get copy pasted back into an LLM and contributors don't understand the code they're submitting tbh

@Tiagoquix

Copy link
Copy Markdown

Thanks for that. I agree with your position; no point in checking if it looks like LLM code.

@2asoft

2asoft commented Nov 14, 2026

Copy link
Copy Markdown
Author

I started looking over the code

Thanks for taking a look.

a lot of slop comments describing the development process (e.g. before this did x...) which does not belong in comments. pls do a thorough self-review of the PR first

Indeed I only had a cursory glance at this iteration to weed out anything obviously wrong, and it wasnt meant for the PR before further review from me.

no offense but I don't feel good about investing time into reviews if my comments just get copy pasted back into an LLM and contributors don't understand the code they're submitting tbh

Justified, and I wouldnt either, in the current state the PR is in. I'll clean it up and slim down to just the minimal required change, and we can go from there to adjust to paru's codebase requirements, if you're still willing to invest the time.

@pfeifferj

pfeifferj commented Nov 14, 2026 •

Copy link
Copy Markdown
Collaborator

thank you, just ping me when it's ready and I'll take another look. I appreciate you wanting to clean things up

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Excessive aur package build times when using chroot builds without LocalRepo

3 participants