Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a global verbose option #2080

Merged
merged 1 commit into from
May 23, 2024
Merged

Add a global verbose option #2080

merged 1 commit into from
May 23, 2024

Conversation

konstin
Copy link
Member

@konstin konstin commented May 9, 2024

Debugging #2079 i realized that we currently require RUST_LOG for users to debug issues like missing inclusions. I added a global counting -v flag to allow users to get more verbose logging from maturin to help them diagnose their problems.

We currently use -v to configure cargo verbosity level. For simplicity, it now configures both at the same time. Fine-grained control is still possible by setting RUST_LOG.

The levels:

  • Default: Show build information and cargo build output.
  • -v: Use cargo build -v.
  • -vv: Show debug logging and use cargo build -vv.
  • -vvv: Show trace logging.

This can be extended to support a quiet option.

@konstin konstin added the enhancement New feature or request label May 9, 2024
Copy link

netlify bot commented May 9, 2024

Deploy Preview for maturin-guide ready!

Name Link
🔨 Latest commit c5533e9
🔍 Latest deploy log https://app.netlify.com/sites/maturin-guide/deploys/663d39cb04333b000867673c
😎 Deploy Preview https://deploy-preview-2080--maturin-guide.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@@ -94,6 +94,7 @@ pub struct CargoOptions {
pub ignore_rust_version: bool,

/// Use verbose output (-vv very verbose/build.rs output)
// Note that this duplicates the global option, but clap seems to be fine with that.
Copy link
Member Author

Choose a reason for hiding this comment

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

This feels wrong but unfortunately i don't understand the cargo argument handling enough to solve this properly

Copy link

netlify bot commented May 9, 2024

Deploy Preview for maturin-guide ready!

Name Link
🔨 Latest commit 202636d
🔍 Latest deploy log https://app.netlify.com/sites/maturin-guide/deploys/664ca64a74236000089da955
😎 Deploy Preview https://deploy-preview-2080--maturin-guide.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@konstin konstin force-pushed the konsti/global-verbose-option branch 2 times, most recently from 9c0a1c6 to dced2b8 Compare May 9, 2024 21:06
@messense messense force-pushed the konsti/global-verbose-option branch from dced2b8 to 10ad37b Compare May 21, 2024 11:59
Debugging #2079 i realized that we currently require `RUST_LOG=debug` for users to debug issues like missing inclusions. I added a global counting `-v` flag.

We currently use `-v` to configure cargo verbosity level. For simplicity, it now configures both at the same time. Fine-grained control is still possible by setting `RUST_LOG`.

The levels:
* Default: Show build information and `cargo build` output.
* `-v`: Use `cargo build -v`.
* `-vv`: Show debug logging and use `cargo build -vv`.
* `-vvv`: Show trace logging.

This can be extended to support a quiet option.
@messense messense force-pushed the konsti/global-verbose-option branch from 10ad37b to 202636d Compare May 21, 2024 13:48
@messense messense added this pull request to the merge queue May 22, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks May 22, 2024
@messense messense added this pull request to the merge queue May 22, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks May 22, 2024
@konstin konstin added this pull request to the merge queue May 22, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks May 22, 2024
@messense messense merged commit f485ee4 into main May 23, 2024
28 checks passed
@messense messense deleted the konsti/global-verbose-option branch May 23, 2024 01:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants