Commit Graph

20 Commits

Author SHA1 Message Date
Bouke Haarsma 9b7455e918 Fixed #21351 -- Replaced memoize with Python's lru_cache.
Replaced the custom, untested memoize with a similar decorator from Python's
3.2 stdlib. Although some minor performance degradation (see ticket), it is
expected that in the long run lru_cache will outperform memoize once it is
implemented in C.

Thanks to EvilDMP for the report and Baptiste Mispelon for the idea of
replacing memoize with lru_cache.
2013-11-11 08:53:09 +01:00
Gregor MacGregor b2b763448f Fixed #20841 -- Added messages to NotImplementedErrors
Thanks joseph at vertstudios.com for the suggestion.
2013-09-10 11:09:59 -04:00
Curtis Maloney 07876cf02b Deprecated SortedDict (replaced with collections.OrderedDict)
Thanks Loic Bistuer for the review.
2013-08-04 07:09:39 -04:00
Ramiro Morales 0fa8d43e74 Replaced `and...or...` constructs with PEP 308 conditional expressions. 2013-05-26 23:47:50 -03:00
Claude Paroz 7c5b244826 Fixed #17061 -- Factored out importing object from a dotted path
Thanks Carl Meyer for the report.
2013-02-04 16:38:25 +01:00
Aymeric Augustin ee191715ea [py3] Fixed access to dict keys/values/items. 2012-08-07 12:00:22 +02:00
Claude Paroz 3904b74a3f Fixed #18013 -- Use the new 'as' syntax for exceptions.
Thanks Clueless for the initial patch.
Note that unittest has been purposely left out (external package only used by Python 2.6).
2012-04-29 20:57:15 +02:00
Jannis Leidel c4cc875643 Fixed #16703 -- Raise an exception if the storage location of the DefaultStorageFinder is empty.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16863 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-21 15:58:32 +00:00
Jannis Leidel 1d32bdd3c9 Fixed #15252 -- Added static template tag and CachedStaticFilesStorage to staticfiles contrib app.
Many thanks to Florian Apolloner and Jacob Kaplan-Moss for reviewing and eagle eyeing.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16594 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-08-11 14:07:39 +00:00
Chris Beaven c47b69ba53 Fix the docstring of contrib.staticfiles BaseFinder so it's not misleading.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@15771 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-03-07 22:54:55 +00:00
Jannis Leidel 3bff7ed34c Preserve order of STATICFILES_DIRS locations in FileSystemFinder.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@15389 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-02-01 20:10:29 +00:00
Carl Meyer 7aad3d3fa8 Fixed #15094 - Added check for forgetting trailing comma in STATICFILES_DIRS tuple. Also reorganized staticfiles settings-checks for better consistency.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@15386 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-02-01 14:57:10 +00:00
Carl Meyer 76fb2bb0e2 Fixed some documentation and default-settings.py comments that were misleading about the purpose of STATIC_ROOT, and removed an unused import.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@15384 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-02-01 14:28:07 +00:00
Jannis Leidel 9e81e18929 Uses a SortedDict for memoization of staticfiles finder instances to preserve order during tests.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@15371 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-01-30 17:23:36 +00:00
Jannis Leidel 645eb2b26b Stopped staticfiles app from requiring a models module when looking for static files. Also removed a bit of code smell in the prefix handling by saving it in the source file storage.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@15219 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-01-15 23:38:00 +00:00
Jannis Leidel 465833834c Fixed a few docstrings and other helper texts in the staticfiles app.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@15148 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-01-05 12:41:40 +00:00
Jannis Leidel e45d1e2dac Safely join paths in staticfiles finder.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@15127 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-01-02 01:31:55 +00:00
Jannis Leidel 0de63c96f2 Fixed #14961 -- Revised staticfiles's prefix handling to make sure it runs 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-12-31 14:22:32 +00:00
Jannis Leidel 58af951c30 Fixing a few cosmetic bugs. Thanks for the hint, Alex Gaynor.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@14307 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2010-10-21 03:16:58 +00:00
Jannis Leidel cfc19f84de Fixed #12323 and #11582 -- Extended the ability to handle static files. 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
2010-10-20 01:33:24 +00:00