Skip to content

Fix: Lazy-initialize storage class to prevent unwanted migration generation #113

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

Merged
merged 1 commit into from
Nov 14, 2023

Conversation

samupl
Copy link
Contributor

@samupl samupl commented Oct 13, 2023

Fixes the issue described in #112 - the storage class is now lazily generated by a callable that reads the IMPORT_EXPORT_CELERY_STORAGE setting.

This makes the migrations happy even if you change IMPORT_EXPORT_CELERY_STORAGE after the migrations were applied.

@samupl
Copy link
Contributor Author

samupl commented Oct 13, 2023

@timthelion Could you please review?

Copy link
Contributor

@PetrDlouhy PetrDlouhy left a comment

Choose a reason for hiding this comment

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

I think these changes are pretty straightforward and they should be merged.
I am using this code already.

@PetrDlouhy PetrDlouhy merged commit d8357e7 into auto-mat:master Nov 14, 2023
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.

3 participants