Skip to content

Commit 7bf126d

Browse files
Added support for Django 4.0 (#898)
* Added support for Django 4.0 Co-authored-by: tschilling <[email protected]>
1 parent fa7179b commit 7bf126d

File tree

8 files changed

+16
-5
lines changed

8 files changed

+16
-5
lines changed

.github/workflows/test.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ jobs:
1212
fail-fast: false
1313
matrix:
1414
python-version: ['3.6', '3.7', '3.8', '3.9', '3.10']
15-
django-version: ['2.2', '3.1', '3.2', 'main']
15+
django-version: ['2.2', '3.1', '3.2', '4.0rc1', 'main']
1616

1717
exclude:
1818
- python-version: '3.6'
@@ -23,6 +23,10 @@ jobs:
2323
django-version: '2.2'
2424
- python-version: '3.10'
2525
django-version: '3.1'
26+
- python-version: '3.6'
27+
django-version: '4.0b1'
28+
- python-version: '3.7'
29+
django-version: '4.0b1'
2630

2731
services:
2832

AUTHORS.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ Authors
3333
- Daniil Skrobov (`yetanotherape <https://github.com/yetanotherape>`_)
3434
- David Grochowski (`ThePumpingLemma <https://github.com/ThePumpingLemma>`_)
3535
- David Hite
36+
- David Smith
3637
- Dmytro Shyshov (`xahgmah <https://github.com/xahgmah>`_)
3738
- Edouard Richard (`vied12 <https://github.com/vied12>` _)
3839
- Eduardo Cuducos

CHANGES.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ Full list of changes:
2525
- Added ability to break into debugger on unit test failure (gh-890)
2626
- Russian translations update (gh-897)
2727
- Add Python 3.10 to test matrix (gh-899)
28+
- Added support for Django 4.0 (gh-898)
2829

2930
3.0.0 (2021-04-16)
3031
------------------

README.rst

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,12 +38,13 @@ django-simple-history stores Django model state on every create/update/delete.
3838

3939
This app supports the following combinations of Django and Python:
4040

41-
========== =======================
41+
========== ========================
4242
Django Python
4343
========== ========================
4444
2.2 3.6, 3.7, 3.8, 3.9
4545
3.1 3.6, 3.7, 3.8, 3.9
4646
3.2 3.6, 3.7, 3.8, 3.9, 3.10
47+
4.0 3.8, 3.9, 3.10
4748
========== ========================
4849

4950
Getting Help

docs/common_issues.rst

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -262,7 +262,8 @@ Using custom OneToOneFields
262262
If you are using a custom OneToOneField that has additional arguments and receiving
263263
the the following ``TypeError``::
264264

265-
..
265+
.. code=block:: python
266+
266267
TypeError: __init__() got an unexpected keyword argument
267268
268269
This is because Django Simple History coerces ``OneToOneField`` into ``ForeignKey``

setup.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@
2626
"Framework :: Django :: 2.2",
2727
"Framework :: Django :: 3.1",
2828
"Framework :: Django :: 3.2",
29+
"Framework :: Django :: 4.0",
2930
"Programming Language :: Python",
3031
"Programming Language :: Python :: 3.6",
3132
"Programming Language :: Python :: 3.7",

simple_history/tests/tests/test_manager.py

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

44
from django.contrib.auth import get_user_model
55
from django.db import IntegrityError
6-
from django.test import TestCase, skipUnlessDBFeature, override_settings
6+
from django.test import TestCase, override_settings, skipUnlessDBFeature
77

88
from ..models import Document, Poll
99

tox.ini

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
envlist =
33
py{36,37,38,39}-dj{22,31}-{sqlite3,postgres,mysql,mariadb},
44
py{36,37,38,39,310}-dj32-{sqlite3,postgres,mysql,mariadb},
5-
py{38,39,310}-djmain-{sqlite3,postgres,mysql,mariadb},
5+
py{38,39,310}-dj{40,main}-{sqlite3,postgres,mysql,mariadb},
66
docs,
77
lint
88

@@ -19,6 +19,7 @@ DJANGO =
1919
2.2: dj22
2020
3.1: dj31
2121
3.2: dj32
22+
4.0: dj40
2223
main: djmain
2324

2425
[flake8]
@@ -33,6 +34,7 @@ deps =
3334
dj22: Django>=2.2,<2.3
3435
dj31: Django>=3.1,<3.2
3536
dj32: Django>=3.2,<3.3
37+
dj40: Django>=4.0rc1,<4.1
3638
djmain: https://github.com/django/django/tarball/main
3739
postgres: -rrequirements/postgres.txt
3840
mysql: -rrequirements/mysql.txt

0 commit comments

Comments
 (0)