Skip to content

Conversation

@G-Rath
Copy link
Collaborator

@G-Rath G-Rath commented Oct 30, 2025

Note I've purposely not used a new error code for now because I can't imagine a use-case for wanting to identify this particular situation in a scripting context, which is where exit code values are relevant (we can always use a more specific code later if a use case is presented)

Resolves #2303

@G-Rath G-Rath requested review from another-rex and cuixq October 30, 2025 01:30
@codecov-commenter
Copy link

codecov-commenter commented Oct 30, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 67.98%. Comparing base (51834cb) to head (c7ce7b3).

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2309      +/-   ##
==========================================
+ Coverage   67.95%   67.98%   +0.03%     
==========================================
  Files         172      172              
  Lines       12821    12834      +13     
==========================================
+ Hits         8712     8725      +13     
- Misses       3437     3438       +1     
+ Partials      672      671       -1     

☔ View full report in Codecov by Sentry.
📢 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.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@another-rex
Copy link
Collaborator

The scripting case I'm thinking of is less identifying this specifically, but differentiating argument errors vs some catch all transient errors that might occur. Right now any error that we don't specifically account for is 127.

@G-Rath
Copy link
Collaborator Author

G-Rath commented Oct 30, 2025

But that's still a scripting context right, in which case I don't see this as being a failure that is really actionable by the user?

@another-rex
Copy link
Collaborator

I think the difference is if it's something caused by a network error, it'll go away by itself hopefully, so you don't need to do anything about it. But with invalid args you have to do something.

Hmm I probably have to think through this a bit more, let's merge this as is for now.

@another-rex another-rex merged commit 8667441 into google:main Oct 31, 2025
16 checks passed
@another-rex another-rex deleted the help-exit-code branch October 31, 2025 05:00
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.

pre-commit hook performs should performs a scan by default

3 participants