From dfbba95cb6194bc6755c4e8583baaa391cf03ddd Mon Sep 17 00:00:00 2001 From: Saleem Latif Date: Wed, 2 Oct 2019 16:40:20 +0500 Subject: [PATCH 1/7] Removing python 2 support. --- .travis.yml | 3 --- 1 file changed, 3 deletions(-) diff --git a/.travis.yml b/.travis.yml index 8f4fbea..020a7e7 100644 --- a/.travis.yml +++ b/.travis.yml @@ -3,15 +3,12 @@ language: python python: - - 2.7 - 3.5 matrix: include: - python: 3.5 env: TOXENV=quality - - python: 2.7 - env: TOXENV=quality script: - make clean From d6a5508f863b21c7b57ec06711628e9f4b0b0151 Mon Sep 17 00:00:00 2001 From: Saleem Latif Date: Wed, 2 Oct 2019 16:48:39 +0500 Subject: [PATCH 2/7] Resolved an error related to unused packege. --- requirements/base.txt | 5 +---- requirements/dev.in | 4 ---- requirements/dev.txt | 28 ++++++---------------------- requirements/quality.txt | 8 ++++---- requirements/test.txt | 5 +---- 5 files changed, 12 insertions(+), 38 deletions(-) diff --git a/requirements/base.txt b/requirements/base.txt index 0fa2f65..9087aa1 100644 --- a/requirements/base.txt +++ b/requirements/base.txt @@ -2,11 +2,8 @@ # This file is autogenerated by pip-compile # To update, run: # -# pip-compile --output-file requirements/base.txt requirements/base.in +# pip-compile --output-file=requirements/base.txt requirements/base.in # ---index-url https://pypi.org/simple/ ---extra-index-url https://saleem.latif:AP81xRt5DR6ruigseCVZpcYxA1QFyuHvZ4ky6m@intechww.jfrog.io/intechww/api/pypi/pypi-virtual/simple - django==1.11.25 importlib-metadata==0.23 # via path.py more-itertools==7.2.0 # via zipp diff --git a/requirements/dev.in b/requirements/dev.in index 7941763..0fc4851 100644 --- a/requirements/dev.in +++ b/requirements/dev.in @@ -1,8 +1,4 @@ # Additional requirements for development of this application -diff-cover # Changeset diff test coverage pip-tools # Requirements file management tox # virtualenv management for tests -tox-battery==0.5 # Makes tox aware of requirements file changes (it's experimental, so keep it pinned) -twine # Utility for PyPI package uploads -wheel # For generation of wheels for PyPI diff --git a/requirements/dev.txt b/requirements/dev.txt index a639ad7..8013515 100644 --- a/requirements/dev.txt +++ b/requirements/dev.txt @@ -2,38 +2,28 @@ # This file is autogenerated by pip-compile # To update, run: # -# pip-compile --output-file requirements/dev.txt requirements/base.in requirements/dev.in requirements/quality.in requirements/test.in +# pip-compile --output-file=requirements/dev.txt requirements/base.in requirements/dev.in requirements/quality.in requirements/test.in # ---index-url https://pypi.org/simple/ ---extra-index-url https://saleem.latif:AP81xRt5DR6ruigseCVZpcYxA1QFyuHvZ4ky6m@intechww.jfrog.io/intechww/api/pypi/pypi-virtual/simple - argparse==1.4.0 # via caniusepython3 astroid==2.3.1 # via pylint atomicwrites==1.3.0 # via pytest attrs==19.2.0 # via pytest backports.functools-lru-cache==1.5 # via caniusepython3 -bleach==3.1.0 # via readme-renderer caniusepython3==7.1.0 certifi==2019.9.11 # via requests chardet==3.0.4 # via requests click==7.0 # via pip-tools coverage==4.5.4 # via pytest-cov ddt==1.2.1 -diff-cover==2.3.0 distlib==0.2.9.post0 # via caniusepython3 django==1.11.25 -docutils==0.15.2 # via readme-renderer factory-boy==2.12.0 faker==2.0.2 # via factory-boy filelock==3.0.12 # via tox idna==2.8 # via requests importlib-metadata==0.23 # via path.py, pluggy, pytest, tox -inflect==2.1.0 # via jinja2-pluralize isort==4.3.21 -jinja2-pluralize==0.3.0 # via diff-cover -jinja2==2.10.1 # via diff-cover, jinja2-pluralize lazy-object-proxy==1.4.2 # via astroid -markupsafe==1.1.1 # via jinja2 mccabe==0.6.1 # via pylint mock==3.0.5 more-itertools==7.2.0 # via pytest, zipp @@ -41,12 +31,10 @@ packaging==19.2 # via caniusepython3, pytest, tox path.py==12.0.1 pep8==1.7.1 pip-tools==4.1.0 -pkginfo==1.5.0.1 # via twine pluggy==0.13.0 # via pytest, tox py==1.8.0 # via pytest, tox pycodestyle==2.5.0 pydocstyle==4.0.1 -pygments==2.4.2 # via diff-cover, readme-renderer pylint==2.4.2 pyparsing==2.4.2 # via packaging pytest-cov==2.7.1 @@ -54,22 +42,18 @@ pytest-django==3.5.1 pytest==5.2.0 # via pytest-cov, pytest-django python-dateutil==2.8.0 # via faker pytz==2019.2 # via django -readme-renderer==24.0 # via twine -requests-toolbelt==0.9.1 # via twine -requests==2.22.0 # via caniusepython3, requests-toolbelt, twine -six==1.12.0 # via astroid, bleach, diff-cover, faker, mock, packaging, pip-tools, python-dateutil, readme-renderer, tox +requests==2.22.0 # via caniusepython3 +six==1.12.0 # via astroid, faker, mock, packaging, pip-tools, python-dateutil, tox snowballstemmer==1.9.1 # via pydocstyle text-unidecode==1.3 # via faker toml==0.10.0 # via tox -tox-battery==0.5 tox==3.14.0 -tqdm==4.36.1 # via twine -twine==2.0.0 typed-ast==1.4.0 # via astroid urllib3==1.25.6 # via requests virtualenv==16.7.5 # via tox wcwidth==0.1.7 # via pytest -webencodings==0.5.1 # via bleach -wheel==0.33.6 wrapt==1.11.2 # via astroid zipp==0.6.0 # via importlib-metadata + +# The following packages are considered to be unsafe in a requirements file: +# setuptools==41.2.0 # via caniusepython3 diff --git a/requirements/quality.txt b/requirements/quality.txt index e72a98d..7857a20 100644 --- a/requirements/quality.txt +++ b/requirements/quality.txt @@ -2,11 +2,8 @@ # This file is autogenerated by pip-compile # To update, run: # -# pip-compile --output-file requirements/quality.txt requirements/base.in requirements/quality.in requirements/test.in +# pip-compile --output-file=requirements/quality.txt requirements/base.in requirements/quality.in requirements/test.in # ---index-url https://pypi.org/simple/ ---extra-index-url https://saleem.latif:AP81xRt5DR6ruigseCVZpcYxA1QFyuHvZ4ky6m@intechww.jfrog.io/intechww/api/pypi/pypi-virtual/simple - argparse==1.4.0 # via caniusepython3 astroid==2.3.1 # via pylint atomicwrites==1.3.0 # via pytest @@ -51,3 +48,6 @@ urllib3==1.25.6 # via requests wcwidth==0.1.7 # via pytest wrapt==1.11.2 # via astroid zipp==0.6.0 # via importlib-metadata + +# The following packages are considered to be unsafe in a requirements file: +# setuptools==41.2.0 # via caniusepython3 diff --git a/requirements/test.txt b/requirements/test.txt index fa6dc67..3f1ba36 100644 --- a/requirements/test.txt +++ b/requirements/test.txt @@ -2,11 +2,8 @@ # This file is autogenerated by pip-compile # To update, run: # -# pip-compile --output-file requirements/test.txt requirements/base.in requirements/test.in +# pip-compile --output-file=requirements/test.txt requirements/base.in requirements/test.in # ---index-url https://pypi.org/simple/ ---extra-index-url https://saleem.latif:AP81xRt5DR6ruigseCVZpcYxA1QFyuHvZ4ky6m@intechww.jfrog.io/intechww/api/pypi/pypi-virtual/simple - atomicwrites==1.3.0 # via pytest attrs==19.2.0 # via pytest coverage==4.5.4 # via pytest-cov From c68f478312b4bc6e05dc3395b7817c9cc107a005 Mon Sep 17 00:00:00 2001 From: Saleem Latif Date: Wed, 2 Oct 2019 17:30:16 +0500 Subject: [PATCH 3/7] Quality fixes --- test_utils/factories.py | 4 ++-- test_utils/testcases.py | 2 -- tests/test_theming/test_apps.py | 8 ++++---- tests/test_theming/test_models.py | 1 + theming/apps.py | 12 ++++++------ theming/exceptions.py | 6 ------ theming/static/finders.py | 5 ++++- 7 files changed, 17 insertions(+), 21 deletions(-) diff --git a/test_utils/factories.py b/test_utils/factories.py index a65fad6..cf0a60b 100644 --- a/test_utils/factories.py +++ b/test_utils/factories.py @@ -14,7 +14,7 @@ class SiteFactory(DjangoModelFactory): Factory for django.contrib.sites.models.Site. """ - class Meta(object): + class Meta: model = Site django_get_or_create = ('domain',) @@ -27,7 +27,7 @@ class ThemeFactory(DjangoModelFactory): Factory for theming.models.Theme. """ - class Meta(object): + class Meta: model = Theme django_get_or_create = ('site',) diff --git a/test_utils/testcases.py b/test_utils/testcases.py index a3f71da..306f4f7 100644 --- a/test_utils/testcases.py +++ b/test_utils/testcases.py @@ -8,5 +8,3 @@ class TestCase(DjangoTestCase): """ Base test case for theme tests. """ - - pass diff --git a/tests/test_theming/test_apps.py b/tests/test_theming/test_apps.py index f95f23f..adba46b 100644 --- a/tests/test_theming/test_apps.py +++ b/tests/test_theming/test_apps.py @@ -73,9 +73,9 @@ def test_ready_with_missing_theme_settings(self): # pylint: disable=invalid-nam """ del settings.THEMING with assertRaisesRegex( - self, - ImproperlyConfigured, - r'"THEMING" setting not set in django settings file. ' - r'If you are not using theming then remove it from INSTALLED_APPS.' + self, + ImproperlyConfigured, + r'"THEMING" setting not set in django settings file. ' + r'If you are not using theming then remove it from INSTALLED_APPS.' ): self.theming_config.ready() diff --git a/tests/test_theming/test_models.py b/tests/test_theming/test_models.py index 31c579b..65cf8c5 100644 --- a/tests/test_theming/test_models.py +++ b/tests/test_theming/test_models.py @@ -1,3 +1,4 @@ +# pylint: disable=no-member """ Validate theming models. """ diff --git a/theming/apps.py b/theming/apps.py index 39691b5..0d513fc 100644 --- a/theming/apps.py +++ b/theming/apps.py @@ -33,27 +33,27 @@ def ready(self): '"THEMING" setting not set in django settings file. ' 'If you are not using theming then remove it from INSTALLED_APPS.' ) - elif 'DIRS' not in settings.THEMING: + if 'DIRS' not in settings.THEMING: raise ImproperlyConfigured( 'The THEMING["DIRS"] setting must be populated.', ) - elif 'ENABLED' not in settings.THEMING: + if 'ENABLED' not in settings.THEMING: raise ImproperlyConfigured( 'The THEMING["ENABLED"] setting must be populated.', ) - elif not isinstance(settings.THEMING['DIRS'], (list, tuple)): + if not isinstance(settings.THEMING['DIRS'], (list, tuple)): raise ImproperlyConfigured( 'The THEMING["DIRS"] setting is not a tuple or list. Perhaps you forgot a trailing comma?', ) - elif not all([isinstance(theme_dir, str) for theme_dir in settings.THEMING['DIRS']]): + if not all([isinstance(theme_dir, str) for theme_dir in settings.THEMING['DIRS']]): raise ImproperlyConfigured( 'THEMING["DIRS"] must contain only string paths.', ) - elif not all([theme_dir.startswith("/") for theme_dir in settings.THEMING['DIRS']]): + if not all([theme_dir.startswith("/") for theme_dir in settings.THEMING['DIRS']]): raise ImproperlyConfigured( 'THEMING["DIRS"] must contain only absolute paths to themes dirs.', ) - elif not all([os.path.isdir(theme_dir) for theme_dir in settings.THEMING['DIRS']]): + if not all([os.path.isdir(theme_dir) for theme_dir in settings.THEMING['DIRS']]): raise ImproperlyConfigured( 'THEMING["DIRS"] must contain valid paths.', ) diff --git a/theming/exceptions.py b/theming/exceptions.py index 878b1b5..22e5da4 100644 --- a/theming/exceptions.py +++ b/theming/exceptions.py @@ -9,20 +9,14 @@ class ThemeException(Exception): Base exception for all theming related exceptions. """ - pass - class MiddlewareNotActivated(ThemeException): """ Exception raised when features being used depends on a theming middleware. """ - pass - class ImproperlyConfigured(ThemeException, DjangoImproperlyConfigured): """ Theming is somehow improperly configured. """ - - pass diff --git a/theming/static/finders.py b/theming/static/finders.py index 795bc83..cb56366 100644 --- a/theming/static/finders.py +++ b/theming/static/finders.py @@ -44,7 +44,10 @@ def __init__(self, *args, **kwargs): super(ThemeFilesFinder, self).__init__(*args, **kwargs) - def check(self, **kwargs): + def check(self, **kwargs): # pylint: disable=unused-argument + """ + Check if current instance data has errors. + """ errors = [] if 'DIRS' not in settings.THEMING: errors.append(Error( From b0683c28439fd528dc0fc0fc7f6ad7dc6a00ece9 Mon Sep 17 00:00:00 2001 From: Saleem Latif Date: Wed, 2 Oct 2019 17:35:49 +0500 Subject: [PATCH 4/7] pylint fixes --- theming/static/storage.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/theming/static/storage.py b/theming/static/storage.py index 07742ec..d300ae9 100644 --- a/theming/static/storage.py +++ b/theming/static/storage.py @@ -92,6 +92,6 @@ def themed(self, name, theme_name): name = name[1:] if name.startswith("/") else name path = safe_join(themed_path, name) return os.path.exists(path) + # in live mode check static asset in the static files dir defined by "STATIC_ROOT" setting - else: - return self.exists(os.path.join(theme_name, name)) + return self.exists(os.path.join(theme_name, name)) From d6cd62ae6425db04e1d7e35d66fd9a519af9623a Mon Sep 17 00:00:00 2001 From: Saleem Latif Date: Wed, 2 Oct 2019 17:57:05 +0500 Subject: [PATCH 5/7] More quality fixes --- settings/test.py | 1 + test_utils/factories.py | 2 ++ test_utils/testcases.py | 2 ++ test_utils/utils.py | 2 ++ tests/test_theming/test_apps.py | 2 ++ tests/test_theming/test_core.py | 2 ++ tests/test_theming/test_middleware.py | 1 + tests/test_theming/test_models.py | 2 ++ tests/test_theming/test_static/test_finders.py | 2 ++ tests/test_theming/test_static/test_storage.py | 2 ++ tests/test_theming/test_template/test_loaders/test_theme.py | 2 ++ tests/test_theming/test_thread_locals.py | 2 ++ theming/__init__.py | 2 ++ theming/admin.py | 2 ++ theming/apps.py | 2 ++ theming/core.py | 2 ++ theming/exceptions.py | 2 ++ theming/middleware.py | 1 + theming/models.py | 1 + theming/static/finders.py | 2 ++ theming/static/storage.py | 2 ++ theming/template/loaders/theme.py | 1 + theming/thread_locals.py | 1 + 23 files changed, 40 insertions(+) diff --git a/settings/test.py b/settings/test.py index a9701b4..eff4b5d 100644 --- a/settings/test.py +++ b/settings/test.py @@ -9,6 +9,7 @@ For the full list of settings and their values, see https://docs.djangoproject.com/en/1.11/ref/settings/ """ +from __future__ import absolute_import import os from path import Path diff --git a/test_utils/factories.py b/test_utils/factories.py index cf0a60b..f7c8514 100644 --- a/test_utils/factories.py +++ b/test_utils/factories.py @@ -1,6 +1,8 @@ """ Theming Factories. """ +from __future__ import absolute_import + import factory from factory.django import DjangoModelFactory diff --git a/test_utils/testcases.py b/test_utils/testcases.py index 306f4f7..8e5d62f 100644 --- a/test_utils/testcases.py +++ b/test_utils/testcases.py @@ -1,6 +1,8 @@ """ Module containing functions and methods common to all theme related tests. """ +from __future__ import absolute_import + from django.test import TestCase as DjangoTestCase diff --git a/test_utils/utils.py b/test_utils/utils.py index 80274d9..d4f16cd 100644 --- a/test_utils/utils.py +++ b/test_utils/utils.py @@ -1,6 +1,8 @@ """ Utility functions used by the tests in `theming` app. """ +from __future__ import absolute_import + from django.test import RequestFactory from theming.thread_locals import get_current_request, set_current_request, set_current_theme diff --git a/tests/test_theming/test_apps.py b/tests/test_theming/test_apps.py index adba46b..76ac22c 100644 --- a/tests/test_theming/test_apps.py +++ b/tests/test_theming/test_apps.py @@ -1,6 +1,8 @@ """ Validate ThemingConfig """ +from __future__ import absolute_import + import ddt from six import assertRaisesRegex diff --git a/tests/test_theming/test_core.py b/tests/test_theming/test_core.py index d67327c..06abef7 100644 --- a/tests/test_theming/test_core.py +++ b/tests/test_theming/test_core.py @@ -1,6 +1,8 @@ """ Validate theming core. """ +from __future__ import absolute_import + import os import ddt diff --git a/tests/test_theming/test_middleware.py b/tests/test_theming/test_middleware.py index 8e191c9..3a36dec 100644 --- a/tests/test_theming/test_middleware.py +++ b/tests/test_theming/test_middleware.py @@ -1,6 +1,7 @@ """ Validate theming middleware. """ +from __future__ import absolute_import from django.test import RequestFactory diff --git a/tests/test_theming/test_models.py b/tests/test_theming/test_models.py index 65cf8c5..ff36743 100644 --- a/tests/test_theming/test_models.py +++ b/tests/test_theming/test_models.py @@ -2,6 +2,8 @@ """ Validate theming models. """ +from __future__ import absolute_import + from functools import partial import ddt diff --git a/tests/test_theming/test_static/test_finders.py b/tests/test_theming/test_static/test_finders.py index 183382b..8624a90 100644 --- a/tests/test_theming/test_static/test_finders.py +++ b/tests/test_theming/test_static/test_finders.py @@ -1,6 +1,8 @@ """ Tests to validate theme finders work as expected. """ +from __future__ import absolute_import + import ddt from django.core.checks import Error diff --git a/tests/test_theming/test_static/test_storage.py b/tests/test_theming/test_static/test_storage.py index 068abee..0b33ff0 100644 --- a/tests/test_theming/test_static/test_storage.py +++ b/tests/test_theming/test_static/test_storage.py @@ -1,6 +1,8 @@ """ Tests to validate theme storage classes work as expected.. """ +from __future__ import absolute_import + import ddt from django.conf import settings diff --git a/tests/test_theming/test_template/test_loaders/test_theme.py b/tests/test_theming/test_template/test_loaders/test_theme.py index 56ac58a..43a4fd1 100644 --- a/tests/test_theming/test_template/test_loaders/test_theme.py +++ b/tests/test_theming/test_template/test_loaders/test_theme.py @@ -1,6 +1,8 @@ """ Validate theme template loaders. """ +from __future__ import absolute_import + from functools import partial import ddt diff --git a/tests/test_theming/test_thread_locals.py b/tests/test_theming/test_thread_locals.py index 9b059ee..5b83a99 100644 --- a/tests/test_theming/test_thread_locals.py +++ b/tests/test_theming/test_thread_locals.py @@ -1,6 +1,8 @@ """ Validate thread_locals module of theming. """ +from __future__ import absolute_import + from functools import partial from threading import local diff --git a/theming/__init__.py b/theming/__init__.py index 8df261b..8ddb9dd 100644 --- a/theming/__init__.py +++ b/theming/__init__.py @@ -1,6 +1,8 @@ """ Module to hold all the nuts and bolts for theming a django site. """ +from __future__ import absolute_import + __version__ = "0.1.0" from .core import is_enabled, get_base_dir, get_themes diff --git a/theming/admin.py b/theming/admin.py index 5650a31..a649d5f 100644 --- a/theming/admin.py +++ b/theming/admin.py @@ -1,6 +1,8 @@ """ Module containing admin interfaces for the theming app. """ +from __future__ import absolute_import + from django.contrib import admin from .models import Theme diff --git a/theming/apps.py b/theming/apps.py index 0d513fc..04f542f 100644 --- a/theming/apps.py +++ b/theming/apps.py @@ -1,6 +1,8 @@ """ App Config for theming. """ +from __future__ import absolute_import + import os from django.apps import AppConfig diff --git a/theming/core.py b/theming/core.py index 5df8a81..da55320 100644 --- a/theming/core.py +++ b/theming/core.py @@ -1,6 +1,8 @@ """ Core logic for Theming. """ +from __future__ import absolute_import + import os from path import Path diff --git a/theming/exceptions.py b/theming/exceptions.py index 22e5da4..13c099c 100644 --- a/theming/exceptions.py +++ b/theming/exceptions.py @@ -1,6 +1,8 @@ """ Module to contain all of the exceptions defined and used by the theming app. """ +from __future__ import absolute_import + from django.core.exceptions import ImproperlyConfigured as DjangoImproperlyConfigured diff --git a/theming/middleware.py b/theming/middleware.py index 2856c4b..21fb231 100644 --- a/theming/middleware.py +++ b/theming/middleware.py @@ -1,6 +1,7 @@ """ Module to contain middleware defined by the theming app. """ +from __future__ import absolute_import from django.utils.deprecation import MiddlewareMixin diff --git a/theming/models.py b/theming/models.py index 2e9ca8b..be16453 100644 --- a/theming/models.py +++ b/theming/models.py @@ -1,6 +1,7 @@ """ Module to contain model definitions for theming app. """ +from __future__ import absolute_import from path import Path diff --git a/theming/static/finders.py b/theming/static/finders.py index cb56366..12e10e2 100644 --- a/theming/static/finders.py +++ b/theming/static/finders.py @@ -3,6 +3,8 @@ https://docs.djangoproject.com/en/1.8/ref/settings/#std:setting-STATICFILES_FINDERS Yes, this interface is private and undocumented, but we need to access it anyway. """ +from __future__ import absolute_import + import os from collections import OrderedDict diff --git a/theming/static/storage.py b/theming/static/storage.py index d300ae9..052cd5f 100644 --- a/theming/static/storage.py +++ b/theming/static/storage.py @@ -2,6 +2,8 @@ Theming support for Django's collectstatic functionality. See https://docs.djangoproject.com/en/1.8/ref/contrib/staticfiles/ """ +from __future__ import absolute_import + import os.path from django.conf import settings diff --git a/theming/template/loaders/theme.py b/theming/template/loaders/theme.py index cf6d65b..db68ee8 100644 --- a/theming/template/loaders/theme.py +++ b/theming/template/loaders/theme.py @@ -1,6 +1,7 @@ """ Wrapper for loading templates from "templates" directories for themes. """ +from __future__ import absolute_import from django.template.loaders.filesystem import Loader as FilesystemLoader diff --git a/theming/thread_locals.py b/theming/thread_locals.py index ed9cba2..889b7c9 100644 --- a/theming/thread_locals.py +++ b/theming/thread_locals.py @@ -2,6 +2,7 @@ """ Thread scoped variables. """ +from __future__ import absolute_import from threading import local From 73c90bac301d3651a3c07c34049525cbdbae91e4 Mon Sep 17 00:00:00 2001 From: Saleem Latif Date: Wed, 2 Oct 2019 18:13:55 +0500 Subject: [PATCH 6/7] quality fixes --- test_utils/__init__.py | 1 + theming/core.py | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/test_utils/__init__.py b/test_utils/__init__.py index d83adee..fcb09bd 100644 --- a/test_utils/__init__.py +++ b/test_utils/__init__.py @@ -1,6 +1,7 @@ """ Utility functions for theming tests. """ +from __future__ import absolute_import import os from path import Path diff --git a/theming/core.py b/theming/core.py index da55320..a5d2990 100644 --- a/theming/core.py +++ b/theming/core.py @@ -1,7 +1,7 @@ """ Core logic for Theming. """ -from __future__ import absolute_import +from __future__ import absolute_import, division import os From af69f4d2e0f0a2b0ca76490eefceeda171dc59b0 Mon Sep 17 00:00:00 2001 From: Saleem Latif Date: Wed, 2 Oct 2019 18:26:53 +0500 Subject: [PATCH 7/7] fixing isort --- test_utils/__init__.py | 1 + theming/__init__.py | 3 ++- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/test_utils/__init__.py b/test_utils/__init__.py index fcb09bd..b0566ed 100644 --- a/test_utils/__init__.py +++ b/test_utils/__init__.py @@ -4,6 +4,7 @@ from __future__ import absolute_import import os + from path import Path from django.conf import settings diff --git a/theming/__init__.py b/theming/__init__.py index 8ddb9dd..66d4248 100644 --- a/theming/__init__.py +++ b/theming/__init__.py @@ -3,8 +3,9 @@ """ from __future__ import absolute_import +from .core import get_base_dir, get_themes, is_enabled + __version__ = "0.1.0" -from .core import is_enabled, get_base_dir, get_themes default_app_config = "theming.apps.ThemingConfig" # pylint: disable=invalid-name