Skip to content
This repository has been archived by the owner on Sep 3, 2024. It is now read-only.

Upgrade/django 3.2 #12

Merged
merged 3 commits into from
Sep 9, 2021
Merged

Upgrade/django 3.2 #12

merged 3 commits into from
Sep 9, 2021

Conversation

VirginiaDooley
Copy link
Contributor

This work upgrades dc_signup_form to Django 3.2 and addresses deprecation warnings.

@VirginiaDooley VirginiaDooley changed the title Upgrade/django 3.0 Upgrade/django 3.2 Sep 7, 2021
setup.py Outdated
@@ -14,7 +14,7 @@
url='https://github.com/DemocracyClub/dc_signup_form',
install_requires=[
'requests',
'Django >=1.10,<2.3',
'Django==3.2.0',
Copy link
Member

Choose a reason for hiding this comment

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

This change means that it will only work with Django 3.2.0. We want a range here, starting at the lowest Django version we support (the first version to introduce re_path I expect?), and ending at <3.3 — if we use less than 3.3 then we get all minor version bumps after 3.2.0 and before 3.3.0.

You should also look at the CI matrix and add/remove the versions we want to support there.

Copy link
Member

Choose a reason for hiding this comment

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

Looks like Django 2.0 was the first to add re_path: https://docs.djangoproject.com/en/2.0/ref/urls/

.travis.yml Outdated
Comment on lines 10 to 11
- DJANGO_VERSION='>=1.10,<1.11' POSTGRES_VERSION=9.5
- DJANGO_VERSION='>=1.11,<1.12' POSTGRES_VERSION=9.5

Choose a reason for hiding this comment

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

Think these two should be deleted now - as we won't be supporting below Django 2.0

@VirginiaDooley VirginiaDooley force-pushed the upgrade/django-3.0 branch 2 times, most recently from 88ae068 to 2e82159 Compare September 9, 2021 14:07
.travis.yml Outdated
- DJANGO_VERSION='>=1.10,<1.11' POSTGRES_VERSION=10
- DJANGO_VERSION='>=1.11,<1.12' POSTGRES_VERSION=10
- DJANGO_VERSION='>=2.2,<2.3' POSTGRES_VERSION=10
- DJANGO_VERSION='>=2.0,<3.3' POSTGRES_VERSION=10
Copy link
Member

@symroe symroe Sep 9, 2021

Choose a reason for hiding this comment

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

I think we need at least one more line here. We have installs of Django 2.2 and (now) 3.2, so we should test them at least. It's also a good idea to test the next version of Django to see if one exists — that way we can catch errors in future versions early. So, we can have:

DJANGO_VERSION='>=2.2,<2.3' POSTGRES_VERSION=10
DJANGO_VERSION='>=3.2,<3.3' POSTGRES_VERSION=10
DJANGO_VERSION='>3.2' POSTGRES_VERSION=10

That gives us:

  1. 2.2.X
  2. 3.2.X
  3. >3.2 (Django 4, but that's not out until December this year)

@VirginiaDooley VirginiaDooley merged commit 716ad7b into master Sep 9, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants