Skip to content

🎨 Palette: Style top-level unhandled errors#67

Merged
ffalcinelli merged 3 commits into
mainfrom
palette/ux-error-styling-6871824705403774767
Jul 11, 2026
Merged

🎨 Palette: Style top-level unhandled errors#67
ffalcinelli merged 3 commits into
mainfrom
palette/ux-error-styling-6871824705403774767

Conversation

@ffalcinelli

Copy link
Copy Markdown
Owner

💡 What: Styled the generic eprintln! prefix for top-level unhandled errors with "error:".red().bold(). Also added an about text for the CLI in --help.
🎯 Why: Top-level errors printed to stderr were generic strings that blended in with normal text output. Formatting them clearly as errors makes it much easier for a developer to spot what went wrong (e.g. Path not found: non_existent_dir). Added help text to improve discoverability.
📸 Before/After:
Before:

Error: Failed to run pinner

Caused by:
    Path not found: non_existent_dir

After:

error: Failed to run pinner

Caused by:
    Path not found: non_existent_dir

(With "error:" rendered in bold red)

Ergonomics: Immediate visual feedback on failure states via standard Unix color outputs on stderr, enhancing scannability.


PR created automatically by Jules for task 6871824705403774767 started by @ffalcinelli

Use the `colored` crate to apply red bold styling to the "error:" prefix
when printing top-level errors in `main.rs`, improving error scannability.

Co-authored-by: ffalcinelli <1167082+ffalcinelli@users.noreply.github.com>
@google-labs-jules

Copy link
Copy Markdown
Contributor

👋 Jules, reporting for duty! I'm here to lend a hand with this pull request.

When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down.

I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job!

For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with @jules. You can find this option in the Pull Request section of your global Jules UI settings. You can always switch back!

New to Jules? Learn more at jules.google/docs.


For security, I will only act on instructions from the user who triggered this task.

@codecov-commenter

codecov-commenter commented Jul 11, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 0% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 87.11%. Comparing base (b8a7e01) to head (d04d00f).

Files with missing lines Patch % Lines
src/main.rs 0.00% 1 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main      #67   +/-   ##
=======================================
  Coverage   87.11%   87.11%           
=======================================
  Files          28       28           
  Lines        2568     2568           
=======================================
  Hits         2237     2237           
  Misses        331      331           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

google-labs-jules Bot and others added 2 commits July 11, 2026 05:56
Adds `test_cli_unhandled_error_styling` to verify that unhandled errors
routed to `stderr` correctly contain the "error:" prefix and the
original error context.

Co-authored-by: ffalcinelli <1167082+ffalcinelli@users.noreply.github.com>
Fixed a formatting violation in tests/cli.rs caught by `cargo fmt`.

Co-authored-by: ffalcinelli <1167082+ffalcinelli@users.noreply.github.com>
@ffalcinelli ffalcinelli merged commit ed6815a into main Jul 11, 2026
4 checks passed
@ffalcinelli ffalcinelli deleted the palette/ux-error-styling-6871824705403774767 branch July 11, 2026 08:39
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.

2 participants