summaryrefslogtreecommitdiff
path: root/django/utils
AgeCommit message (Collapse)Author
2014-03-21Removed reading of old 'django_language' session variable per deprecation ↵Tim Graham
timeline. refs #5789.
2014-03-21Removed fix_ampersands template filter per deprecation timeline.Tim Graham
Also removed related utility functions: * django.utils.html.fix_ampersands * django.utils.html.clean_html
2014-03-19Merge pull request #2221 from bmispelon/LazyObject-refactorAndrew Godwin
Fixed #21840 -- Moved dunder methods from SimpleLazyObject to LazyObject...
2014-03-18Fixed #22283 -- Updated documentation referring to non-existent tuples.Matthew Somerville
2014-03-13Simplified implementation of collectstatic command.Baptiste Mispelon
Since d2e242d16c6dde6f4736086fb38057424bed3edb made isinstance() calls work correctly on LazyObject, we can simplify the implementation of is_local_storage added in 7e27885c6e7588471fd94a4def16b7081577bdfc.
2014-03-13Fixed #21840 -- Moved dunder methods from SimpleLazyObject to LazyObject.Baptiste Mispelon
This commit also added tests for LazyObject and refactored the testsuite of SimpleLazyObject so that it can share test cases with LazyObject.
2014-03-08Avoided changing raw DeprecationWarning filter behaviorClaude Paroz
Refs #21188. Now pure Python DeprecationWarning visibility should be back to Python defaults.
2014-03-08Fixed #21188 -- Introduced subclasses for to-be-removed-in-django-XX warningsClaude Paroz
Thanks Anssi Kääriäinen for the idea and Simon Charette for the review.
2014-03-03Fixed many typos in comments and docstrings.Rodolfo Carvalho
Thanks Piotr Kasprzyk for help with the patch.
2014-03-01Fixed #22130 -- Deprecated fix_ampersands, removed utils.clean_html()Erik Romijn
2014-02-26Fixed #21389 -- Accept most valid language codesBouke Haarsma
By removing the 'supported' keyword from the detection methods and only relying on a cached settings.LANGUAGES, the speed of said methods has been improved; around 4x raw performance. This allows us to stop checking Python's incomplete list of locales, and rely on a less restrictive regular expression for accepting certain locales. HTTP Accept-Language is defined as being case-insensitive, based on this fact extra performance improvements have been made; it wouldn't make sense to check for case differences.
2014-02-22Extra new line to make flake8 happyAlex Gaynor
2014-02-22Fixed #22120 -- Documented persistent activation of languages and cleaned up ↵Erik Romijn
language session key use
2014-02-22Deprecated django.utils.text.javascript_quote.Baptiste Mispelon
Refs #21725.
2014-02-16Fixed #19980: Signer broken for binary keys (with non-ASCII chars).MattBlack85
With this pull request, request #878 should considered closed. Thanks to nvie for the patch.
2014-02-15Fixed #21725 -- Fixed JavaScript quoting encoding.MattBlack85
Thanks to nedbatchelder for the report.
2014-02-13Fixed #19496 -- Added truncatechars_html filter.Jeremy
Thanks esevece for the suggestion and Nick Sandford and Martin Warne for the inital work on the patch.
2014-02-12Fixed #22017 -- Prevented RuntimeError on Python 3Claude Paroz
Refs #21049. Thanks quinox for the report.
2014-02-09Fixed #21482 -- Uplifted restriction of collectstatic using symlink option ↵Jannis Leidel
in Windows NT 6. Original patch by Vajrasky Kok. Reviewed by Florian Apolloner, Aymeric Augustin.
2014-02-09Fixed #21247 -- Made method_decorator play nicely with descriptorsMarc Tamlyn
When a method decorator was used in conjunction with a decorator implemented as a descriptor, method_decorator did not correctly respect the method binding. Thanks for Graham Dumpleton for the report and initial patch.
2014-02-09Merge pull request #1997 from dpwrussell/method_decorator_args_fixMarc Tamlyn
Used available_attrs in method_decorator
2014-02-08Fixed #21674 -- Deprecated the import_by_path() function in favor of ↵Berker Peksag
import_string(). Thanks Aymeric Augustin for the suggestion and review.
2014-02-06Fixed #21731 -- Made javascript_quote escapes '</'.Vajrasky Kok
2014-02-05Revert "Fixed #20296 -- Allowed SafeData and EscapeData to be lazy"Baptiste Mispelon
This reverts commit 2ee447fb5f8974b432d3dd421af9a242215aea44. That commit introduced a regression (#21882) and didn't really do what it was supposed to: while it did delay the evaluation of lazy objects passed to mark_safe(), they weren't actually marked as such so they could end up being escaped twice. Refs #21882.
2014-01-26Fixed #21823 -- Upgraded six to 1.5.2Tim Graham
2014-01-26Fixed #21880 -- Added missing items to django.utils.timezone.__all__.Aymeric Augustin
Thanks Wim for the report.
2014-01-20Fixed #16905 -- Added extensible checks (nee validation) frameworkRussell Keith-Magee
This is the result of Christopher Medrela's 2013 Summer of Code project. Thanks also to Preston Holmes, Tim Graham, Anssi Kääriäinen, Florian Apolloner, and Alex Gaynor for review notes along the way. Also: Fixes #8579, fixes #3055, fixes #19844.
2014-01-12Add further workarounds for HTMLParser with Python 3.4.Marc Tamlyn
Python 3.5 will change the default value of convert_charrefs, so 3.4 gives warnings if it's not present. This is slightly technical as 2.7 doesn't have the kwarg. Thankfully, we already have a bunch of workarounds for different versions.
2014-01-12Used a regular lock for app registry population.Aymeric Augustin
Since the app registry is always populated before the first request is processed, the situation described in #18251 for the old app cache cannot happen any more. Refs #18251, #21628.
2014-01-10Fixed #21513 -- Added method_decorator support for argumented decoratordpwrussell
Copied attributes into the decorated method and special case __name__ copy as this will not be present on a Class object. Added regression test to decorator suite.
2013-12-31Fixed #21714 -- Moved logging configuration to global setup()Claude Paroz
Thanks Aymeric Augustin for the report and the review.
2013-12-28Fixed #20346 -- Made cache middleware vary on the full URL.ijl
Previously, only the URL path was included in the cache key. Thanks jamey for the suggestion.
2013-12-26Made the AppConfig API marginally more consistent.Aymeric Augustin
Eliminated the app_ prefix that was more confusing than useful.
2013-12-26Removed a few gratuitous lambdas.Aymeric Augustin
2013-12-24Renamed AppCache to Apps.Aymeric Augustin
Also renamed app_cache to apps and "app cache" to "app registry". Deprecated AppCache.app_cache_ready() in favor of Apps.ready().
2013-12-22Fixed #21651 -- Remove recapitalize.Marc Tamlyn
It was not used inside Django, is not tested or documented. Consequently remove without deprecation path. Thanks to @vajrasky for bringing it to our attention.
2013-12-22Moved apps back in the toplevel django namespace.Aymeric Augustin
Reverted 4a56a93cc458e9ab4dcab95d9f5067d4975dd1a2.
2013-12-22Stopped iterating on INSTALLED_APPS.Aymeric Augustin
Used the app cache's get_app_configs() method instead.
2013-12-22Added a context manager to hold the import lock.Aymeric Augustin
2013-12-16Removed unnecessary function-level import.Baptiste Mispelon
2013-12-16Removed unnecessary call to force_text in utils.html.clean_html.Vajrasky Kok
Refs #21574
2013-12-15Fixed #21621 -- Removed kqueue autoreloader.Aymeric Augustin
2013-12-14Fixed E127 pep8 warnings.Loic Bistuer
2013-12-12Fixed #21574 -- Handle bytes consistently in utils.text.normalize_newlines.Baptiste Mispelon
All input is now coerced to text before being normalized. This changes nothing under Python 2 but it allows bytes to be passed to the function without a TypeError under Python3 (bytes are assumed to be utf-8 encoded text). Thanks to trac user vajrasky for the report.
2013-12-12Fixed PEP257 violations (single-quoted docstrings) in utils.text.Baptiste Mispelon
2013-12-10Fixed E124 pep8 warnings.Loic Bistuer
2013-12-07Fixed #21573 -- Improved performance of utils.text.normalize_newlines.Vajrasky Kok
2013-12-04Fixed 21406 -- Made blocktrans 'trimmed' option preserve line numbers.Bouke Haarsma
Thanks Bouke Haarsma for report, fix and initial patch.
2013-12-04Fixed #21546 -- Strengthened kqueue detection.Aymeric Augustin
Thanks Loic Bistuer.
2013-12-03Fixed #21545 -- autoreload kqueue events weren't cleared which caused an ↵Loic Bistuer
infinite loop.