Rethrow Panic from runners and narrow gen() result semantics#31
Conversation
This stack of pull requests is managed by Graphite. Learn more about stacking. |
|
Warning Rate limit exceeded
⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (11)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
@codex review |
|
✅ Actions performedReview triggered.
|
|
Codex Review: Didn't find any major issues. More of your lovely PRs please. ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
If Codex has suggestions, it will comment; otherwise it will react with 👍. Codex can also answer questions or update the PR. Try commenting "@codex address that feedback". |
56c3a30 to
28f232d
Compare
392c4f0 to
29c0fcf
Compare
28f232d to
6c0cfde
Compare
29c0fcf to
37ef0c3
Compare
37ef0c3 to
c8ca403
Compare
Merge activity
|

This pull request implements critical correctness fixes for error handling and panic semantics across the hardtry library.
Key Changes:
run()andrunSync()now rethrow user-thrownPanicinstances instead of wrapping them, ensuring panic semantics remain consistent and preventing retry attempts on control errorsControlErrorbase class forCancellationErrorandTimeoutError, replacing thecheckIsControlError()utility function with directinstanceofchecksgen()now throws unexpected failures unchanged while keepingGenResultnarrow to only include explicit yielded/returned error values, avoiding the need to widen the public type withUnhandledExceptionrun()andrunSync()never returnPanicas a result valueTest Coverage:
Panicrethrow behavior in both sync and async execution pathsPanicinstancesThis maintains backward compatibility for normal error handling while fixing edge cases where control errors were incorrectly wrapped or returned as values.