Live-check: add min-advice-level option to control advice verbosity#923
Live-check: add min-advice-level option to control advice verbosity#923lmolkova wants to merge 2 commits intoopen-telemetry:mainfrom
Conversation
There was a problem hiding this comment.
Pull Request Overview
This PR adds a new command-line option --min-advice-level to the live-check functionality to control the verbosity of advice output by filtering based on advice level severity.
- Adds
--min-advice-levelCLI argument with default value "information" - Threads advice level filtering through the entire live check execution chain
- Implements filtering logic in
LiveCheckResultto exclude advice below the minimum level
Reviewed Changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| src/registry/live_check.rs | Adds CLI argument and passes it to live check execution |
| crates/weaver_live_check/src/lib.rs | Updates trait signatures and implements filtering logic |
| crates/weaver_live_check/src/sample_*.rs | Updates all sample types to accept and pass through advice level parameter |
| crates/weaver_live_check/src/live_checker.rs | Updates test calls with new parameter signature |
| crates/weaver_checker/src/violation.rs | Adds string conversion implementation for AdviceLevel |
| crates/weaver_live_check/README.md | Documents the new feature with usage examples |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #923 +/- ##
=====================================
Coverage 77.9% 78.0%
=====================================
Files 76 76
Lines 5972 6012 +40
=====================================
+ Hits 4657 4690 +33
- Misses 1315 1322 +7 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
|
||
| #### Customize advise level | ||
|
|
||
| By default, live-check shows `information`, `improvement` and `violation` advices. You can provide `--min-advice-level` argument to only show advices of this and higher levels. |
There was a problem hiding this comment.
| By default, live-check shows `information`, `improvement` and `violation` advices. You can provide `--min-advice-level` argument to only show advices of this and higher levels. | |
| By default, live-check shows `information`, `improvement` and `violation` advice. You can provide `--min-advice-level` argument to only show advices of this and higher levels. |
|
Discussed at the weaver call, the conclusion: The full report contains a lot of details which are useful too. We could print this summary at the bottom of ansi report and have the section in the json report. We could also print it to stderr if I'll close this PR and will open another one with that proposal. |
No description provided.