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

Fix circular import error when Conformity is involved in the import #9

Closed
nickwilliams-eventbrite opened this issue Mar 5, 2020 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@nickwilliams-eventbrite
Copy link
Contributor

When PyMetrics tries to import Django to look for settings, it already has protections against circular imports. However, those projections break down when one of the imports happens in Conformity validation code, which turns the ImportError into a ValidationError.

@nickwilliams-eventbrite nickwilliams-eventbrite added the bug Something isn't working label Mar 5, 2020
nickwilliams-eventbrite added a commit to eventbrite/conformity that referenced this issue Mar 5, 2020
The issue eventbrite/pymetrics#9 is caused by the fact that Conformity wraps `ImportError`s that occur during validation. This tiny tweak makes it possible for PyMetrics to easily detect such errors and include them in its circular-import protection code.
nickwilliams-eventbrite added a commit to eventbrite/conformity that referenced this issue Mar 5, 2020
The issue eventbrite/pymetrics#9 is caused by the fact that Conformity wraps `ImportError`s that occur during validation. This tiny tweak makes it possible for PyMetrics to easily detect such errors and include them in its circular-import protection code.
nickwilliams-eventbrite added a commit to eventbrite/conformity that referenced this issue Mar 5, 2020
The issue eventbrite/pymetrics#9 is caused by the fact that Conformity wraps `ImportError`s that occur during validation. This tiny tweak makes it possible for PyMetrics to easily detect such errors and include them in its circular-import protection code.
nickwilliams-eventbrite added a commit that referenced this issue Mar 6, 2020
[PATCH] Fix #9: Catch circular Django settings import Conformity error
nickwilliams-eventbrite added a commit that referenced this issue Mar 6, 2020
Changelog Details:
- [PATCH] Fix #9: Catch circular Django settings import Conformity error
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant