Skip to content

fix: preserve original exception context in retry decorator#64

Open
mayank-dev-15 wants to merge 1 commit into
bnusunny:developfrom
mayank-dev-15:fix/retry-preserve-exception-context
Open

fix: preserve original exception context in retry decorator#64
mayank-dev-15 wants to merge 1 commit into
bnusunny:developfrom
mayank-dev-15:fix/retry-preserve-exception-context

Conversation

@mayank-dev-15

Copy link
Copy Markdown

Fixes #29 - The retry decorator was swallowing the original exception when all retries were exhausted. The raised exception had no __cause__, making it impossible to diagnose the root cause.

Changes:

  • Store the last caught exception in the retry loop
  • Use raise ... from last_exception to preserve the exception chain
  • Root cause is now visible in tracebacks

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.

1 participant