From 70123cf084e3af7dfc61bb7bd2090ff802c3cda4 Mon Sep 17 00:00:00 2001 From: Preston Timmons Date: Mon, 2 Mar 2015 13:31:14 -0600 Subject: Fixed #24399 -- Made filesystem loaders use more specific exceptions. --- docs/releases/1.9.txt | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'docs') diff --git a/docs/releases/1.9.txt b/docs/releases/1.9.txt index 51bbc917d8..cc2273bd56 100644 --- a/docs/releases/1.9.txt +++ b/docs/releases/1.9.txt @@ -224,6 +224,19 @@ the keyword argument ``clear=True``. assignment for many-to-many relations and as a consequence now use the new behavior. +Filesystem-based template loaders catch more specific exceptions +~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ + +When using the :class:`filesystem.Loader ` +or :class:`app_directories.Loader ` +template loaders, earlier versions of Django raised a +:exc:`~django.template.TemplateDoesNotExist` error if a template source existed +but was unreadable. This could happen under many circumstances, such as if +Django didn't have permissions to open the file, or if the template source was +a directory. Now, Django only silences the exception if the template source +does not exist. All other situations result in the original ``IOError`` being +raised. + Miscellaneous ~~~~~~~~~~~~~ -- cgit v1.3