summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZuul <zuul@review.opendev.org>2021-09-17 22:39:35 +0000
committerGerrit Code Review <review@openstack.org>2021-09-17 22:39:35 +0000
commit4ce20afd6eb9a0edd683b232e286dcc80431fdd9 (patch)
tree098542d401c78e6b3a943030a9d4b2316211401c
parent6c2a98c9fe9ec396d93e213cd0b718a1b767cd86 (diff)
parentf3d2b9d540cc789ddc523abeccba733bb23ec5d7 (diff)
downloadhorizon-4ce20afd6eb9a0edd683b232e286dcc80431fdd9.tar.gz
Merge "Preparation for Django 3.2 support"
-rw-r--r--.zuul.d/django-jobs.yaml17
-rw-r--r--tox.ini10
2 files changed, 11 insertions, 16 deletions
diff --git a/.zuul.d/django-jobs.yaml b/.zuul.d/django-jobs.yaml
index 1b73a2447..be8512676 100644
--- a/.zuul.d/django-jobs.yaml
+++ b/.zuul.d/django-jobs.yaml
@@ -22,16 +22,10 @@
- name: openstack/horizon
- job:
- name: horizon-tox-python3-django30
+ name: horizon-tox-python3-django32
parent: horizon-tox-python3-django
vars:
- django_version: '>=3.0,<3.1'
-
-- job:
- name: horizon-tox-python3-django31
- parent: horizon-tox-python3-django
- vars:
- django_version: '>=3.1,<3.2'
+ django_version: '>=3.2,<3.3'
- project-template:
name: horizon-non-primary-django-jobs
@@ -45,13 +39,10 @@
# to keep this project template as it is used in horizon plugins.
# NOTE: We keep it as a template even though it is not used now.
- openstack-tox-py38
- - horizon-tox-python3-django30:
- voting: false
- - horizon-tox-python3-django31:
+ - horizon-tox-python3-django32:
voting: false
gate:
jobs:
- openstack-tox-py38
# Skip these until the django3.x jobs become voting.
- # - horizon-tox-python3-django30
- # - horizon-tox-python3-django31
+ # - horizon-tox-python3-django32
diff --git a/tox.ini b/tox.ini
index 5e6afd99d..4e6e7dc3d 100644
--- a/tox.ini
+++ b/tox.ini
@@ -1,6 +1,6 @@
[tox]
minversion = 3.1
-envlist = pep8,py36,py38,releasenotes,npm,py3-dj{30,31}
+envlist = pep8,py36,py38,releasenotes,npm,py3-dj32
skipsdist = True
# Automatic envs (pyXX) will only use the python version appropriate to that
# env and ignore basepython inherited from [testenv] if we set
@@ -15,6 +15,11 @@ setenv =
PYTHONDONTWRITEBYTECODE = 1
PYTHONWARNINGS = once,ignore::PendingDeprecationWarning
py{3,36,37}:PYTHONWARNINGS = once,ignore::PendingDeprecationWarning,ignore::ImportWarning:backports
+ # DeprecationWarning is disabled in dj32 tox env as Django 3.2
+ # deprecated Django 2.2 features. This workaround is just to reduce
+ # the number of warnings due to this change.
+ # It should be dropped when we drop Django 2.2 support.
+ dj32: PYTHONWARNINGS = once,ignore::PendingDeprecationWarning,ignore::DeprecationWarning
whitelist_externals =
bash
@@ -26,8 +31,7 @@ deps =
# Unit test for a local hacking rule requires hacking.
hacking>=3.0.1,<3.1.0 # Apache-2.0
commands =
- dj30: pip install django>=3.0,<3.1
- dj31: pip install django>=3.1,<3.2
+ dj32: pip install django>=3.2,<3.3
find . -type f -name "*.pyc" -delete
bash {toxinidir}/tools/unit_tests.sh {toxinidir} {posargs}