Arthur de Jong

Open Source / Free Software developer

summaryrefslogtreecommitdiffstats
path: root/django/views/decorators/http.py
Commit message (Collapse)AuthorAgeFilesLines
* Fixed #24935 -- Refactored common conditional GET handling.Denis Cornehl2015-08-151-68/+8
|
* Fixed typos in HTTP decorator docs.I am Clinton2015-05-251-3/+3
|
* Sorted imports with isort; refs #23860.Tim Graham2015-02-061-3/+7
|
* Fixed #22461 -- Added if-unmodified-since support to the ↵Thomas Tanner2014-12-241-29/+35
| | | | condition decorator.
* Fixed #23695 -- Made condition decorator work for HEAD ↵Anton Novosyolov2014-10-211-1/+1
| | | | requests without ETag.
* Correct flake8 E302 violationsRay Ashman Jr2013-11-031-0/+3
|
* Whitespace cleanup.Tim Graham2013-10-101-1/+0
| | | | | | | * Removed trailing whitespace. * Added newline to EOF if missing. * Removed blank lines at EOF. * Removed some stray tabs.
* Imported getLogger directly from logging moduleClaude Paroz2012-09-201-2/+2
| | | | This was a remainder of some 2.4 compatibility code.
* Fixed #17358 -- Updated logging calls to use official ↵Jannis Leidel2012-02-091-3/+3
| | | | | | syntax for arguments instead of string interpolation. Thanks, spulec. git-svn-id: http://code.djangoproject.com/svn/django/trunk@17480 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #15840 -- Wrapped inner function of the condition ↵Jannis Leidel2012-02-091-0/+1
| | | | | | decorator with functools.wraps to follow best practices. Thanks, zsiciarz. git-svn-id: http://code.djangoproject.com/svn/django/trunk@17470 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #16225 -- Removed unused imports. Many thanks to ↵Jannis Leidel2011-07-131-1/+0
| | | | | | Aymeric Augustin for the work on the patch and Alex for reviewing. git-svn-id: http://code.djangoproject.com/svn/django/trunk@16539 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Replaced old-style with new-style decorator syntax.Jannis Leidel2011-05-011-1/+2
| | | | git-svn-id: http://code.djangoproject.com/svn/django/trunk@16138 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #15637 -- Added a require_safe decorator for views ↵Jannis Leidel2011-04-281-0/+3
| | | | | | to accept GET or HEAD. Thanks, aaugustin and Julien. git-svn-id: http://code.djangoproject.com/svn/django/trunk@16115 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Removed a bunch more Python 2.4 workarounds now that we ↵Adrian Holovaty2011-03-281-5/+1
| | | | | | don't support that version. Refs #15702 -- thanks to jonash for the patch. git-svn-id: http://code.djangoproject.com/svn/django/trunk@15927 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #717 - If-Modified-Since handling should compare ↵Luke Plant2011-03-011-8/+10
| | | | | | | | | dates according to RFC 2616 Thanks to Maniac for the report, julienb for the initial patch, and especially to aaugustin for the final patch and tests. git-svn-id: http://code.djangoproject.com/svn/django/trunk@15696 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #14406 -- Added a Python 2.4 compatibility to the ↵Russell Keith-Magee2010-10-061-2/+2
| | | | | | logging interface. Thanks to Łukasz Rekucki for the report, and to Luke Plant for original patch this was based on. git-svn-id: http://code.djangoproject.com/svn/django/trunk@13989 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #12012 -- Added support for logging. Thanks to ↵Russell Keith-Magee2010-10-041-1/+22
| | | | | | Vinay Sajip for his draft patch, and to the many people who gave feedback during development of the patch. git-svn-id: http://code.djangoproject.com/svn/django/trunk@13981 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #12164 -- Removed the Python 2.3 compatibility ↵Russell Keith-Magee2010-05-041-1/+1
| | | | | | imports and workarounds. Thanks to timo and claudep for the patch. git-svn-id: http://code.djangoproject.com/svn/django/trunk@13094 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #13093 -- Updated some decorators and the ↵Russell Keith-Magee2010-03-121-2/+2
| | | | | | decorator_from_middleware function to allow callable classes to be decorated. Thanks to Brian Neal for the report. git-svn-id: http://code.djangoproject.com/svn/django/trunk@12762 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #10681 -- Work around (by ignoring) invalid ETag ↵Malcolm Tredinnick2009-04-031-1/+9
| | | | | | | | | | | | headers. This is a hack to work around problems in the Real World. Apparently, Opera 9.64 has been observed sending malformed headers. We now compromise our high principles and simply ignore such bad behaviour. Patch from Ivan Sagalaev. git-svn-id: http://code.djangoproject.com/svn/django/trunk@10370 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* A bunch of improvements for conditional HTTP processing.Malcolm Tredinnick2009-03-241-4/+4
| | | | | | | | Fixed some typos in the code (fixed #10586). Added more tests. Made the tests compatible with Python 2.3. Improved the documentation by putting the good news and common use-case right up front. git-svn-id: http://code.djangoproject.com/svn/django/trunk@10134 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #10581 -- Fixed conditional handling of If-Match ↵Malcolm Tredinnick2009-03-231-1/+1
| | | | | | | | | | | headers. The conditional processing decorator from r10114 wasn't parsing ETags from an If-Match header correctly. Patch from Ivan Sagalaev (who also did most of the work in r10114, before I rewrote parts of it and added bonus bugs, although I forgot to thank him there). git-svn-id: http://code.djangoproject.com/svn/django/trunk@10116 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #5791 -- Added early-bailout support for views ↵Malcolm Tredinnick2009-03-221-2/+98
| | | | | | | | | | | | | | (ETags and Last-modified). This provides support for views that can have their ETag and/or Last-modified values computed much more quickly than the view itself. Supports all HTTP verbs (not just GET). Documentation and tests need a little more fleshing out (I'm not happy with the documentation at the moment, since it's a bit backwards), but the functionality is correct. git-svn-id: http://code.djangoproject.com/svn/django/trunk@10114 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #5701 -- Fixed decorators to take the name, ↵Gary Wilson Jr2008-02-251-1/+6
| | | | | | attributes, and docstring of the function they decorate by adding a modified version of the `functools.wraps` function from Python 2.5. `wraps` has been altered to work with Django's `curry` function and with Python 2.3, which doesn't allow assignment of a function's `__name__` attribute. This fixes severaly annoyances, such as the online documentation for template filters served by the admin app. This change is backwards incompatible if, for some reason, you were relying on the name of a Django decorator instead of the function it decorates. git-svn-id: http://code.djangoproject.com/svn/django/trunk@7153 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Converted request.META['REQUEST_METHOD'] calls to ↵Adrian Holovaty2006-06-201-3/+2
| | | | | | request.method, throughout the Django codebase git-svn-id: http://code.djangoproject.com/svn/django/trunk@3171 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #2185 -- Changed ↵Adrian Holovaty2006-06-201-6/+6
| | | | | | django.views.decorators.http.require_http_methods decorator to use HttpResponseNotAllowed instead of HttpResponseForbidden git-svn-id: http://code.djangoproject.com/svn/django/trunk@3163 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* MERGED MAGIC-REMOVAL BRANCH TO TRUNK. This change is ↵Adrian Holovaty2006-05-021-1/+1
| | | | | | highly backwards-incompatible. Please read http://code.djangoproject.com/wiki/RemovingTheMagic for upgrade instructions. git-svn-id: http://code.djangoproject.com/svn/django/trunk@2809 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #703: added decorators to require that view be ↵Jacob Kaplan-Moss2005-10-281-2/+28
| | | | | | called with a given HTTP REQUEST_METHOD git-svn-id: http://code.djangoproject.com/svn/django/trunk@1016 bcc190cf-cafb-0310-a4f2-bffc1f526a37
* Fixed #580 -- Added mega support for generating Vary ↵Adrian Holovaty2005-10-091-0/+9
headers, including some view decorators, and changed the CacheMiddleware to account for the Vary header. Also added GZipMiddleware and ConditionalGetMiddleware, which are no longer handled by CacheMiddleware itself. Also updated the cache.txt and middleware.txt docs. Thanks to Hugo and Sune for the excellent patches git-svn-id: http://code.djangoproject.com/svn/django/trunk@810 bcc190cf-cafb-0310-a4f2-bffc1f526a37