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

Allow into argument of reraise to be callable #100

Merged
merged 1 commit into from
May 8, 2021
Merged

Allow into argument of reraise to be callable #100

merged 1 commit into from
May 8, 2021

Conversation

duijf
Copy link
Contributor

@duijf duijf commented May 7, 2021

This PR tweaks reraise() to also accept any callable as a second argument. This allows users to transform any exceptions before they are re-raised without introducing helper functions or another try ... except block.

funcy/flow.py Outdated Show resolved Hide resolved
@Suor Suor merged commit cc49a44 into Suor:master May 8, 2021
@Suor
Copy link
Owner

Suor commented May 8, 2021

Thanks, merged.

@duijf duijf deleted the reraise-lambda-into branch May 10, 2021 07:41
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.

2 participants