#24235: Deprecate is_usable attribute on template loaders?
---------------------------------+--------------------
     Reporter:  prestontimmons   |      Owner:  nobody
         Type:  Uncategorized    |     Status:  new
    Component:  Template system  |    Version:  master
     Severity:  Normal           |   Keywords:
 Triage Stage:  Unreviewed       |  Has patch:  0
Easy pickings:  0                |      UI/UX:  0
---------------------------------+--------------------
 Each Django loaders has a boolean attribute of "is_usable". It seems the
 only use for this comes from the egg loader when setuptools isn't
 installed. If "is_usable" is false, a warning is raised in
 engine.find_template_loader, but otherwise the loader is silently ignored
 for template loading.

 It seems like that is the wrong behavior. I think the loaders should fail
 loudly if they're missing configuration. Otherwise, it's unclear why
 they're not used to find templates. I ran into this when writing a sample
 loader and forgetting to specify "is_usable" as True on it.

 Unless there's a use case for silently ignoring template loaders, I think
 we should deprecate this behavior.

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

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To post to this group, send email to django-updates@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/057.1d3799751eacd074b4ce1cbe3cf4ecf1%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to