Commit Graph

296 Commits

Author SHA1 Message Date
Gary Wilson Jr d0032458a2 Fixed #6679 -- In `decorator_from_middleware`, don't unpack arguments when calling a middleware's
`process_view` method, thanks Gulopine.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@7269 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-03-17 17:47:34 +00:00
Gary Wilson Jr dcdd9b3c63 Removed unused import, corrected a typo, and made some styling fixes.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@7206 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-03-08 03:55:47 +00:00
Malcolm Tredinnick efed04b634 Fixed #5603 -- Allow customization of the language cookie name. Thanks, moe.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@7185 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-02-29 18:38:44 +00:00
Malcolm Tredinnick 2dbb08e5dc Fixed #5846 -- Bullet-proofed the default timezone encoding test.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@7184 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-02-29 17:13:20 +00:00
Gary Wilson Jr 5ca0b9203b Fixed #5701 -- Fixed decorators to take the name, 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
2008-02-25 06:02:35 +00:00
Malcolm Tredinnick 54546f23f0 Fixed #6627 -- Made dict.clear() work for SortedDicts.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@7140 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-02-21 21:27:44 +00:00
Malcolm Tredinnick e7b2ad8020 Fixed #6611 -- When copying a SortedDict, make a new copy of the keys list.
Thanks, Jeremy Dunck.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@7129 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-02-18 23:08:51 +00:00
Adrian Holovaty 8b3f36029f Made a bunch of small doc rewordings from changes over the past couple of weeks
git-svn-id: http://code.djangoproject.com/svn/django/trunk@7122 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-02-16 05:15:09 +00:00
Malcolm Tredinnick 0a3c8f03e0 Fixed #6409 -- Unbreak compound locale name parsing (e.g. zh-cn).
This was inadvertently broken back in [6608]. Slightly backwards-incompatible:
people specifying "es_AR" in their LANGUAGES list will need to change that to
"es-ar". Thanks, simonb and Ramiro Morales for making the effort to fix this.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@7091 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-02-06 01:04:30 +00:00
Malcolm Tredinnick 0c4ea9b922 Fixed #6279, #6514 -- Fixed some HTML escaping problems in the urlize filter.
Based on a patch from SmileyChris with some test additions from Rob Hudson.
Thanks, both.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@7079 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-02-03 08:54:26 +00:00
Malcolm Tredinnick 8926a10fea Fixed #6303 -- Handle missing language specification in feed generation. Thanks, david.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@7066 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-02-03 03:23:10 +00:00
Malcolm Tredinnick 8b29767f3f Fixed #6301 -- Added '*' to the characters not converted by iri_to_uri(), as
pointed out by samidh.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@7064 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-02-03 02:21:51 +00:00
Malcolm Tredinnick 2542b94fb2 Fixed #6465 -- Tweaked MergeDict.getlist() to work with Django's MultiValueDict class. Thanks, Matt McClanahan.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@7062 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2008-02-03 02:02:41 +00:00
Gary Wilson Jr a944613b3a Minor style fixes.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6911 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-12-11 05:49:11 +00:00
Adrian Holovaty 72a5c03dee Removed comma splices in max_length DeprecationWarning and elsewhere in the module
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6872 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-12-04 05:56:30 +00:00
Malcolm Tredinnick bd400a368d Fixed #5657 -- Use string.ascii_letters instead of ascii.letters in the urlize
filter to ensure consistent (and correct) results no matter what the server's
locale setting might be. Thanks, Andrew Stoneman.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@6856 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-12-03 00:41:42 +00:00
Malcolm Tredinnick 2e62b84acc Fixed #6071 -- Fixed another infinite recursion problem in SafeString and
SafeUnicode. Thanks, Trey Long.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@6845 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-12-02 20:17:10 +00:00
Gary Wilson Jr 1921554b2b Changed use of `maxlength` to issue a `DeprecationWarning` instead of `PendingDeprecationWarning`, refs #2101.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6825 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-12-02 01:47:42 +00:00
Malcolm Tredinnick b2dbbd5bbc Fixed #6021 -- Removed some brain damage from SafeString. Not quite sure what I
was smoking there. Thanks, Jan Rademaker.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@6807 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-12-01 20:08:45 +00:00
Adrian Holovaty c5a4541f10 Edited docstring changes from [6714]
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6800 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-12-01 19:22:05 +00:00
Malcolm Tredinnick caa0523cb8 Fixed #6050 -- Handled edge-case of duplicate keys being passed when
initialising SortedDict. Patch from Collin Grady and SmileyChris.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@6751 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-29 20:09:54 +00:00
Malcolm Tredinnick f3c15225fc Fixed #6023 -- Fixed daylight savings determination for years beyond 2038 on
32-bit systems (modulo the fact that the system timezone libraries might not be
accurate that far out; at least we don't crash now). Thanks, SmileyChris.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@6749 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-29 19:39:46 +00:00
Malcolm Tredinnick f2f6e70b08 Fixed #5813 -- Taught the CacheMiddleware to respect any max-age HTTP header
when setting the expiry time. Thanks, SmileyChris.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@6736 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-29 16:57:18 +00:00
Gary Wilson Jr c7181ec0ff Made `MultiValueDict`'s `get` and `getlist` method docstrings more descriptive.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6714 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-25 18:14:18 +00:00
Gary Wilson Jr 891cc5df92 Minor styling fix in `DotExpandedDict.__init__`.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6713 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-25 18:11:44 +00:00
Gary Wilson Jr 303d22b0d2 Changed several hardcoding of `dict` method calls in `django.utils.datastructures.py` to use `super` instead.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6712 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-25 18:10:45 +00:00
Gary Wilson Jr 8df3d2b467 In `MergeDict` class, changed variable names to not clash with `dict` builtin.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6711 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-25 18:07:57 +00:00
Gary Wilson Jr 1607acee40 Fixed #5978 -- Gave `LOCALE_PATHS` a default setting of an empty tuple and removed some code that was checking for its existance in settings before accessing it.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6701 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-19 05:59:58 +00:00
Gary Wilson Jr 66576c285a Some minor changes to the `patch_vary_headers` function:
* Replaced a for loop with a list comprehension.
 * Used a set instead of a dict with dummy values.
 * Used a bit more readable variable names.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@6698 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-19 04:00:41 +00:00
Gary Wilson Jr 34cc21983c Removed `vary_delim_re` in `django/utils/cache.py` in favor of existing `cc_delim_re` since the latter is more correct in parsing the header (allows whitespace before and after comma separators instead of just after). As a bonus, tests added for `patch_vary_headers()`.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6696 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-19 03:12:19 +00:00
Malcolm Tredinnick ce73298e26 Fixed #5960 -- Fixed some Python 2.3 incompatibilities.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6685 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-17 12:58:06 +00:00
Malcolm Tredinnick 4585b4d6c2 Fixed some missed auto-escaping and URL quoting cases in the urlize filter.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6683 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-17 12:12:40 +00:00
Malcolm Tredinnick 64c0bf8677 Translating safe strings should return a safe result.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6681 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-17 12:11:54 +00:00
Malcolm Tredinnick 356662cf74 Implemented auto-escaping of variable output in templates. Fully controllable by template authors and it's possible to write filters and templates that simulataneously work in both auto-escaped and non-auto-escaped environments if you need to. Fixed #2359
See documentation in templates.txt and templates_python.txt for how everything
works.

Backwards incompatible if you're inserting raw HTML output via template variables.

Based on an original design from Simon Willison and with debugging help from Michael Radziej.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@6671 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-14 12:58:53 +00:00
Gary Wilson Jr 5e8be6978e Simplified `SortedDict.__deepcopy__` now that the its constructor can take a sequence of tuples.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6669 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-12 03:12:47 +00:00
Malcolm Tredinnick 3f1ce2e602 Fixed #5640 -- Added some extra error reporting when smart_unicode() or
force_unicode() raise a UnicodeDecodeError. This should at least help people
identify which is the bad piece of data they passed in. About the best we can
do here.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@6649 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-04 03:37:04 +00:00
Gary Wilson Jr 0e59bf42cf Fixed #5869 -- Corrected documentation for `now` template tag's "r" format character. Thanks, xavier.morel@masklinn.net.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6640 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-11-04 01:14:58 +00:00
Gary Wilson Jr 8c442f21dc Fixed #5816 -- Fixed a regression from [6333] that generates incorrect cookie "expires" dates when using a locale other than English. Introduced `http_date` and `cookie_date` utility functions. Thanks for the report Michael Lemaire. Thanks for the patch Karen Tracey and `SmileyChris`.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6634 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-10-31 03:59:40 +00:00
Gary Wilson Jr d453eda388 Corrected a typo and made some style fixes.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6626 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-10-28 22:32:25 +00:00
Jacob Kaplan-Moss 842a771e05 i18n security fix. Details will be posted shortly to the Django mailing lists and the official weblog.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6608 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-10-26 19:52:42 +00:00
Malcolm Tredinnick dbd1cb9083 Fixed #5183 -- Added __deepcopy__, pop() and popitem() to SortedDict. Based on
a patch from David Blewett.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@6593 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-10-22 00:52:54 +00:00
Malcolm Tredinnick bab4fdc9fd Fixed #5560 -- Improved the way we create __str__ and __unicode__ methods in
lazy() objects. This fixes things for Jython and makes the code more readable,
even for CPython. Thanks, Leo Soto.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@6587 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-10-21 18:35:31 +00:00
Malcolm Tredinnick 7ca708140a Fixed #2920 -- Removed _() from builtins.
This is backwards incompatible, but easy to work around.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@6582 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-10-21 17:14:25 +00:00
Malcolm Tredinnick 8a3cf46e60 Fixed #3502 -- Added TTL support for RSS (not Atom) feeds. Patch from
jason.sidabras@gmail.com and Thomas Kerpe.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@6570 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-10-20 14:54:38 +00:00
Malcolm Tredinnick 18e1f56a41 Fixed #5475 -- Added the Luhn check algorithm to django.utils.checksums so that
localflavors don't have to reimplement it each time. Thanks, __hawkeye__.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@6569 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-10-20 13:40:20 +00:00
Malcolm Tredinnick b7687fae2d Added datetime.date to the things ignored by strings_only in [6406].
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6567 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-10-20 13:01:09 +00:00
Malcolm Tredinnick bece031772 Fixed #5734 -- Fixed an omission where we weren't passing the "safe" argument
upstream in django.utils.http.urlquote(). Thanks, Thomas Güttler.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@6554 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-10-20 08:38:59 +00:00
Gary Wilson Jr 088cb3c2f3 Django coding style fixes.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6528 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-10-19 01:26:09 +00:00
Gary Wilson Jr 78d557bf02 Fixed #5744 -- Allowed SortedDict contructor to be passed a list of tuples to match the interface of dict, thanks Thomas Güttler.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6506 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-10-14 04:17:02 +00:00
Malcolm Tredinnick 2a63414ccd Fixed #5674 -- Fixed a typo in a docstring from [6446]. Thanks, ski.whitespace@gmail.com.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6448 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-10-03 22:12:22 +00:00
Malcolm Tredinnick fa546d797e Fixed #4796. Fixed a problem when using i18n support for the first time -- in
particular when string_concat() was the first call made. Thanks, Andy Durdin.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@6446 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-10-03 01:57:02 +00:00
Jacob Kaplan-Moss 964f0c16ad Fixed #5557: URLs are now properly escaped in the cache_page decorator. Thanks, eriks.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6435 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-09-28 22:34:27 +00:00
Jacob Kaplan-Moss 2dd882885b Fixed #5047: patch_cache_control now respects existing max-age settings. Thanks, permon.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6434 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-09-28 22:30:59 +00:00
Russell Keith-Magee f2101abacf Fixed #5553 -- Fixed a serialization problem with datetime and time objects. Thanks to pigletto for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6406 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-09-22 13:21:54 +00:00
Adrian Holovaty 4704412bb3 Fixed #5540 -- Made __repr__() for MultiValueDict more generic. Thanks, Thomas Guttler
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6383 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-09-20 01:56:02 +00:00
Gary Wilson Jr 2e75529990 Removed unused import.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6368 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-09-17 04:54:53 +00:00
Gary Wilson Jr 66203fc9ee Fixed #2675 -- Changed the `timeuntil` and `timesince` template filters to display "0 minutes" when passed a past or future date respectively instead of "-1 years, 12 months". Thanks to nickefford for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6366 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-09-17 04:50:12 +00:00
Malcolm Tredinnick 68884a571f Fixed #2633 -- Fixed timezone computation in O() format function, using fix from [6300].
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6358 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-09-16 11:59:56 +00:00
Malcolm Tredinnick ec7d80b9dd Fixed #3993 -- Added some useful dictionary methods to SortedDict, plus an insert() method. Patch from Paul Collier.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6350 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-09-16 03:27:38 +00:00
Malcolm Tredinnick 09060e9bc8 Made a small optimization to __deepcopy__ in [6276].
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6279 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-09-15 11:13:21 +00:00
Malcolm Tredinnick 39814eeb54 Fixed #5487 -- Added deepcopying ability to lazy() objects, along with a test to demonstrate why the previous code failed. Debugging and patch from John Buchanan.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6276 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-09-15 10:57:03 +00:00
Malcolm Tredinnick b984505d13 Fixed #5470 -- Fixed the 'Z' time format marker in templates to handle timezones west of UTC. Thanks, Paul Lanier.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6275 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-09-15 10:36:14 +00:00
Russell Keith-Magee 84e824fbbf Fixed #3036 -- Fixed some doctest strings that were failing. Thanks to pterk for the original patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6268 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-09-15 08:29:56 +00:00
Malcolm Tredinnick 671a8359e8 Fixed a small bug in strings_only handling for force_unicode().
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6267 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-09-15 08:05:32 +00:00
Adrian Holovaty 604504896c Fixed #3088 -- Filter parameters are now translated in blocktrans. Thanks, permon
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6263 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-09-15 05:14:16 +00:00
Jacob Kaplan-Moss eb11615baa Fixed number #4076: django.utils.feedgenerator now corectly handles times without timezones. Thanks, Alastair Tse.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6233 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-09-14 22:29:37 +00:00
Adrian Holovaty b522469322 Fixed #4071 -- Fixed bug in cache_page decorator, which was setting the wrong header. Thanks, Ionut Ciocirlan (xlotlu) and permon
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6222 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-09-14 21:42:26 +00:00
Jacob Kaplan-Moss ad077ccbc0 Fixed #5445: added some compatibility code for the lack of __iter__ in Jython 2.2. Thanks, Leo Soto.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6211 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-09-14 19:55:24 +00:00
Russell Keith-Magee 50497e3867 Refs #5138 -- Refactored implementation of __contains__ in HttpRequest introduced in [6097] after a suggestion from Malcolm. Applied a similar refactor for MergeDict and Context which had comparable behavior.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@6098 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-09-11 14:04:40 +00:00
Adrian Holovaty 4652c96de1 Fixed #5237 -- Added an optional 'path' argument to get_svn_revision(). Thanks, django@poelzi.org
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5995 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-08-24 03:53:04 +00:00
Adrian Holovaty a1e26b0105 Fixed #5215 -- Added Subversion revision number to Django version string. Thanks for the patch, Deryck Hodge
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5990 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-08-21 03:08:02 +00:00
Malcolm Tredinnick ce151bb8e4 Fixed #5156 -- Added some translation calls to a couple of missed words. Based on a patch from dAniel hAhler.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5895 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-08-15 12:09:32 +00:00
Malcolm Tredinnick f6e86c4286 Fixed #5111 -- Set svn:eol-style to 'native' on files that didn't have it
already.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@5876 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-08-12 12:49:01 +00:00
Malcolm Tredinnick 3757f30c99 Fixed #4947 -- Avoid displaying uploaded file contents in the debug web page. Based on a patch from eibaan@gmail.com.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5874 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-08-12 12:02:08 +00:00
Adrian Holovaty 56a75a2a4e Fixed #5077 -- django/utils/encoding.py no longer imports settings, as it doesn't use that module. Thanks, Collin Grady
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5810 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-08-06 05:06:15 +00:00
Gary Wilson Jr 212ee65be7 Fixed #2101 -- Renamed `maxlength` argument to `max_length` for oldforms `FormField`s and db model `Field`s. This is fully backwards compatible at the moment since the legacy `maxlength` argument is still supported. Using `maxlength` will, however, issue a `PendingDeprecationWarning` when used.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5803 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-08-05 05:14:46 +00:00
Adrian Holovaty b263e1704c Changed safe_join() docstring from [5750] to use active verbs. See also [5756]
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5758 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-07-25 03:18:17 +00:00
Gary Wilson Jr 304381616f Fixed #4952 -- Fixed the `get_template_sources` functions of the `app_directories` and `filesystem` template loaders to not return paths outside of given template directories. Both functions now make use of a new `safe_join` utility function. Thanks to SmileyChris for help with the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5750 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-07-23 04:45:01 +00:00
Russell Keith-Magee f2303b6f7a Fixed #4402 -- Modified test client to allow multi-valued inputs on GET requests. Thanks for the suggestion, eddymul@gmail.com.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5741 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-07-21 05:17:20 +00:00
Gary Wilson Jr 7aac81d280 Cleaned up a couple unused imports and fixed docstrings to follow Python Style Guide.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5717 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-07-16 05:28:13 +00:00
Malcolm Tredinnick 5dd9a2ab38 Fixed #4199 -- Changed date formatting in HTTP expires header to be spec
compliant. Thanks, Chris Bennett.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@5712 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-07-16 03:50:22 +00:00
Gary Wilson Jr b68f188628 Fixed #4310 -- Fixed a regular expression bug in `strip_entities` function and added tests for several `django.utils.html` functions. Based on patch from Brian Harring.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5701 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-07-15 05:03:28 +00:00
Russell Keith-Magee 34655a3e78 Fixed #4768 -- Converted timesince and dateformat to use explicit floor division (pre-emptive avoidance of Python 3000 compatibility problem), and removed a redundant millisecond check. Thanks, John Shaffer <jshaffer2112@gmail.com>.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5671 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-07-12 13:55:19 +00:00
Malcolm Tredinnick 86640f33c1 Fixed #3760 -- Added the ability to manually set feed- and item-level id
elements in Atom feeds. This is fully backwards compatible. Based on a patch
from spark343@cs.ubc.ca.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@5643 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-07-10 12:33:55 +00:00
Malcolm Tredinnick b6812f2d9d Fixed reverse URL lookup using functions when the original URL pattern was a
string. This is now just as fragile as it was prior to [5609], but works in a
few cases that people were relying on, apparently.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@5632 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-07-08 00:39:32 +00:00
Malcolm Tredinnick 4c011e6f36 Corrected misleading comment from [5619]. Not sure what I was smoking at the
time.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@5631 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-07-07 18:39:23 +00:00
Malcolm Tredinnick 05de381512 Fixed #1015 -- Fixed decorator_from_middleware to return a real decorator even
when arguments are given. This looks a bit ugly, but it's fully backwards
compatible and all the extra work is done at import time, so it shouldn't have
any real performance impact.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@5619 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-07-05 11:10:27 +00:00
Malcolm Tredinnick 953badbea5 Merged Unicode branch into trunk (r4952:5608). This should be fully
backwards compatible for all practical purposes.

Fixed #2391, #2489, #2996, #3322, #3344, #3370, #3406, #3432, #3454, #3492, #3582, #3690, #3878, #3891, #3937, #4039, #4141, #4227, #4286, #4291, #4300, #4452, #4702


git-svn-id: http://code.djangoproject.com/svn/django/trunk@5609 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-07-04 12:11:04 +00:00
Malcolm Tredinnick a56a8dacf3 Fixed small bug in Python 2.3 fallback for itertools.groupby. Refs #4506.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5526 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-06-24 12:38:11 +00:00
Malcolm Tredinnick fc20eeec47 Fixed a Python 2.3 incompatibility I overlooked in [5516].
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5517 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-06-23 06:02:17 +00:00
Malcolm Tredinnick 5f5f1d913b Fixed #4566 -- Added caching speed-ups to reverse URL matching. Based on a
patch from smoo.master@gmail.com.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@5516 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-06-23 05:40:28 +00:00
Malcolm Tredinnick 284c6ba44b Fixed #4657 -- Fixed an error in an edge case of the urlizetrunc filter.
Thanks, SmileyChris.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@5513 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-06-23 03:10:32 +00:00
Malcolm Tredinnick 2a34fbe043 Fixed #4506 -- Changed "regroup" template tag to use __eq__ instead of repr()
for grouping equality checking. Thanks, Brian Harring.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@5484 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-06-17 07:33:18 +00:00
Malcolm Tredinnick 12771614db Fixed #4323 -- Added the ability to display author names without email
addresses to RSS 2.0 feeds.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@5357 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-05-26 10:36:36 +00:00
Malcolm Tredinnick 92c35a0617 Fixed #2365, #3324 -- Renamed FloatField to DecimalField and changed the code
to return Decimal instances in Python for this field. Backwards incompatible
change.

Added a real FloatField (stores floats in the database) and support for
FloatField and DecimalField in newforms (analogous to IntegerField).

Included decimal.py module (as django.utils._decimal) from Python 2.4. This is
license compatible with Django and included for Python 2.3 compatibility only.

Large portions of this work are based on patches from Andy Durdin and Jorge
Gajon.



git-svn-id: http://code.djangoproject.com/svn/django/trunk@5302 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-05-21 01:29:58 +00:00
Malcolm Tredinnick 439cb4047f Fixed #4040 -- Changed uses of has_key() to "in". Slight performance
improvement and forward-compatible with future Python releases. Patch from Gary
Wilson.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@5091 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-04-26 13:30:48 +00:00
Malcolm Tredinnick d744a660c4 Fixed #4137 -- Added translation markup to a couple of missed strings. Thanks,
Sung-Jin Hong.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@5071 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-04-25 08:32:31 +00:00
Malcolm Tredinnick aca569804e Fixed #3964 -- Added a custom SortedDict.__repr__ so that the keys are printed
in sorted order. Based on a patch from Forest Bond.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@5069 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-04-25 07:30:54 +00:00
Malcolm Tredinnick 535535a45e Removed a bunch of annoying trailing whitespace.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5068 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-04-25 07:25:22 +00:00
Adrian Holovaty 254e087e31 Fixed #4106 -- Fixed typo in datastructures.py. Thanks, Amr Mostafa
git-svn-id: http://code.djangoproject.com/svn/django/trunk@5060 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2007-04-23 01:55:45 +00:00