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

Stable migrations #95

Merged
merged 2 commits into from
May 30, 2023
Merged

Conversation

PetrDlouhy
Copy link
Collaborator

No description provided.

@PetrDlouhy PetrDlouhy marked this pull request as ready for review May 29, 2023 16:10
@PetrDlouhy
Copy link
Collaborator Author

@nitsujri @Joshun When I am testing the new code I am often struggling with the migrations changing all the time.
I have tried to mitigate that with this PR. Part of it is taken from #90.

I will have to fix the tests in Django 3.2.

Can you please, can you check if this is correct?

@codecov-commenter
Copy link

codecov-commenter commented May 29, 2023

Codecov Report

Patch coverage: 100.00% and project coverage change: +0.02 🎉

Comparison is base (7f83ecf) 92.90% compared to head (352c683) 92.92%.

❗ Your organization is not using the GitHub App Integration. As a result you may experience degraded service beginning May 15th. Please install the Github App Integration for your organization. Read more.

Additional details and impacted files
@@            Coverage Diff             @@
##           master      #95      +/-   ##
==========================================
+ Coverage   92.90%   92.92%   +0.02%     
==========================================
  Files          59       59              
  Lines        3734     3747      +13     
  Branches      233      236       +3     
==========================================
+ Hits         3469     3482      +13     
  Misses        223      223              
  Partials       42       42              
Impacted Files Coverage Δ
hordak/defaults.py 100.00% <100.00%> (ø)
hordak/models/core.py 98.23% <100.00%> (+0.01%) ⬆️
hordak/tests/models/test_core.py 100.00% <100.00%> (ø)

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@PetrDlouhy
Copy link
Collaborator Author

Looks good to me! I tested the migration locally works just fine.

Yeah that's weird that 3.2 thinks there is a missing migration where the other versions don't?

(answering here on official PR, the PetrDlouhy#1 was my testing PR)

The Django 3.2 was creating new migrations when get_internal_currency was a function. When I changed it to:

get_internal_currency = defaults.INTERNAL_CURRENCY

everything works for all versions.

@PetrDlouhy PetrDlouhy merged commit f239d02 into adamcharnock:master May 30, 2023
This pull request was closed.
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