-
Notifications
You must be signed in to change notification settings - Fork 415
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(django-upgrade): upgrade django major version #4136
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎ 3 Skipped Deployments
|
Uffizzi Preview |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #4136 +/- ##
==========================================
+ Coverage 96.92% 96.95% +0.02%
==========================================
Files 1178 1152 -26
Lines 39623 39650 +27
==========================================
+ Hits 38405 38442 +37
+ Misses 1218 1208 -10 ☔ View full report in Codecov by Sentry. |
@gagantrivedi just a heads up that I've updated the title of this PR to mark it as breaking |
caffa2b
to
56b5148
Compare
|
|
|
|
|
update pyproject.toml bump pytest-django update test remove default_app_config bump pytest-xdist rbac test fixes remove default_app_config cover fixes
4fedc0a
to
0f1d539
Compare
): | ||
# Given | ||
if ( | ||
settings.IS_RBAC_INSTALLED and not is_admin_master_api_key_client |
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.
This feels slightly odd to me:
- I'd rather not have to use another parametrized argument for the boolean if we can avoid it (although I have looked into it myself and can't see any obvious options).
- If we do need to use the extra argument, why not invert it and use
is_admin_client
rather thanis_admin_master_api_key_client
?
Either way, it'd be good to add a comment as to why we expect the extra query in this scenario.
if settings.IS_RBAC_INSTALLED: # pragma: no cover | ||
num_queries += 1 |
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.
I guess what Gagan is trying to achieve here is a generic solution that works for both (one which includes all the private packages) and one which doesn't.
I guess with @khvn26 's approach, we could add a pytest.mark.skip
perhaps?
ff6f162
to
ecc95d1
Compare
758fc94
to
4a3e2ce
Compare
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.
Looks good to me, but keen to get @khvn26 's thoughts on the solution to the main discussion thread.
Thanks for submitting a PR! Please check the boxes below:
pre-commit
to check lintingdocs/
if required so people know about the feature!Changes
BREAKING CHANGE: Upgrade django major version
How did you test this code?
Updates tests