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

[Django 4.2]: Django 4.2 Upgrade #2196

Merged
merged 1 commit into from
Oct 6, 2023
Merged

[Django 4.2]: Django 4.2 Upgrade #2196

merged 1 commit into from
Oct 6, 2023

Conversation

irtazaakram
Copy link
Member

@irtazaakram irtazaakram commented Sep 20, 2023

Upgrading to django42 and dropped django32 support.

@@ -226,6 +226,9 @@
TIME_ZONE = "UTC"
TIME_ZONE_CLASS = timezone.utc

# https://docs.djangoproject.com/en/4.2/releases/4.0/#zoneinfo-default-timezone-implementation
USE_DEPRECATED_PYTZ = True
Copy link
Contributor

Choose a reason for hiding this comment

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

Django switched from the pytz third-party python package to the Python native package zoneinfo in Django 4.0. In release notes, they have mentioned that both are not equivalent so one might need some manual work for this migration. So Django provided this USE_DEPRECATED_PYTZ setting, so we can decouple this migration from the Django upgrade.

More info: https://docs.djangoproject.com/en/4.2/releases/4.0/#zoneinfo-default-timezone-implementation

@@ -234,8 +237,6 @@

LOCALE_PATHS = (root("conf", "locale"),)

DEFAULT_HASHING_ALGORITHM = "sha1"
Copy link
Contributor

@awais786 awais786 Sep 25, 2023

Choose a reason for hiding this comment

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

Django4.2 has dropped sha1 support. For details https://github.com/orgs/edx/projects/12/views/8?pane=issue&itemId=39005351

Its side effect it might logout the users from credentials.

@UsamaSadiq UsamaSadiq marked this pull request as ready for review September 25, 2023 14:16
@awais786 awais786 closed this Sep 26, 2023
@awais786 awais786 reopened this Sep 26, 2023
@irtazaakram irtazaakram force-pushed the django42 branch 2 times, most recently from 8d9ebd1 to ab5149a Compare October 3, 2023 06:40
@awais786
Copy link
Contributor

awais786 commented Oct 5, 2023

#2221 We are blocked due to translations check but this Temp PR is green using the fix hash. Hopefully we will get new version so i will update that in this PR.

# via
# -r requirements/base.txt
# python3-openid
# social-auth-core
didkit==0.3.2
# via -r requirements/base.txt
django==3.2.21
django==4.2.6
Copy link
Contributor

Choose a reason for hiding this comment

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

Upgrading to 4.2.6

@jsnwesson jsnwesson merged commit 75cf063 into master Oct 6, 2023
8 checks passed
@jsnwesson jsnwesson deleted the django42 branch October 6, 2023 15:12
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.

Django 4.2 Upgrade
3 participants