summaryrefslogtreecommitdiff
path: root/django/contrib/staticfiles/views.py
AgeCommit message (Collapse)Author
2024-01-26Applied Black's 2024 stable style.Mariusz Felisiak
https://github.com/psf/black/releases/tag/24.1.0
2022-02-07Refs #33476 -- Reformatted code with Black.django-bot
2019-05-13Refs #28593 -- Changed url() to path() in comments following URL routing ↵Tobias Bengfort
changes.
2017-03-17Fixed #27948 -- Removed incorrect unquote() in static serving views.Tim Graham
2017-01-18Refs #23919 -- Removed most of remaining six usageClaude Paroz
Thanks Tim Graham for the review.
2015-02-06Sorted imports with isort; refs #23860.Tim Graham
2014-08-12Fixed #23276 -- Deprecated passing views as strings to url().Tim Graham
2013-11-02More attacking E302 violatorsAlex Gaynor
2013-09-05Took advantage of django.utils.six.moves.urllib.*.Aymeric Augustin
2013-08-31Made django.test.testcases not depend on staticfiles contrib app.Ramiro Morales
Do this by introducing a django.contrib.staticfiles.testing.StaticLiveServerCase unittest TestCase subclass. Fixes #20739.
2013-07-31Fixed #20819 -- Return 404 instead of 500 error when ``staticfiles`` view is ↵Tai Lee
used in production.
2013-02-23Fixed embarrassing typo in last commit.Jannis Leidel
2013-02-23Removes document_root argument from django.contrib.staticfiles.views.servefako
This argument can be removed, because the new way of finding static files doesn't take document_root into account at all.
2013-01-29Fixed typos in docs and commentsTim Graham
2012-07-22[py3] Updated urllib/urllib2/urlparse imports.Aymeric Augustin
Lots of functions were moved. Use explicit imports in all cases to keey it easy to identify where the functions come from.
2011-07-04Fixed #15765 -- Stopped showing an odd error message when using the ↵Jannis Leidel
staticfiles enabled runserver management command and trying to serve files from STATIC_URL at the same time. git-svn-id: http://code.djangoproject.com/svn/django/trunk@16503 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-02-14Modified the staticfiles serve view to return a 404 early in the stack.Jannis Leidel
git-svn-id: http://code.djangoproject.com/svn/django/trunk@15539 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-02-14Fixes #15270 -- Moved back the serve view to django.views.static due to ↵Jannis Leidel
dependency conflicts with the contrib app staticfiles (reverts parts of r14293). Added a helper function that generates URL patterns for serving static and media files during development. Thanks to Carl for reviewing the patch. git-svn-id: http://code.djangoproject.com/svn/django/trunk@15530 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-12-31Fixed #14961 -- Revised staticfiles's prefix handling to make sure it runs ↵Jannis Leidel
on Windows. Also revised staticfiles tests to pass on Windows. git-svn-id: http://code.djangoproject.com/svn/django/trunk@15119 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-11-30Fixed #14812 -- Made parsing of the If-Modified-Since HTTP header more ↵Ramiro Morales
robust in presence of malformed values when serving static content. Thanks shaohua for the report, and alexey.smolsky@gmail.com for a similar report and patch. git-svn-id: http://code.djangoproject.com/svn/django/trunk@14753 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-11-11Fixed #14524, #14582, #14617, #14665 and #14667 -- Tweaked staticfiles app.Jannis Leidel
* Updated StaticFilesHandler and AdminMediaHandler to make use of the 404 handler if needed. * Updated runserver management command to serve static files only in DEBUG mode (or if specified the --insecure option) and if the staticfiles app is in INSTALLED_APPS. Also added an option to disable serving completely (--nostatic). * Added check in debug mode if STATICFILES_* settings are different to MEDIA_* settings. * Removed a faulty PendingDeprecationWarning in AdminMediaHandler that is triggered every time runserver is used. * Fixed an issue with the modification time checks when running collectstatic. * Extended and refined documentation. Thanks to everyone for input, especially to Carl Meyer, Ted Kaemming and Adam Vandenberg for patches. git-svn-id: http://code.djangoproject.com/svn/django/trunk@14533 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-10-21Fixed #14507 -- Corrected the logic of the URL helpers and view of ↵Jannis Leidel
staticfiles to actual work like documented (only when settings.DEBUG is True). Thanks for the report and initial patch, mbi. git-svn-id: http://code.djangoproject.com/svn/django/trunk@14306 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-10-20Fixed #12323 and #11582 -- Extended the ability to handle static files. ↵Jannis Leidel
Thanks to all for helping with the original app, the patch, documentation and general support. git-svn-id: http://code.djangoproject.com/svn/django/trunk@14293 bcc190cf-cafb-0310-a4f2-bffc1f526a37