You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Decide How to Close the int() Crash in the Signal-0 Timeout Check (#1634) #1985
The fix for #1634 (handoff #1983, branch feature/auto-1634, no pull request yet) used its two rounds of local review edits and a third strict review pass still found an introduced defect. Per local-strict-review, editing stopped here. Should the lane apply the fix below and continue to a pull request?
The open finding
_is_timeout_signal_zero in host-setup/agent-safety/claude/gh-write-guard.py calls int() on any all-digit -s value. Python 3.11 and later raise ValueError for a digit string longer than 4300 digits, so a timeout -s <5000 zeros> 900 ... prefix crashes the hook with exit 1, a non-blocking hook error, and the command runs with no check at all, a cross-owner gh api write included. The code before this branch skipped the -s value without converting it, so the crash is new with this change.
Options
Recommended: fix and continue. Strip leading zeros and refuse a digit string longer than an int's range (ten digits) before int(), treating an over-long value as the zero it masks to when it is all zeros and as no signal otherwise, add a self-test case with a digit string over 4300 digits, run one more strict pass, then open the pull request to develop. The parked work keeps everything it has and gains one small change.
Drop the number masking. Read only 0+, EXIT and the SIG forms as signal 0 and never call int(). This removes the crash with less code, and -s 128 or -s 256 go back to being read as a bound, a leak the README would then have to declare.
Answered by the maintainer in an attended session: option 1, fix and continue. Strip leading zeros and refuse a digit string over ten digits before int(), add a self-test row with a digit string over 4300 digits, run one more strict pass, then open the pull request to develop. Work continues under handoff #1983.
Activity
ptr727 commentedon Sep 28, 2026
Answered by the maintainer in an attended session: option 1, fix and continue. Strip leading zeros and refuse a digit string over ten digits before
int(), add a self-test row with a digit string over 4300 digits, run one more strict pass, then open the pull request to develop. Work continues under handoff #1983.