[Django] #29002: Documentation about cached template loader is inaccurate about DEBUG

51 views
Skip to first unread message

Django

unread,
Jan 9, 2018, 6:59:39 AM1/9/18
to django-...@googlegroups.com
#29002: Documentation about cached template loader is inaccurate about DEBUG
-----------------------------------------+------------------------
Reporter: oTree-org | Owner: nobody
Type: Bug | Status: new
Component: Documentation | Version: 2.0
Severity: Normal | Keywords:
Triage Stage: Unreviewed | Has patch: 0
Needs documentation: 0 | Needs tests: 0
Patch needs improvement: 0 | Easy pickings: 0
UI/UX: 0 |
-----------------------------------------+------------------------
The documentation here:
https://docs.djangoproject.com/en/2.0/ref/templates/api/#django.template.loaders.cached.Loader

It says about the cached template loader:


{{{
This loader is automatically enabled if DEBUG is False and
OPTIONS['loaders'] isn’t specified.
}}}


Actually, it's not based on DEBUG per se, but rather the template engine's
'debug' option, which is acknowledged correctly elsewhere in the docs.

So, I would correct that text to:


{{{
This loader is automatically enabled if OPTIONS['loaders'] isn’t specified
and the template engine's debug option is False (if not set, this option
defaults to the value of DEBUG)
}}}

--
Ticket URL: <https://code.djangoproject.com/ticket/29002>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

Django

unread,
Jan 9, 2018, 7:00:49 AM1/9/18
to django-...@googlegroups.com
#29002: Documentation about cached template loader is inaccurate about DEBUG
-------------------------------+--------------------------------------

Reporter: oTree-org | Owner: nobody
Type: Bug | Status: new
Component: Documentation | Version: 2.0
Severity: Normal | Resolution:

Keywords: | Triage Stage: Unreviewed
Has patch: 0 | Needs documentation: 0
Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------+--------------------------------------
Description changed by oTree-org:

Old description:

> The documentation here:
> https://docs.djangoproject.com/en/2.0/ref/templates/api/#django.template.loaders.cached.Loader
>
> It says about the cached template loader:
>

> {{{
> This loader is automatically enabled if DEBUG is False and
> OPTIONS['loaders'] isn’t specified.
> }}}
>

> Actually, it's not based on DEBUG per se, but rather the template
> engine's 'debug' option, which is acknowledged correctly elsewhere in the
> docs.
>
> So, I would correct that text to:
>

> {{{
> This loader is automatically enabled if OPTIONS['loaders'] isn’t
> specified and the template engine's debug option is False (if not set,
> this option defaults to the value of DEBUG)
> }}}

New description:

It says about the cached template loader:


{{{
This loader is automatically enabled if DEBUG is False and
OPTIONS['loaders'] isn’t specified.
}}}


Actually, it's not based on DEBUG per se, but rather the template engine's
'debug' option, which is acknowledged correctly elsewhere in the docs.

So, I would correct that text to:


{{{
This loader is automatically enabled if OPTIONS['loaders'] isn’t specified

and the OPTIONS['debug'] is False (if not set, this option defaults to the
value of DEBUG)
}}}

--

--
Ticket URL: <https://code.djangoproject.com/ticket/29002#comment:1>

Django

unread,
Jan 9, 2018, 9:38:09 AM1/9/18
to django-...@googlegroups.com
#29002: Documentation about cached template loader is inaccurate about DEBUG
-------------------------------+------------------------------------

Reporter: oTree-org | Owner: nobody
Type: Bug | Status: new
Component: Documentation | Version: 2.0
Severity: Normal | Resolution:
Keywords: | Triage Stage: Accepted
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------+------------------------------------
Changes (by Tim Graham):

* has_patch: 0 => 1
* stage: Unreviewed => Accepted


Comment:

[https://github.com/django/django/pull/9558 PR]

--
Ticket URL: <https://code.djangoproject.com/ticket/29002#comment:2>

Django

unread,
Jan 11, 2018, 6:06:35 AM1/11/18
to django-...@googlegroups.com
#29002: Documentation about cached template loader is inaccurate about DEBUG
-------------------------------------+-------------------------------------

Reporter: oTree-org | Owner: nobody
Type: Bug | Status: new
Component: Documentation | Version: 2.0
Severity: Normal | Resolution:
Keywords: | Triage Stage: Ready for
| checkin
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by Carlton Gibson):

* stage: Accepted => Ready for checkin


--
Ticket URL: <https://code.djangoproject.com/ticket/29002#comment:3>

Django

unread,
Jan 11, 2018, 6:48:55 AM1/11/18
to django-...@googlegroups.com
#29002: Documentation about cached template loader is inaccurate about DEBUG
-------------------------------------+-------------------------------------
Reporter: oTree-org | Owner: nobody
Type: Bug | Status: closed
Component: Documentation | Version: 2.0
Severity: Normal | Resolution: fixed

Keywords: | Triage Stage: Ready for
| checkin
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------
Changes (by GitHub <noreply@…>):

* status: new => closed
* resolution: => fixed


Comment:

In [changeset:"7c00f9fb1cc47e1c993f7728e2b592a1be29dd40" 7c00f9f]:
{{{
#!CommitTicketReference repository=""
revision="7c00f9fb1cc47e1c993f7728e2b592a1be29dd40"
Fixed #29002 -- Corrected cached template loader docs about when it's
automatically enabled.

Thanks oTree-org for the suggestion.
}}}

--
Ticket URL: <https://code.djangoproject.com/ticket/29002#comment:4>

Django

unread,
Jan 11, 2018, 6:53:22 AM1/11/18
to django-...@googlegroups.com
#29002: Documentation about cached template loader is inaccurate about DEBUG
-------------------------------------+-------------------------------------
Reporter: oTree-org | Owner: nobody
Type: Bug | Status: closed
Component: Documentation | Version: 2.0

Severity: Normal | Resolution: fixed
Keywords: | Triage Stage: Ready for
| checkin
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------

Comment (by Tim Graham <timograham@…>):

In [changeset:"3d144787c9d80b868ecbef348049275493f5fc78" 3d144787]:
{{{
#!CommitTicketReference repository=""
revision="3d144787c9d80b868ecbef348049275493f5fc78"
[2.0.x] Fixed #29002 -- Corrected cached template loader docs about when
it's automatically enabled.

Thanks oTree-org for the suggestion.

Backport of 7c00f9fb1cc47e1c993f7728e2b592a1be29dd40 from master
}}}

--
Ticket URL: <https://code.djangoproject.com/ticket/29002#comment:5>

Django

unread,
Jan 11, 2018, 6:53:49 AM1/11/18
to django-...@googlegroups.com
#29002: Documentation about cached template loader is inaccurate about DEBUG
-------------------------------------+-------------------------------------
Reporter: oTree-org | Owner: nobody
Type: Bug | Status: closed
Component: Documentation | Version: 2.0

Severity: Normal | Resolution: fixed
Keywords: | Triage Stage: Ready for
| checkin
Has patch: 1 | Needs documentation: 0

Needs tests: 0 | Patch needs improvement: 0
Easy pickings: 0 | UI/UX: 0
-------------------------------------+-------------------------------------

Comment (by Tim Graham <timograham@…>):

In [changeset:"bb39e4b57e036765ea86ebb36913a54ec78b2b04" bb39e4b5]:
{{{
#!CommitTicketReference repository=""
revision="bb39e4b57e036765ea86ebb36913a54ec78b2b04"
[1.11.x] Fixed #29002 -- Corrected cached template loader docs about when
it's automatically enabled.

Thanks oTree-org for the suggestion.

Backport of 7c00f9fb1cc47e1c993f7728e2b592a1be29dd40 from master
}}}

--
Ticket URL: <https://code.djangoproject.com/ticket/29002#comment:6>

Reply all
Reply to author
Forward
0 new messages