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

Python 3.12 & Django 4.2 upgrade #97

Merged
merged 14 commits into from
Jun 7, 2024
Merged

Conversation

SunnyR
Copy link
Member

@SunnyR SunnyR commented Jun 6, 2024

This merge request aims to update the Python package to ensure seamless compatibility with Django 4.2 and Python 3.12. The following modifications have been implemented:

Django 4.2 Compatibility Updates:

  • Updated references for ugettext_lazy to gettext_lazy.
  • Upgraded package dependencies to versions compatible with Django 4.2.
  • Reviewed and adjusted any deprecated Django features, replacing them with their updated counterparts.
  • Ensured that existing functionality aligns with the latest Django ORM methods and query syntax.

Python 3.12 Compatibility Updates:

  • Analyzed codebase for any potential issues related to Python 3.12.
  • Updated syntax and libraries to ensure compatibility with Python 3.12 features and standards.
  • Performed necessary adjustments to resolve any warnings or deprecation issues raised by Python 3.12.

Ref: https://sdelements.atlassian.net/browse/DEVOP-6777

@SunnyR SunnyR self-assigned this Jun 6, 2024
@SunnyR SunnyR requested review from RouganStriker and Gee19 June 6, 2024 02:48
@Gee19
Copy link
Member

Gee19 commented Jun 6, 2024

Left a few comments but all minor stuff, +1

security/middleware.py Outdated Show resolved Hide resolved
tests/settings.py Show resolved Hide resolved
tox.ini Show resolved Hide resolved
security/middleware.py Show resolved Hide resolved
Copy link
Member

@RouganStriker RouganStriker left a comment

Choose a reason for hiding this comment

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

If we do drop the deprecated middlewares, we will actually need to reach out to the content team to update some things - turns out we have been advertising the django-security package in our how-tos - they should be updated to reference the Django built-in security middlewares now: I690

README.md Outdated Show resolved Hide resolved
pyproject.toml Outdated Show resolved Hide resolved
security/auth_throttling/__init__.py Show resolved Hide resolved
security/south_migrations/0001_initial.py Outdated Show resolved Hide resolved
security/middleware.py Outdated Show resolved Hide resolved
security/middleware.py Outdated Show resolved Hide resolved
security/middleware.py Show resolved Hide resolved
security/middleware.py Outdated Show resolved Hide resolved
security/middleware.py Outdated Show resolved Hide resolved
@SunnyR SunnyR merged commit 6162b6e into master Jun 7, 2024
1 check passed
@SunnyR SunnyR deleted the feature/devop-6777/python-upgrade branch June 7, 2024 22:05
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