Skip to content

Commit 63e4bd8

Browse files
author
Ross Mechanic
authored
Merge pull request #358 from treyhunner/remove-support-for-django-1.7
Remove support for Django 1.7
2 parents 24a5f00 + dd09251 commit 63e4bd8

File tree

7 files changed

+12
-21
lines changed

7 files changed

+12
-21
lines changed

.travis.yml

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ python:
99
- 3.6
1010

1111
env:
12-
- DJANGO="Django>=1.7,<1.8"
1312
- DJANGO="Django>=1.8,<1.9"
1413
- DJANGO="Django>=1.9,<1.10"
1514
- DJANGO="Django>=1.10,<1.11"
@@ -22,11 +21,4 @@ install:
2221

2322
script: coverage run setup.py test
2423

25-
matrix:
26-
exclude:
27-
- python: 3.5
28-
env: DJANGO="Django>=1.7,<1.8"
29-
- python: 3.6
30-
env: DJANGO="Django>=1.7,<1.8"
31-
3224
after_success: codecov

CHANGES.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ Changes
22
=======
33

44
1.9.1 (2018-03-30)
5-
----------
5+
------------------
66
- Use get_queryset rather than model.objects in history_view. (gh-303)
77
- Change ugettext calls in models.py to ugettext_lazy
88
- Resolve issue where model references itself (gh-278)

README.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ django-simple-history
2020

2121
django-simple-history stores Django model state on every create/update/delete.
2222

23-
This app requires Django 1.7 or greater and Python 2.7, or 3.4 or greater.
23+
This app requires Django 1.8 or greater and Python 2.7, or 3.4 or greater.
2424

2525
Getting Help
2626
------------

setup.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
import simple_history
33

44
tests_require = [
5-
'Django>=1.7', 'WebTest==2.0.24', 'django-webtest==1.8.0', 'mock==1.0.1']
5+
'Django>=1.8', 'WebTest==2.0.24', 'django-webtest==1.8.0', 'mock==1.0.1']
66

77
setup(
88
name='django-simple-history',
@@ -24,6 +24,11 @@
2424
"Framework :: Django",
2525
"Environment :: Web Environment",
2626
"Intended Audience :: Developers",
27+
"Framework :: Django",
28+
"Framework :: Django :: 1.8",
29+
"Framework :: Django :: 1.9",
30+
"Framework :: Django :: 1.10",
31+
"Framework :: Django :: 1.11",
2732
"Programming Language :: Python",
2833
"Programming Language :: Python :: 2.7",
2934
'Programming Language :: Python :: 3',

simple_history/management/commands/populate_history.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ def _model_from_natural_key(self, natural_key):
9494
else:
9595
try:
9696
model = get_model(app_label, model)
97-
except LookupError: # Django >= 1.7
97+
except LookupError:
9898
model = None
9999
if not model:
100100
raise ValueError(self.MODEL_NOT_FOUND +

simple_history/models.py

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -124,13 +124,9 @@ def create_history_model(self, model, inherited):
124124
# registered under different app
125125
attrs['__module__'] = self.module
126126
elif app_module != self.module:
127-
try:
128-
# Abuse an internal API because the app registry is loading.
129-
app = apps.app_configs[model._meta.app_label]
130-
except NameError: # Django < 1.7
131-
models_module = get_app(model._meta.app_label).__name__
132-
else:
133-
models_module = app.name
127+
# Abuse an internal API because the app registry is loading.
128+
app = apps.app_configs[model._meta.app_label]
129+
models_module = app.name
134130
attrs['__module__'] = models_module
135131

136132
fields = self.copy_fields(model)

tox.ini

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
[tox]
22
envlist =
3-
py{27,34}-django17,
43
py{27,34,35}-django18,
54
py{27,34,35}-django19,
65
py{27,34,35,36}-django110,
@@ -30,7 +29,6 @@ commands = sphinx-build -W -b html -d {envtmpdir}/doctrees . {envtmpdir}/html
3029
[testenv]
3130
deps =
3231
coverage
33-
django17: Django>=1.7,<1.8
3432
django18: Django>=1.8,<1.9
3533
django19: Django>=1.9,<1.10
3634
django110: Django>=1.10,<1.11

0 commit comments

Comments
 (0)