Commit e0b1619
fix: address StopWithRetry false negative issue
Address code review feedback from @perdasilva: the "final attempt" after
timeout creates a confusing false negative. If the final attempt succeeds
after we've logged "timeout reached", we return success despite logging
a timeout message.
Changes:
- Remove final attempt after timeout
- Return error immediately when timeout is reached
- Clearer error message with timeout duration
- Prevents false negatives where timeout is logged but success is returned
This makes the function behavior match its log messages - if we say we
timed out, we actually return an error.
Assisted-by: Cursor/Claude
Co-authored-by: Cursor <cursoragent@cursor.com>1 parent 3b46724 commit e0b1619
2 files changed
Lines changed: 5 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
40 | 40 | | |
41 | 41 | | |
42 | 42 | | |
43 | | - | |
| 43 | + | |
44 | 44 | | |
45 | 45 | | |
46 | 46 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
61 | 61 | | |
62 | 62 | | |
63 | 63 | | |
64 | | - | |
65 | 64 | | |
66 | 65 | | |
67 | 66 | | |
68 | 67 | | |
69 | | - | |
70 | 68 | | |
71 | 69 | | |
72 | 70 | | |
73 | 71 | | |
74 | | - | |
75 | | - | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
76 | 75 | | |
77 | | - | |
| 76 | + | |
78 | 77 | | |
0 commit comments