Skip to content

Commit 9ff5277

Browse files
authored
chores(deps): update to Django 5, where supported by Python (GoogleCloudPlatform#10998)
* cleanup: change all django doc links to 'stable' * fix: Update Django dependencies to match major Python version support * chores(deps): update dependency psycopg2-binary to v2.9.9 * revert: appengine/standard_python3/bundled-services (flakytest)
1 parent 471f681 commit 9ff5277

File tree

30 files changed

+74
-61
lines changed

30 files changed

+74
-61
lines changed

appengine/flexible/django_cloudsql/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77

88
This repository is an example of how to run a [Django](https://www.djangoproject.com/)
99
app on Google App Engine Flexible Environment. It uses the
10-
[Writing your first Django app](https://docs.djangoproject.com/en/3.2/intro/tutorial01/) as the
10+
[Writing your first Django app](https://docs.djangoproject.com/en/stable/intro/tutorial01/) as the
1111
example app to deploy.
1212

1313

appengine/flexible/django_cloudsql/mysite/settings.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@
150150
]
151151

152152
# Internationalization
153-
# https://docs.djangoproject.com/en/3.2/topics/i18n/
153+
# https://docs.djangoproject.com/en/stable/topics/i18n/
154154

155155
LANGUAGE_CODE = "en-us"
156156

@@ -175,6 +175,6 @@
175175
# [END staticurl]
176176

177177
# Default primary key field type
178-
# https://docs.djangoproject.com/en/3.2/ref/settings/#default-auto-field
178+
# https://docs.djangoproject.com/en/stable/ref/settings/#default-auto-field
179179

180180
DEFAULT_AUTO_FIELD = "django.db.models.BigAutoField"
Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
1-
Django==4.2.7
1+
Django==5.0; python_version >= "3.10"
2+
Django==4.2.8; python_version < "3.10"
23
gunicorn==20.1.0
3-
psycopg2-binary==2.9.6
4+
psycopg2-binary==2.9.9
45
django-environ==0.10.0
56
google-cloud-secret-manager==2.16.1
67
django-storages[google]==1.13.2

appengine/flexible/hello_world_django/project_name/settings.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,10 @@
1818
Generated by 'django-admin startproject' using Django 1.8.4.
1919
2020
For more information on this file, see
21-
https://docs.djangoproject.com/en/1.8/topics/settings/
21+
https://docs.djangoproject.com/en/stable/topics/settings/
2222
2323
For the full list of settings and their values, see
24-
https://docs.djangoproject.com/en/1.8/ref/settings/
24+
https://docs.djangoproject.com/en/stable/ref/settings/
2525
"""
2626

2727
# Build paths inside the project like this: os.path.join(BASE_DIR, ...)
@@ -31,7 +31,7 @@
3131

3232

3333
# Quick-start development settings - unsuitable for production
34-
# See https://docs.djangoproject.com/en/1.8/howto/deployment/checklist/
34+
# See https://docs.djangoproject.com/en/stable/howto/deployment/checklist/
3535

3636
# SECURITY WARNING: keep the secret key used in production secret!
3737
SECRET_KEY = "qgw!j*bpxo7g&o1ux-(2ph818ojfj(3c#-#*_8r^8&hq5jg$3@"
@@ -86,7 +86,7 @@
8686

8787

8888
# Database
89-
# https://docs.djangoproject.com/en/1.8/ref/settings/#databases
89+
# https://docs.djangoproject.com/en/stable/ref/settings/#databases
9090

9191
DATABASES = {
9292
"default": {
@@ -97,7 +97,7 @@
9797

9898

9999
# Internationalization
100-
# https://docs.djangoproject.com/en/1.8/topics/i18n/
100+
# https://docs.djangoproject.com/en/stable/topics/i18n/
101101

102102
LANGUAGE_CODE = "en-us"
103103

@@ -111,6 +111,6 @@
111111

112112

113113
# Static files (CSS, JavaScript, Images)
114-
# https://docs.djangoproject.com/en/1.8/howto/static-files/
114+
# https://docs.djangoproject.com/en/stable/howto/static-files/
115115

116116
STATIC_URL = "/static/"

appengine/flexible/hello_world_django/project_name/urls.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
"""project_name URL Configuration
1616
1717
The `urlpatterns` list routes URLs to views. For more information please see:
18-
https://docs.djangoproject.com/en/1.8/topics/http/urls/
18+
https://docs.djangoproject.com/en/stable/topics/http/urls/
1919
Examples:
2020
Function views
2121
1. Add an import: from my_app import views

appengine/flexible/hello_world_django/project_name/wsgi.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818
It exposes the WSGI callable as a module-level variable named ``application``.
1919
2020
For more information on this file, see
21-
https://docs.djangoproject.com/en/1.8/howto/deployment/wsgi/
21+
https://docs.djangoproject.com/en/stable/howto/deployment/wsgi/
2222
"""
2323

2424
import os
Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,4 @@
1-
Django==4.2.7
1+
Django==5.0; python_version >= "3.10"
2+
Django==4.2.8; python_version >= "3.8" and python_version < "3.10"
3+
Django==3.2.23; python_version < "3.8"
24
gunicorn==20.1.0

appengine/flexible_python37_and_earlier/django_cloudsql/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77

88
This repository is an example of how to run a [Django](https://www.djangoproject.com/)
99
app on Google App Engine Flexible Environment. It uses the
10-
[Writing your first Django app](https://docs.djangoproject.com/en/3.2/intro/tutorial01/) as the
10+
[Writing your first Django app](https://docs.djangoproject.com/en/stable/intro/tutorial01/) as the
1111
example app to deploy.
1212

1313

appengine/flexible_python37_and_earlier/django_cloudsql/mysite/settings.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@
150150
]
151151

152152
# Internationalization
153-
# https://docs.djangoproject.com/en/3.2/topics/i18n/
153+
# https://docs.djangoproject.com/en/stable/topics/i18n/
154154

155155
LANGUAGE_CODE = "en-us"
156156

@@ -175,6 +175,6 @@
175175
# [END staticurl]
176176

177177
# Default primary key field type
178-
# https://docs.djangoproject.com/en/3.2/ref/settings/#default-auto-field
178+
# https://docs.djangoproject.com/en/stable/ref/settings/#default-auto-field
179179

180180
DEFAULT_AUTO_FIELD = "django.db.models.BigAutoField"
Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
1-
Django==4.2.7
1+
Django==5.0; python_version >= "3.10"
2+
Django==4.2.8; python_version >= "3.8" and python_version < "3.10"
3+
Django==3.2.23; python_version < "3.8"
24
gunicorn==20.1.0
3-
psycopg2-binary==2.9.6
5+
psycopg2-binary==2.9.9
46
django-environ==0.10.0
57
google-cloud-secret-manager==2.16.1
68
django-storages[google]==1.13.2

0 commit comments

Comments
 (0)