fix: gitt miner check exits with code 1 when no validators have a valid PAT (#842)#1129
Closed
alpurkan17 wants to merge 1 commit into
Closed
fix: gitt miner check exits with code 1 when no validators have a valid PAT (#842)#1129alpurkan17 wants to merge 1 commit into
alpurkan17 wants to merge 1 commit into
Conversation
Contributor
Author
CLI Screenshot EvidenceBefore → After (exit code fix for gitt miner check)
|
Contributor
Author
CLI Screenshot Evidence (PR #1129)Before → After — gitt miner check exit code fix
Terminal output: Non-output-affecting change — the same table/JSON output is produced regardless of exit code. |
Contributor
Author
CLI Screenshot EvidencePR #1129 — gitt miner check exit code fix Changes:
Live test: |
Collaborator
|
#842 closed — zero valid PATs is the command's output, not a failure exit. Closing. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Summary
Root Cause
check.pyiterates over configured validators and displays PAT status, but exits with code 0 even whenvalid_count == 0(all PATs are invalid). Downstream scripts rely on exit codes to detect failure, so they miss the all-PATs-invalid state.Impact
Automation scripts that call
gitt miner checkdon't detect when all PATs are invalid. Miners remain unaware their setup has no valid tokens.Related Issues
Fixes #842
Test plan
Live verification
gitt miner check --network finney; echo Exit: $?shows 1 when no valid PATsHow to verify
gitt miner check --network finney; echo $?Edge cases considered
Post-merge verification