-
Notifications
You must be signed in to change notification settings - Fork 28
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
Remove migrations
migrated to shared
#1090
Conversation
All the migrations which have been migrated to `shared` and are being referenced via `MIGRATION_MODULES` can be removed from `api`, as that code is never being imported from here.
Codecov ReportAll modified and coverable lines are covered by tests ✅ ✅ All tests successful. No failed tests found. 📢 Thoughts on this report? Let us know! |
✅ All tests successful. No failed tests were found. 📣 Thoughts on this report? Let Codecov know! | Powered by Codecov |
Codecov ReportAll modified and coverable lines are covered by tests ✅
✅ All tests successful. No failed tests found. Additional details and impacted files@@ Coverage Diff @@
## main #1090 +/- ##
==========================================
+ Coverage 96.02% 96.12% +0.10%
==========================================
Files 831 829 -2
Lines 19563 19540 -23
==========================================
- Hits 18785 18783 -2
+ Misses 778 757 -21
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Godsend 😂 I had made a comment in another ticket to see if you could do this - thank you.
Left another comment as well but approved. Reemphasizing to manually test this in some capacity to ensure nothing breaks since it's a lot of files moved
@@ -1,2 +1 @@ | |||
from shared.django_apps.codecov_auth.models import * | |||
from shared.django_apps.codecov_auth.models import _generate_key # noqa: F401 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this safe to remove? I forget specifically why this was here in the first place, maybe for some migrations?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
searching for this across the code did not yield any results, so 🤷🏻♂️
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Did a quick search and found it here
models.TextField(default=core.models._gen_image_token, null=True), |
So I think by completely removing that migration from API and putting it into Shared we should be able to delete it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Indeed, the migration as it exists in shared already has copied this code:
https://github.com/codecov/shared/blob/95c63cd9647a825355db6b75c370ccc32d0b1704/shared/django_apps/core/migrations/0001_initial.py#L13
All the migrations which have been migrated to
shared
and are being referenced viaMIGRATION_MODULES
can be removed fromapi
, as that code is never being imported from here.