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

Make PyErr: Send + Sync #1067

Merged
merged 1 commit into from Aug 2, 2020
Merged

Make PyErr: Send + Sync #1067

merged 1 commit into from Aug 2, 2020

Conversation

davidhewitt
Copy link
Member

Changes PyErr to implement Send + Sync. This allows easier integration with libraries such as anyhow, which often require Send + Sync errors.

While technically breaking, I think it is unlikely to cause much frustration, because most types convertible to Python are Send + Sync already since we added the #[pyclass] requirements.

Also, PyErr::from_value can be used where the new bounds are restrictive.

@davidhewitt
Copy link
Member Author

@kngwyu unless you have any objections, I plan to merge this later today

Copy link
Member

@kngwyu kngwyu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks!

@kngwyu
Copy link
Member

kngwyu commented Aug 2, 2020

Sorry I overlooked this PR, thanks!

@kngwyu kngwyu merged commit aaeb5ea into PyO3:master Aug 2, 2020
@davidhewitt davidhewitt deleted the pyerr-send branch August 10, 2021 07:19
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.

None yet

2 participants