From 287e4421c98386ebbd314047b0ee58268164dbf3 Mon Sep 17 00:00:00 2001 From: Fabio Caccamo Date: Mon, 2 Dec 2019 18:51:35 +0100 Subject: [PATCH] Added python 3.8 and django 3.0 compatibility. --- CHANGELOG.md | 3 +++ admin_interface/admin.py | 4 ++-- admin_interface/models.py | 12 +++++++----- requirements.txt | 4 ++++ setup.py | 3 +++ tox.ini | 6 ++++-- 6 files changed, 23 insertions(+), 9 deletions(-) create mode 100644 requirements.txt diff --git a/CHANGELOG.md b/CHANGELOG.md index f2e1c61..c6338c7 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,9 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [0.12.0](https://github.com/fabiocaccamo/django-admin-interface/releases/tag/0.12.0) - 2019-12-02 +- Added python 3.8 and django 3.0 compatibility. + ## [0.11.2](https://github.com/fabiocaccamo/django-admin-interface/releases/tag/0.11.2) - 2019-09-27 - Fixed select2 background color. diff --git a/admin_interface/admin.py b/admin_interface/admin.py index 348a854..578acb3 100644 --- a/admin_interface/admin.py +++ b/admin_interface/admin.py @@ -1,10 +1,10 @@ # -*- coding: utf-8 -*- +from admin_interface.models import Theme + from django.contrib import admin from django.utils.translation import ugettext_lazy as _ -from admin_interface.models import Theme - class ThemeAdmin(admin.ModelAdmin): diff --git a/admin_interface/models.py b/admin_interface/models.py index 60bf4ac..aec5aa3 100644 --- a/admin_interface/models.py +++ b/admin_interface/models.py @@ -2,14 +2,16 @@ from __future__ import unicode_literals -from django.db import models -from django.db.models.signals import post_delete, post_save, pre_save -from django.utils.encoding import python_2_unicode_compatible, force_text -from django.utils.translation import ugettext_lazy as _ +from admin_interface.cache import del_cached_active_theme from colorfield.fields import ColorField -from admin_interface.cache import del_cached_active_theme +from django.db import models +from django.db.models.signals import post_delete, post_save, pre_save +from django.utils.encoding import force_text +from django.utils.translation import ugettext_lazy as _ + +from six import python_2_unicode_compatible @python_2_unicode_compatible diff --git a/requirements.txt b/requirements.txt new file mode 100644 index 0000000..9ad4e29 --- /dev/null +++ b/requirements.txt @@ -0,0 +1,4 @@ +django-colorfield +django-flat-theme +django-flat-responsive +six>=1.9.0 \ No newline at end of file diff --git a/setup.py b/setup.py index f446980..3d5a369 100644 --- a/setup.py +++ b/setup.py @@ -37,6 +37,7 @@ setup( 'django-colorfield >= 0.1, < 1.0', 'django-flat-theme >= 1.0, < 2.0', 'django-flat-responsive >= 1.0, < 3.0', + 'six >= 1.9.0, < 2.0.0', ], classifiers=[ 'Development Status :: 5 - Production/Stable', @@ -50,6 +51,7 @@ setup( 'Framework :: Django :: 2.0', 'Framework :: Django :: 2.1', 'Framework :: Django :: 2.2', + 'Framework :: Django :: 3.0', 'Intended Audience :: Developers', 'License :: OSI Approved :: MIT License', 'Natural Language :: English', @@ -61,6 +63,7 @@ setup( 'Programming Language :: Python :: 3.5', 'Programming Language :: Python :: 3.6', 'Programming Language :: Python :: 3.7', + 'Programming Language :: Python :: 3.8', 'Topic :: Software Development :: Build Tools', ], license='MIT', diff --git a/tox.ini b/tox.ini index 6a8a8f7..ac2bb30 100644 --- a/tox.ini +++ b/tox.ini @@ -3,8 +3,9 @@ envlist = py27-{dj17,dj18,dj19,dj110,dj111}-{sqlite,postgres}, py34-{dj17,dj18,dj19,dj110,dj111,dj20}-{sqlite,postgres}, py35-{dj18,dj19,dj110,dj111,dj20,dj21,dj22}-{sqlite,postgres}, - py36-{dj18,dj19,dj110,dj111,dj20,dj21,dj22,djmaster}-{sqlite,postgres}, - py37-{dj20,dj21,dj22,djmaster}-{sqlite,postgres}, + py36-{dj18,dj19,dj110,dj111,dj20,dj21,dj22,dj30,djmaster}-{sqlite,postgres}, + py37-{dj20,dj21,dj22,dj30,djmaster}-{sqlite,postgres}, + py38-{dj22,dj30,djmaster}-{sqlite,postgres}, [testenv] passenv = CI TRAVIS TRAVIS_* deps = @@ -16,6 +17,7 @@ deps = dj20: Django >= 2.0, < 2.1 dj21: Django >= 2.1, < 2.2 dj22: Django >= 2.2, < 2.3 + dj30: Django >= 3.0, < 3.1 djmaster: https://github.com/django/django/archive/master.tar.gz # mysql: mysqlclient postgres: psycopg2-binary