Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Does not retry wrapped PermanentError #140

Open
RoryCrispin opened this issue Mar 19, 2024 · 1 comment
Open

Does not retry wrapped PermanentError #140

RoryCrispin opened this issue Mar 19, 2024 · 1 comment

Comments

@RoryCrispin
Copy link

When the retry Op returns a wrapped PermanentError - the library does not recognise it as a Permanent Error (as the type cast to *PermanentError fails.

This is unexpected in my opinion. It would be more idiomatic to respect the usual Go error wrapping rules and test with errors.Is.
I'll be happy to raise a PR for this change

@cenkalti
Copy link
Owner

Yes. Can you send a PR?

@RoryCrispin RoryCrispin changed the title Do not retry wrapped PermanentError Does not retry wrapped PermanentError Mar 19, 2024
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

No branches or pull requests

2 participants