Skip to content

fix(build): forward verbosity to build backends - #6806

Open
Jamison929611 wants to merge 3 commits into
prefix-dev:mainfrom
Jamison929611:fix/build-backend-verbosity
Open

fix(build): forward verbosity to build backends#6806
Jamison929611 wants to merge 3 commits into
prefix-dev:mainfrom
Jamison929611:fix/build-backend-verbosity

Conversation

@Jamison929611

Copy link
Copy Markdown

Description

Forward Pixi's effective CLI verbosity to JSON-RPC build backend processes without relying on process-global mutable state. Each command dispatcher snapshots immutable verbosity configuration, and both system and isolated tools receive matching backend flags. Existing public setup/command entry points keep their default behavior.

Also stop forcing uv's nested pip install invocation to -vv by default. The Python backend now derives uv verbosity from its backend logging level while preserving pip's existing -vv behavior.

Fixes #6099

How Has This Been Tested?

  • cargo test --locked --offline -p pixi_build_frontend -p pixi-build-python
    • pixi_build_frontend: 7 passed; doc tests passed
    • pixi-build-python: 96 passed; 1 ignored
  • cargo test --locked --offline -p pixi_command_dispatcher
    • 100 unit tests passed
    • 37 integration tests passed; 2 ignored
    • doc tests passed (2 ignored)
  • cargo check --locked --offline -p pixi_cli
  • cargo clippy --locked --offline -p pixi_build_frontend -p pixi-build-python -p pixi_command_dispatcher -p pixi_cli --all-targets -- -D warnings
  • cargo fmt --all -- --check
  • git diff --check

AI Disclosure

  • This PR contains AI-generated content.
    • I have tested any AI-generated content in my PR.
    • I take responsibility for any AI-generated content in my PR.

Tools: Codex

Prompt: Diagnose and fix #6099 using TDD; propagate Pixi CLI verbosity to build backends without global mutable state, preserve public APIs and pip behavior, add end-to-end regression coverage, and run the relevant Rust checks.

Checklist:

  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have added sufficient tests to cover my changes.

@Jamison929611

Jamison929611 commented Aug 12, 2026

Copy link
Copy Markdown
Author

Update: the branch was rebased onto current main, and the fresh CI run is green, including cargo test | windows x64.

This is ready for review whenever someone has bandwidth.

@Jamison929611
Jamison929611 force-pushed the fix/build-backend-verbosity branch from 84672d5 to 3c3655d Compare August 13, 2026 00:15
@Jamison929611

Copy link
Copy Markdown
Author

Hi maintainers, this PR has been rebased and all checks are passing. It has been ready for review for a little over a week. When someone has bandwidth, could you please take a look? I'm happy to address any feedback. Thanks!

} else {
0
}
}

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

please can we make this generic over the installer? I think it can just be called verbosity and passed to pip the same as uv.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

Updated in 08cd4e3: the build script context now uses generic verbosity, and both uv and pip receive the same derived -v/-vv flags. Added pip coverage for default/debug/trace behavior.

Comment on lines +8 to +14
{%- if installer == "uv" and uv_verbosity == 1 -%}
{% set OPTIONS = ["-v"] + OPTIONS -%}
{%- elif installer == "uv" and uv_verbosity >= 2 -%}
{% set OPTIONS = ["-vv"] + OPTIONS -%}
{%- elif installer == "pip" -%}
{% set OPTIONS = ["-vv"] + OPTIONS -%}
{%- endif -%}

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

see other comment on having this be the same for all installers

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

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

Handled in 08cd4e3 with the generic installer verbosity change.

@Jamison929611
Jamison929611 force-pushed the fix/build-backend-verbosity branch from 3c3655d to 08cd4e3 Compare August 24, 2026 01:51
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.

bug(pixi-build): debug and trace logs printed on install

2 participants