Skip to content

Commit d593b1b

Browse files
committed
Python 3.10 / Django 4.0 Support
Allow deprecated Django 3.2
1 parent 720adda commit d593b1b

File tree

9 files changed

+44
-23
lines changed

9 files changed

+44
-23
lines changed

.flake8

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
[flake8]
2+
ignore = E203, E266, E501, W503, F403, F401
3+
max-line-length = 120
4+
max-complexity = 18
5+
select = B,C,E,F,W,T4,B9
6+
exclude =
7+
.venv/*
8+
demo_app/*
9+
*/migrations/*
10+
*/tests/*
11+
manage.py
12+
setup.py

.github/workflows/main.yml

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ jobs:
2121
- uses: actions/checkout@v2
2222
- uses: actions/setup-python@v2
2323
with:
24-
python-version: 3.8
24+
python-version: "3.10"
2525

2626
- name: Install dependencies
2727
run: |
@@ -31,7 +31,7 @@ jobs:
3131
pip install -r requirements_dev.txt --user
3232
3333
- name: outdated
34-
run: pip list --outdated --not-required --user | grep . && echo "There are outdated packages" && exit 1 || echo "All packages up to date"
34+
run: pip list --outdated --not-required --exclude=django --user | grep . && echo "There are outdated packages" && exit 1 || echo "All packages up to date"
3535

3636
black:
3737
name: Black
@@ -40,7 +40,7 @@ jobs:
4040
- uses: actions/checkout@v2
4141
- uses: actions/setup-python@v2
4242
with:
43-
python-version: 3.8
43+
python-version: "3.10"
4444

4545
- name: Install dependencies
4646
run: |
@@ -59,7 +59,7 @@ jobs:
5959
- uses: actions/checkout@v2
6060
- uses: actions/setup-python@v2
6161
with:
62-
python-version: 3.8
62+
python-version: "3.10"
6363

6464
- name: Install dependencies
6565
run: |
@@ -79,7 +79,7 @@ jobs:
7979
- uses: actions/checkout@v2
8080
- uses: actions/setup-python@v2
8181
with:
82-
python-version: 3.8
82+
python-version: "3.10"
8383

8484
- name: Install dependencies
8585
run: |
@@ -108,8 +108,8 @@ jobs:
108108
max-parallel: 4
109109
matrix:
110110
db: [ sqlite, mysql ]
111-
django-version: [ "~=3.2" ]
112-
python-version: [ 3.8, 3.9, "3.10"]
111+
django-version: [ "~=3.2", "~=4.0" ]
112+
python-version: [ "3.10" ]
113113
experimental: [ false ]
114114

115115
services:
@@ -169,7 +169,7 @@ jobs:
169169
- uses: actions/checkout@v2
170170
- uses: actions/setup-python@v2
171171
with:
172-
python-version: 3.8
172+
python-version: "3.10"
173173

174174
- name: Install dependencies
175175
run: |
@@ -220,7 +220,7 @@ jobs:
220220
fetch-depth: 0
221221
- uses: actions/setup-python@v2
222222
with:
223-
python-version: 3.8
223+
python-version: "3.10"
224224

225225
- name: Install dependencies
226226
run: |

.idea/django-datatable-view.iml

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/misc.xml

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.idea/watcherTasks.xml

Lines changed: 8 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.pre-commit-config.yaml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
1+
default_language_version:
2+
python: python3.10
13
repos:
24
- repo: git://github.com/pre-commit/pre-commit-hooks
3-
rev: v2.3.0
5+
rev: v4.0.1
46
hooks:
57
- id: check-added-large-files
68
args: [ '--maxkb=500' ]
@@ -19,10 +21,11 @@ repos:
1921
exclude: .idea/.*
2022
- id: check-json
2123
- repo: https://github.com/ambv/black
22-
rev: stable
24+
rev: 21.12b0
2325
hooks:
2426
- id: black
27+
language_version: python3.10
2528
- repo: https://gitlab.com/pycqa/flake8
26-
rev: 3.9.2
29+
rev: 4.0.1
2730
hooks:
2831
- id: flake8

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[tool.black]
22
line-length = 100
3-
target-version = ['py38']
3+
target-version = ['py310']
44
include = '\.pyi?$'
55
exclude = '''
66
/(

requirements.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
python-decouple
2-
python-dateutil~=2.8.1
2+
python-dateutil
33
six
44

5-
Django~=3.2
6-
pytz~=2020.5
5+
Django
6+
pytz

setup.py

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -33,22 +33,20 @@
3333
"Development Status :: 5 - Production/Stable",
3434
"Environment :: Web Environment",
3535
"Framework :: Django",
36-
"Framework :: Django :: 3.0",
37-
"Framework :: Django :: 3.1",
3836
"Framework :: Django :: 3.2",
37+
"Framework :: Django :: 4.0",
3938
"Intended Audience :: Developers",
4039
"License :: OSI Approved :: Apache Software License",
4140
"Operating System :: OS Independent",
4241
"Programming Language :: Python",
4342
"Programming Language :: Python :: 3",
44-
"Programming Language :: Python :: 3.8",
4543
"Programming Language :: Python :: 3.9",
4644
"Programming Language :: Python :: 3.10",
4745
"Topic :: Software Development",
4846
],
49-
python_requires=">=3.8.*",
47+
python_requires=">=3.9.*",
48+
install_requires=["django>=3.2", "python-dateutil"],
5049
packages=find_packages(),
5150
package_data={"datatableview": ["static/js/*.js", "templates/datatableview/*.html"]},
5251
include_package_data=True,
53-
install_requires=["django>=3.0", "python-dateutil"],
5452
)

0 commit comments

Comments
 (0)