Skip to content

Fix DJ check_debug issue with DJ1.10 #38

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Feb 7, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,13 @@ plural text, so both are marked as used if the tag is used.
Changes
~~~~~~~

v1.4.2 --- 2017-01-30
---------------------

Fixes another instance of `issue 32`_, which was the result of an initialization order problem.

.. _issue 32: https://github.com/nedbat/django_coverage_plugin/issues/32


v1.4.1 --- 2017-01-25
---------------------
Expand Down
6 changes: 6 additions & 0 deletions django_coverage_plugin/plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,12 @@ def check_debug():
# into template engines, so we don't need to depend on settings values
# directly and can look at the resulting configured objects

# I _think_ this check is all that's needed and the 3 "hasattr" checks
# below can be removed, but it's not clear how to verify that
from django.apps import apps
if not apps.ready:
return False

# django.template.backends.django gets loaded lazily, so return false
# until they've been loaded
if not hasattr(django.template, "backends"):
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@

setup(
name='django_coverage_plugin',
version='1.4.1',
version='1.4.2',
description='Django template coverage.py plugin',
author='Ned Batchelder',
author_email='ned@nedbatchelder.com',
Expand Down