Skip to content

Commit f2d4216

Browse files
committed
Fix gh actions
1 parent 6bd46e2 commit f2d4216

File tree

3 files changed

+10
-7
lines changed

3 files changed

+10
-7
lines changed

.github/workflows/python-app.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ jobs:
2525
- django_version: '3.1'
2626
python_version: '3.5'
2727

28-
- django_version: '3.1'
28+
- django_version: '3.2'
2929
python_version: '3.5'
3030
include:
3131
- django_version: '2.2'
@@ -66,7 +66,7 @@ jobs:
6666
sudo apt-get install -y libproj-dev libgeos-dev gdal-bin libgdal-dev
6767
python -m pip install --upgrade pip
6868
pip install -U flake8 coveralls psycopg2-binary argparse
69-
pip install -U Django~=${{ matrix.django_version }}
69+
pip install -U Django~=${{ matrix.django_version }}.0
7070
- name: Lint with flake8
7171
run: |
7272
flake8 --ignore=E501,W504 leaflet

leaflet/__init__.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
from collections import OrderedDict
2+
from distutils.version import LooseVersion
23
from urllib.parse import urlparse
34

5+
import django
46
from django.conf import settings
57
from django.core.exceptions import ImproperlyConfigured
68
from django.templatetags.static import static
@@ -182,4 +184,5 @@ def _normalize_plugins_config():
182184
PLUGINS['__is_normalized__'] = True
183185

184186

185-
default_app_config = 'leaflet.apps.LeafletConfig'
187+
if LooseVersion(django.__version__) < LooseVersion('3.2'):
188+
default_app_config = 'leaflet.apps.LeafletConfig'

tox.ini

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,10 +9,10 @@ envlist =
99
[testenv]
1010
commands = python -W error::DeprecationWarning -W error::PendingDeprecationWarning -m coverage run ./quicktest.py leaflet --db={env:DATABASE:}
1111
deps =
12-
django22: Django~=2.2
13-
django30: Django~=3.0
14-
django31: Django~=3.1
15-
django32: Django~=3.2
12+
django22: Django~=2.2.0
13+
django30: Django~=3.0.0
14+
django31: Django~=3.1.0
15+
django32: Django~=3.2.0
1616
djangomain: https://github.com/django/django/archive/main.tar.gz
1717
postgres: psycopg2-binary
1818
coverage

0 commit comments

Comments
 (0)