Commit Graph

7198 Commits

Author SHA1 Message Date
Aymeric Augustin bda21e2b9d Fixed #11555 -- Made SessionBase.session_key read-only. Cleaned up code slightly. Refs #13478.
This also removes the implicit initialization of the session key on the first access in favor of explicit initialization.



git-svn-id: http://code.djangoproject.com/svn/django/trunk@17155 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-27 17:52:24 +00:00
Alex Gaynor e4919f64b0 Clean up the the locmem cache backend and utils.synch by using context managers. Puch prettier.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17152 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-27 04:28:31 +00:00
Carl Meyer 1086a9a845 Fixed #17287 -- Prevented LocMemCache.incr/decr from changing key expiry time. Thanks Ivan Virabyan for report and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17151 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-26 22:27:16 +00:00
Aymeric Augustin 866c229f52 Fixed #17294 -- Supported nullable DateTimeFields when time zone support is enabled. Thanks pressureman for the report.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17148 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-25 09:25:43 +00:00
Julien Phalip a89b156284 Disentangled some parts of the admin ChangeList and ListFilter's internals. With this refactoring, the query string lookups are now processed once instead of twice and some bugs (in particular the SimpleListFilter parameter name being mistaken for a model field in some cases) are avoided.
Refs #17091.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@17145 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-22 12:26:17 +00:00
Alex Gaynor e71f33625c Fixed the humanize tests to work properly with a pure-python datetime module (platforms such as PyPy)
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17144 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-22 09:20:58 +00:00
Julien Phalip 8ddecc39db Fixed #17252 -- Fixed a minor regression introduced by the work in #11868, where the default sorted columns wouldn't correctly be visually represented in the changelist table headers if those columns referred to non model fields. Thanks to sebastian for the report and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17143 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-22 09:14:09 +00:00
Aymeric Augustin 658abb0859 Removed redundant definition of urls in the auth tests.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17142 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-22 07:44:26 +00:00
Paul McMillan 02a1b9a93e Improved the test for #16847.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17141 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-22 01:10:00 +00:00
Paul McMillan 16e3636a1a Fixed Python 2.5 test failure introduced in r17135.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17137 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-21 22:50:35 +00:00
Paul McMillan 0506facd86 Fixed #16378. Locmem now uses pickle.HIGHEST_PROTOCOL for better compatibility with other hash backends. Thanks aaugustin for the initial patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17136 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-21 22:25:49 +00:00
Paul McMillan 4d975b4f88 Fixed #16847. Session Cookies now default to httponly = True.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17135 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-21 22:03:03 +00:00
Aymeric Augustin 43c5d35315 Fixed #17274 -- Accepted TIME_ZONE = None when USE_TZ = True. Thanks pressureman for the report.
This problem only occured when pytz is installed. It's still strongly recommended to define the correct time zone in TIME_ZONE in order to use pytz' implementation and not the approximation based on system time.



git-svn-id: http://code.djangoproject.com/svn/django/trunk@17134 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-21 12:42:09 +00:00
Aymeric Augustin c5a899b190 Fixed #16787 -- Restored the ability to {% load %} template tags libraries within packages. Thanks Ivan Sagalaev for the report and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17133 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-21 10:28:12 +00:00
Aymeric Augustin 19e54084dc Fixed #17114 -- Handled integer values 0 and 1 for checkboxes like other integer values, not like False and True.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17132 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-21 10:11:06 +00:00
Aymeric Augustin 74b836abf5 Fixed #17062 -- Ensured that the effect of SET TIME ZONE isn't lost when the first transation is rolled back under PostgreSQL. Thanks Anssi for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17128 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-20 16:12:33 +00:00
Aymeric Augustin 98b08bd4d4 Upgraded the date based generic views to avoid warnings when time zone support is enabled.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17127 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-20 15:34:08 +00:00
Julien Phalip 5c9901323e Fixed #12073 -- Made `AdminDateWidget` and `AdminTimeWidget` consider user-supplied `attrs`. Thanks to elliss for the report and to koenb for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17125 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-20 11:12:37 +00:00
Aymeric Augustin 119e188717 Upgraded manage.py cleanup to be compatible with time zone support. See also r17121.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17124 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-20 11:04:37 +00:00
Aymeric Augustin 1510c3efda Upgraded django.contrib.comments to be compatible with time zone support.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17123 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-20 10:58:20 +00:00
Aymeric Augustin 03cfad4198 Upgraded django.contrib.auth to be compatible with time zone support.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17122 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-20 10:50:18 +00:00
Aymeric Augustin 4ac594f8a5 Upgraded django.contrib.sessions to be compatible with time zone support.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17121 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-20 10:33:44 +00:00
Aymeric Augustin 7075e93256 Made the database cache backend, which bypasses the ORM, compatible with time zone support.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17119 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-20 10:17:12 +00:00
Aymeric Augustin 9c30d48b45 Fixed #17263 -- Added a warning when a naive datetime reaches the database layer while time zone support is enabled.
After this commit, timezones.AdminTests will raise warnings because the sessions contrib app hasn't been upgraded to support time zones yet.
This will be fixed in an upcoming commit.



git-svn-id: http://code.djangoproject.com/svn/django/trunk@17117 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-19 23:27:20 +00:00
Aymeric Augustin d0eb4693ab Fixed #15255 -- Ensured createcachetable honors database routers.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17114 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-19 19:56:31 +00:00
Aymeric Augustin 549c495875 Used symbolic constants for psycopg2 isolation levels.
Django used the value 1 = ISOLATION_LEVEL_READ_UNCOMMITTED in some places, but
PostgreSQL doesn't provide "read uncommited", it uses "read committed" instead:
http://www.postgresql.org/docs/9.1/static/transaction-iso.html. For clarity,
this commit uses ISOLATION_LEVEL_READ_COMMITTED = 2 where 1 was previously used.



git-svn-id: http://code.djangoproject.com/svn/django/trunk@17112 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-19 14:18:44 +00:00
Aymeric Augustin 40b9532668 Fixed #16753 -- Supported network-path references in the syndication framework. Thanks cato for the report and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17108 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-18 22:54:24 +00:00
Jannis Leidel 6f66b55108 Fixed #17255 -- Removed "as" prefix from new timezone template filter names for the sake of clarity. Cheers to Aymeric Augustin for bearing with me.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17107 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-18 15:00:08 +00:00
Aymeric Augustin 9b1cb755a2 Added support for time zones. Thanks Luke Plant for the review. Fixed #2626.
For more information on this project, see this thread:
http://groups.google.com/group/django-developers/browse_thread/thread/cf0423bbb85b1bbf



git-svn-id: http://code.djangoproject.com/svn/django/trunk@17106 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-18 13:01:06 +00:00
Jannis Leidel 773d91ead2 Fixed #17128 -- Fixed a Python 2.5 incompatibility. Thanks, Simon Meers.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17102 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-17 21:30:07 +00:00
Jannis Leidel c20d33201c Fixed #17223 -- Correctly reference the signed cookies session backend. Thanks, Bryan Veloso.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17101 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-17 21:16:42 +00:00
Ramiro Morales 907015cb40 Fixed #17234 -- Added back a missing endblock tag to an admindoc template. Thanks shibz for the report and fix.
Refs #16912.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@17098 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-16 10:30:19 +00:00
Julien Phalip a6ccc8cc06 Fixed #15912 -- Ensured that `forms.CharField.widget_attrs()` always returns a dictionary. Thanks to tsabi and rubyruy for the report and to mmcnickle and prestontimmons for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17096 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-15 09:36:08 +00:00
Karen Tracey 5de31cb8cb Refs #17215: Avoid generating 47 leftover tmp dirs during a clean test run.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17094 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-13 19:05:02 +00:00
Karen Tracey b8353016b7 Fixed #13640: Avoid generating an exception when a model has an attribute named 'evaluate'. Thanks LukaszKorzybski and tobias.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17093 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-13 15:09:08 +00:00
Karen Tracey 0db571b417 Fixed #17134: Corrected Python 2.5 fallback code for parsing microseconds in time values. Thanks aaugustin and jcd.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17092 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-13 00:43:02 +00:00
Julien Phalip b45099eefb Fixed #17190 -- Ensured that the `NullBooleanSelect` widget's options get lazily localized. Thanks to pennersr for the report and to kenth for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17091 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-12 23:07:51 +00:00
Karen Tracey efe4e2e517 Fix #16570: Restore ability to have decimal fields where max_digits equals decimal_places. Thanks dcwatson and kenth.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17089 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-12 19:53:56 +00:00
Karen Tracey 63ba472cc4 Fix #13864: Removed database error raised when force_update is requsted on save of an inherited model with no fields of its own. Thanks fva, gregmuellegger, and markb1.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17088 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-12 19:06:39 +00:00
Karen Tracey f4f61baa8c Fix #16813: Restore checking whether a backend supports inctive users before sending inactive users in for permission checking. Thanks apollo13 for the report and poirier for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17084 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-12 17:23:07 +00:00
Julien Phalip c3df840c20 Fixed #16903 -- Added `--no-location` option to the `makemessages` command to not write '#: filename:line' comment lines in language files. Thanks to alpar for the suggestion and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17081 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-11 13:07:14 +00:00
Ramiro Morales e92b3b723f Fixed #11118 -- Made management command BaseCommand restore locale after execution.
Thanks rvdrijst for the report and initial patch and Claude Paroz for enhancing it.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@17077 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-07 11:28:31 +00:00
Julien Phalip 90d3697417 Fixed #17125 -- Made it possible to change a `RegexField`'s regular expression validator after it has been initialized. Thanks to Claude Paroz for the report and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17076 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-07 07:41:24 +00:00
Julien Phalip 5f64af9ecb Fixed #17152 -- Fixed a few anomalies in the `contrib.formtools` documentation and templates. Thanks, Bradley Ayers.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17072 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-06 01:19:40 +00:00
Julien Phalip b2948d8179 Fixed #17165 -- Fixed `SelectDateWidget._has_changed()` to work correctly with a localized date format.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17071 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-06 00:31:06 +00:00
Jannis Leidel a82488bf4b Fixed #16966 -- Stopped CachedStaticFilesStorage from choking on querystrings and path fragments.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17068 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-03 10:51:02 +00:00
Jannis Leidel 0e2c543979 Fixed #16967 -- Made sure CachedStaticFilesStorage repopulates its cache if there was a miss (for example if the cache server went down).
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17067 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-02 17:45:32 +00:00
Luke Plant 6d39cb4119 Fixed #5704 - Admin popup windows won't close when using application/xhtml as default content type
Thanks to Rob van der Linde for the report, and to mb0, dArignac and claudep
for the patch.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@17065 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-01 21:50:17 +00:00
Aymeric Augustin d71b4309ca Used yaml.safe_load instead of yaml.load, because safety should be the default.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17062 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-01 20:07:42 +00:00
Aymeric Augustin af1893c4ff Made the cache locale-dependant when USE_L10N is True, even if USE_I18N is False. Refs #5691.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17061 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-11-01 14:02:31 +00:00
Aymeric Augustin 01964fd7e4 Fixed an obsolete comment.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17060 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-31 18:54:24 +00:00
Aymeric Augustin d17bc72880 Fixed #17135 -- Made it possible to use decorators (like stringfilter) on template filter functions in combination with auto-escaping. Refs #16726.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17056 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-30 07:32:21 +00:00
Ramiro Morales bebbc9e4a5 Made a couple of changes for readability and correctness in loaddata.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17055 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-29 22:32:28 +00:00
Aymeric Augustin 0a1a9b71fa Made the defaultfilters tests run on the actual filters, not on functions imported from django.utils.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17054 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-29 15:28:44 +00:00
Ramiro Morales eedc9cb5f6 Fixed #16849 -- Updated management command verbosity option help text.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17053 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-29 15:01:17 +00:00
Aymeric Augustin 52c66a21e1 Used the decorator syntax consistently to register template filters.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17052 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-29 14:51:43 +00:00
Ramiro Morales 345be05622 Enhanced loaddata error message printed when no DB fixture is provided.
Fixes #7043 by fixing the last code path where a misleading 'No fixtures found.' error message was being shown.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@17051 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-29 14:47:45 +00:00
Aymeric Augustin 69eadc7f15 Used the decorator syntax consistently for stringfilter. Fixed linebreaks that was decorated twice.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17050 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-29 14:39:02 +00:00
Ramiro Morales 24f3c06e4a More django.conf.urls.defaults removals. Refs #17132
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17049 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-29 12:24:44 +00:00
Alex Gaynor 3e66913f96 Fixed #17132 -- remove a leftover reference to django.conf.default.urls in Django. THanks to claudep for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17048 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-28 21:23:50 +00:00
Carl Meyer 7a718f0f3a Fixed #17127 -- Made field validators list independent per form instance. Thanks claudep for report and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17046 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-28 14:38:41 +00:00
Aymeric Augustin 0cf139d201 Fixed several problems that hid one another in the cache tests and code.
1 - Used django.test.TestCase instead of unittest.TestCase so that the override_settings decorator works.
2 - Reverted parts of r17039 that caused failures (masked until 1).
3 - Isolated tests by clearing the cache in tear down (masked until 1). Refs #11505.
4 - Fixed a bug in cache key generation (revealed by 3).
5 - Fixed a test that relied on this bug -- hardcoding the generated cache keys in tests isn't a very good idea anyway.
6 - Uniformized some parts of the cache tests.



git-svn-id: http://code.djangoproject.com/svn/django/trunk@17042 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-26 22:47:04 +00:00
Aymeric Augustin 4cfb7632e0 Removed remains from times when tests could be run outside of runtests.py.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17040 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-26 21:03:18 +00:00
Carl Meyer 5a16b64ed2 Avoid spurious failures in naturaltime tests.
Previous fix didn't cover timesince module, which naturaltime delegates to
under certain conditions. Extended mock of datetime to timesince module, and
switched to a fixed datetime rather than now() for testing, for more
reproducible tests (failures in mock will fail fast, rather than sporadically).

git-svn-id: http://code.djangoproject.com/svn/django/trunk@17038 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-26 15:17:43 +00:00
Julien Phalip 9796f69533 Fixed #16257 -- Added new `ModelAdmin.get_list_display_links()` method to allow for the dynamic display of links on the admin changelist. Thanks to graveyboat for the suggestion and initial patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17037 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-26 12:19:18 +00:00
Julien Phalip 600c576ac5 Fixed #17090 -- Made the API specification for `ModelAdmin.get_list_display()` more consistent with that of `ModelAdmin.list_display` by separating out the admin action check boxes business. This is backwards-incompatible for those who have been using the still-unreleased `get_list_display()` method. Thanks to Ramiro Morales for the review.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17035 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-26 09:37:07 +00:00
Julien Phalip 4d79083453 Fixed #17111 -- Made the `redirect_to` generic view properly handle query strings with percent symbols. Thanks, Chris Adams.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17034 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-26 06:33:13 +00:00
Julien Phalip 2e2689c7c0 Fixed #15938 -- Prevented the `max_length` number in the admin `prepopulated_fields` javascript to be localized when `USE_THOUSAND_SEPARATOR` is turned on. Thanks to Lev Maximov, Mathieu Agopian and feel.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17033 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-26 05:33:17 +00:00
Julien Phalip c1a014bba4 Made some `contrib.messages` tests use `override_settings` for clarity. Thanks to Claude Paroz for the patch. Refs #16507, #16574.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17032 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-25 02:55:25 +00:00
Carl Meyer 6df91d9539 Fixed #17086 -- Removed pollution of global template-builtins from markup and humanize tests.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17031 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-24 21:30:55 +00:00
Carl Meyer d89be53d95 Fixed #17099 -- Removed an out-of-date warning and some unused code, now that startapp doesn't require creating app inside project. Thanks ptone for the report.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17030 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-24 20:50:39 +00:00
Aymeric Augustin 965c5d7cce Fixed #14202 -- made the atom:link element optional in feeds.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17029 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-23 15:19:09 +00:00
Julien Phalip 59c051d170 Fixed #13760 -- Cleaned up unnecessary default option handling in a bunch of management commands. Thanks to Paul McMillan for the report and to adamv and Claude Paroz for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17028 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-23 03:43:43 +00:00
Julien Phalip adf51b0cb8 Fixed #16574 -- Strengthened the `contrib.messages` tests' isolation to avoid failures under certain project setting environments. Thanks to Boldewyn for the report and to Claude Paroz for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17027 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-22 23:39:09 +00:00
Julien Phalip 4f00a2d316 Fixed #15826 -- Made `assertContains` and `assertNotContains` work with `SimpleTemplateResponse` by forcing it to be rendered if it hasn't been rendered yet. Thanks to bmihelac for the report, to mmcnickle for the initial patch and tests, and to Carl Meyer for the guidance.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17025 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-22 09:15:50 +00:00
Carl Meyer 36a44ae75f Mocked datetime in the naturaltime tests to avoid sporadic test failure.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17023 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-22 06:06:44 +00:00
Carl Meyer 145a77edc9 Fixed #16360 -- Added WSGI entrypoint to startproject layout, and enabled internal servers (runserver and runfcgi) to use an externally-defined WSGI application. Thanks to Armin Ronacher, Jannis Leidel, Alex Gaynor, ptone, and Jacob Kaplan-Moss.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17022 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-22 04:30:10 +00:00
Julien Phalip dca81ad58a Fixed #17064 -- Improved the UX for the admin's time and date picker widgets by brushing up the 'Cancel' button's visual feedback and by allowing the popups to get closed by pressing the 'Escape' key.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17021 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-22 03:38:10 +00:00
Alex Gaynor 9117a4af30 move an mport out of a function
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17020 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-21 23:38:52 +00:00
Justin Bronn 01f4ce4c49 Fixed #17059 -- Encode `GeoIP` query strings properly so `libGeoIP` returns results for unicode strings.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17019 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-20 20:08:33 +00:00
Ramiro Morales b3b9049942 Fixed #17071 -- Made sure we report the right version of system-level {simple,}json module.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17018 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-20 17:21:10 +00:00
Julien Phalip 1452cecd15 Fixed 16938 -- Ensured that the active locale's formats take precedence over the default settings even if they would be interpreted as False in a conditional test (e.g. 0 or empty string). Thanks to pikerr for the report and initial patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17017 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-20 12:14:06 +00:00
Julien Phalip 51b8f0a240 Removed a small useless piece of code from `contrib.auth`.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17016 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-20 04:23:34 +00:00
Julien Phalip 26698bc851 Fixed #14806 -- Added support for contextual translations to the `trans` and `blocktrans` template tags. Thanks to jtiai for the report.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17015 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-19 04:59:47 +00:00
Alex Gaynor 358e5a8031 Fixed #16393 -- FormWizard's cookie storage backend now works with all versions of simplejson and the standard library json module.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17014 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-19 00:09:41 +00:00
Paul McMillan 67565a5379 Remove comments referencing encryption. Django doesn't do encryption.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17012 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-18 20:28:52 +00:00
Aymeric Augustin 14d24eb438 Fixed #17067 -- reverted some backwards-incompatible changes from r16933 and added tests.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17010 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-18 16:42:32 +00:00
Alex Gaynor 396fcaaef9 Remove all relative imports. We have always been at war with relative imports.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17009 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-18 00:47:49 +00:00
Alex Gaynor 66210cbc70 Remove a great many of the remaining relative imports.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17008 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-17 18:45:22 +00:00
Alex Gaynor 544a8372fd Remove several more relative imports.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17007 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-17 16:56:18 +00:00
Alex Gaynor 1856e398c5 Remove more relative imports (I will kill them all).
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17006 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-17 16:39:53 +00:00
Alex Gaynor 87ffc6a6c2 remove some relative imports from django
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17003 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-17 13:15:40 +00:00
Carl Meyer 62afd58c87 Fixed #17057 -- Corrected flatpage url uniqueness validation to account for flatpage editing.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@17000 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-17 00:56:32 +00:00
Ramiro Morales 5f2be4ecbb Fixed #17056 -- Tweaked insert SQL clause generation so a corner case doesn't fail with Oracle.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16997 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-16 20:06:59 +00:00
Aymeric Augustin d75337fc7b Fixed a test that was broken at r16978. Refs #17055.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16993 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-16 09:46:01 +00:00
Julien Phalip 93a581431a Fixed #15221 -- Made the admin filters on foreign key and m2m relationships display the related field's verbose name instead of that of the related model.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16991 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-16 06:42:50 +00:00
Aymeric Augustin 246580573d Fixed #12308 -- Added tablespace support to the PostgreSQL backend.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16987 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-14 21:49:43 +00:00
Alex Gaynor 6c91521902 Remove the usage of deprecated function in Django. Also simplify the fallback code.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16985 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-14 00:20:50 +00:00
Aymeric Augustin f830166167 Fixed #16899 -- Backported the fix for http://bugs.python.org/issue9063 and added a test.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16980 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-13 21:19:48 +00:00
Aymeric Augustin 38999f7e00 Fixed #16923 -- Removed unused method in the serialization code.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16979 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-13 19:39:46 +00:00
Aymeric Augustin 06d9b82a27 Fixed #16906 -- Format datetimes with str/unicode instead of strftime where possible: it's faster and it works for all dates.
Also ensured that datetime_safe is used wherever strftime is called on dates/datetimes that may be before 1900.


git-svn-id: http://code.djangoproject.com/svn/django/trunk@16978 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-13 19:23:45 +00:00
Julien Phalip 99512d3544 Fixed #16918 -- Ensured that custom querysets are used when provided to `BaseDateDetailView.get_object()`. Thanks to mitar for the report, to koenb for the patch and to Preston Holmes for the review.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16974 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-13 13:38:38 +00:00
Julien Phalip c58e5724bc Fixed a couple of `assert` syntax warnings mistakingly introduced in r16966 and added some tests to prevent future regressions. Thanks to Anssi Kääriäinen for the report.
Refs #12467.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16971 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-13 11:53:59 +00:00
Julien Phalip 1f1b16722e Fixed a padding issue in admin tabular inline headers.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16968 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-13 10:09:17 +00:00
Julien Phalip 4da7c772ad Fixed #16776 -- Fixed a regression introduced in r16415 which caused Django's embedded jQuery to overwrite any pre-existing values of `window.jQuery` in the global namespace. Many thanks to Rob Hudson, Jannis Leidel and "anonymous" for the help resolving this issue.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16967 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-13 09:20:10 +00:00
Julien Phalip 3b22c68343 Fixed #12467 -- Made the model data validation for `DateField` and `DateTimeField` more useful by actually telling what was the value that failed. Also did a bit of PEP8 cleanup in the area. Thanks to knutin for the report, to raulcd for the initial patch and to charettes for the review.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16966 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-13 08:11:00 +00:00
Carl Meyer 38f1fe3b35 Fixed #15372 -- Switched to a startproject default layout that allows us to avoid sys.path hacks.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16964 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-13 05:56:15 +00:00
Alex Gaynor f04af7080b Introduce `ContentType.objects.get_for_models(*models)` and use it in the the auth permissions code. This is a solid performance gain on the test suite. Thanks to ptone for the profiling to find this hotspot, and carl for the review.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16963 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-12 20:51:59 +00:00
Alex Gaynor a5e691e5de Convert the contettypes tests to use self.assertNumQueries, rather than hand rolling their own version. Thanks to carl for the review.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16962 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-12 19:34:34 +00:00
Alex Gaynor 3e940cdfd9 Simplify some code to have one loop, rather than two.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16959 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-11 20:43:11 +00:00
Alex Gaynor e35ba97740 Change some string literals to be unicode, because:
* It's the most micro of optimizations (forget I even said it)
    * It makes significantly more sense semantically, given these are functions which return unicode.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16957 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-11 17:36:05 +00:00
Ramiro Morales 4725a732e7 Fixed #9460 -- Added template blocks for submit buttons rows in admin app model add/change views.
This allows for easier customization. Thanks kosmik for report and patch.

Refs #13875.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16956 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-10 22:19:59 +00:00
Julien Phalip 17659adf93 Fixed #16371 -- Added a prefix "field-" to all CSS class names automatically generated from field names in admin forms to avoid conflicts with other common class names (e.g. "button"). This is backwards-incompatible for those who previously used plain field names as selector in custom style sheets or javascript transformations.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16953 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-10 12:35:06 +00:00
Julien Phalip 6d7461ffdd Fixed #17019 -- Fixed a minor margin issue in multi-field admin form rows for right-to-left languages. Thanks to rem for the report and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16947 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-09 11:37:48 +00:00
Carl Meyer 29def3e52c Fixed #16873 - Added dummy database backend in default settings, so that just importing django.db doesn't trigger ImproperlyConfigured if there is no DATABASES setting.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16946 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-08 19:23:37 +00:00
Luke Plant d5803bb5fb More efficient IN clauses for prefetch_related queries by use of sets to eliminate duplicates
This simply reduces the size of the IN clause in the SQL, which can be
significant in some cases.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16944 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-08 13:50:29 +00:00
Carl Meyer b6ad1afa68 Fixed #17011 - Made override_settings modify a decorated class in-place rather than creating a dynamic subclass, so as to avoid infinite recursion when used with super(). Thanks jsdalton for the report and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16942 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-08 08:16:17 +00:00
Luke Plant 64da8eec30 Fixed #17014 - added protection against infinite recursion.
Thanks to akaariai for the report and tests.

No tests have been added, since unittests for termination are basically
impossible, and the failure condition will take down the developer's machine
in this case. It has been tested against the cases in #17014.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16940 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-07 16:06:02 +00:00
Luke Plant 052a011ee6 Fixed #17003 - prefetch_related should support foreign keys/one-to-one
Support for `GenericForeignKey` is also included.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16939 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-07 16:05:53 +00:00
Carl Meyer 3f3010014b Fixed #14678 -- Added validation to catch flatpages with the same URL on the same site. Thanks seler for the report, and joni, graham_king, and j4nu5 for work on the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16937 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-07 15:45:52 +00:00
Aymeric Augustin 510ea906f7 Fixed #17012 - Removed references to the 'hasNoProfanities' validator. Refs #8794.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16935 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-07 08:35:20 +00:00
Carl Meyer b1b1da1eac Fixed #8060 - Added permissions-checking for admin inlines. Thanks p.patruno for report and Stephan Jaensch for work on the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16934 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-07 00:41:25 +00:00
Aymeric Augustin e2f9c11736 Fixed #16705 - Made the test client adhere to the WSGI spec -- in particular, removed the assumption that environ['QUERY_STRING'] exists.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16933 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-06 20:39:15 +00:00
Luke Plant b763412aa4 Removed ForeignRelatedObjectsDescriptor.RelatedManager.delete_manager, which has been unused since [14507]
And cleaned up the result, allowing more consistency with the other related
descriptors.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16931 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-06 11:08:11 +00:00
Luke Plant 662eea116f Fixed #16937 - added `QuerySet.prefetch_related` to prefetch many related objects.
Many thanks to akaariai for lots of review and feedback, bug finding,
additional unit tests and performance testing.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16930 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-05 23:14:52 +00:00
Luke Plant d30fbf8b78 Fixed #16902 - select_related() results in a poor perfomance
Thanks to ivan_virabyan for the great patch!

(For the record, some very small tweaks were made by me).

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16929 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-05 22:56:09 +00:00
Julien Phalip 03d4a8d1b6 Fixed #16990 -- Fixed a couple of small docstring typos in the `django/test/testcases.py` module and did some minor cleanup while I was in the area.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16928 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-05 12:50:44 +00:00
Luke Plant 05cf72bace Very small docstring correction.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16927 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-05 09:54:01 +00:00
Paul McMillan 1ac2bb9b8e Fixed #16987 -- Improved error message for session tests. Thanks jMyles and DiskSpace for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16926 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-05 05:21:47 +00:00
Aymeric Augustin 2a044732f6 Fixed #16971 - Made the parsing of javascript files by 'makemessages' much faster. Thanks Antti Haapala for the implementation and Ned Batchelder for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16924 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-04 20:11:41 +00:00
Ramiro Morales 0d9b6a5bc4 Fixed #10841 -- Switched response served when DEBUG=True and request.is_ajax() returns True (indicating request has been generated by a JS library) to a plain text version for easier debugging.
Contents of this response are similar to its HTML counterpart modulo frame variables values in the Python traceback section.

Thanks to Riz for the report, to SmileyChris for the patch and to Julien for reviewing.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16921 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-10-02 02:53:58 +00:00
Luke Plant 10d90cba83 Fixed #16935 - misleading message if AttributeError escapes during SimpleTemplateResponse.render
Thanks to isagalaev for the report.

As discussed on django-devs, this reverts some of the changes in [16568]
i.e.  the addition of `SimpleTemplateResponse.__getattr__`, because this
makes it much harder to debug the common case of an AttributeError somewhere
during the rendering of a SimpleTemplateResponse.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16917 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-30 11:46:23 +00:00
Luke Plant 5009e45dfe Fixed #14270 - related manager classes should be cached
Thanks to Alex Gaynor for the report and initial patch, and mrmachine for
more work on it.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16916 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-30 10:41:25 +00:00
Luke Plant ec5bfed57a Made GenericRelatedObjectManager consistent with other related managers w.r.t. use of core_filters attribute.
Previously it had an unused keyword argument.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16914 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-29 15:30:37 +00:00
Luke Plant 6d6fe61bf6 Cleanups to related manager code, especially in use of closures.
The related manager classes are defined within functions, and the methods
had inconsistent and confusing usage of closures vs. parameters on self to
retrieve needed information. Everything is stored on self now.

Also some methods were not using super() where they should have been.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16913 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-29 15:30:29 +00:00
Luke Plant e3a6ac8f60 Small cleanups of 'related manager' code for consistency
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16912 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-29 15:30:19 +00:00
Julien Phalip 8137027fd7 Fixed #13956 -- Enabled `*args` and `**kwargs` support for `simple_tag`, `inclusion_tag` and `assignment_tag`. Many thanks to Stephen Burrows for the report and initial patch, to Gregor Müllegger for the initial tests, to SamBull for the suggestions, and to Jannis Leidel for the review and PEP8 cleanup.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16908 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-27 12:15:15 +00:00
Luke Plant 29b8e34dfb Removed unused parameter 'join_table' in various bits of RelatedManager code
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16907 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-26 17:20:20 +00:00
Ramiro Morales 735fbcfe8b Fixed #16597 -- Added Sphinx cross-reference metadata to the form wizard docs. Thanks FunkyBob for the report and jkistler for the patch.
Also, additional fixes in that document and in the WizardView docstrings.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16904 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-26 01:37:57 +00:00
Ramiro Morales 3ef1762cb9 Fixed #16924 -- Corrected `date` template filter handling of negative (West of UTC) timezone offsets.
The 'O' format specifier output was incorrect. Thanks mrgriscom and Aymeric Augustin.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16903 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-25 17:08:31 +00:00
Julien Phalip 482388cd61 Fixed #16927 -- Corrected the `{% ifchanged %}` template tag's documentation. Thanks to sebastian for the report and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16902 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-25 05:21:29 +00:00
Ramiro Morales 4c457bca85 Fixed #16789 -- Added names to URLs in convenience contrib.auth urls.py.
Thanks wim AT go2people DOT nl for the report, cmheisel for the patch and
fcurella for reviewing it.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16901 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-24 19:48:27 +00:00
Jannis Leidel ce9e3b4e97 Fixed a regression introduced in r16897. Thanks to Julien for the eagle eyes and Florian Apolloner for the review.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16900 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-24 13:32:57 +00:00
Julien Phalip f2ed107b07 Simplified the admin changelist multi-sort interface specifically by removing the popup window, adding explicit tooltip help texts, improving the hover visual states and allowing all operations (i.e. removing a column from sorting and toggling the sorting with and without changing the sorting priority) to be actionable with just one click. Many thanks to Idan Gazit for the feedback and direction. Refs #16212.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16899 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-24 06:17:53 +00:00
Ramiro Morales b1c3174cfa Removed unused code from admindocs app now that it supports reversing URLs.
As a consequence the undocumented `ADMIN_SITE_ROOT_URL` setting isn't used anymore.

Refs r8718 and r16857.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16898 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-23 23:57:06 +00:00
Jannis Leidel 6cae2a550d Fixed #16878 -- Improved intword filter to support numbers up to decillion and googol. Thanks to crodjer for the initial patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16897 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-23 16:45:40 +00:00
Carl Meyer 0a9c52e013 Fixed #16917 -- Don't try to use the model name for a ContentType's unicode representation if the model no longer exists. Thanks Ivan Sagalaev for report and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16895 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-23 04:22:30 +00:00
Gabriel Hurley 39bbd1653a Fixed #7198 (again) -- Corrects a problem with string interpolation from r16876 and adds tests for the new error message.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16888 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-22 21:09:00 +00:00
Ramiro Morales bb641631e5 Fixed #16912 -- Fixed breadcrumb styling in a couple of admin pages, broken since r16857. Thanks Florian Apolloner for the report.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16887 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-22 17:04:05 +00:00
Jannis Leidel 66dc22c2d9 Fixed #16909 -- Pass language to get_format_modules when calling it from get_format to make sure the correct module is returned.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16884 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-22 15:04:27 +00:00
Paul McMillan c59339f450 Fixed #16565 -- Fixed a databrowse error on null foreign key, even though databrowse is deprecated. Thanks aaugustin for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16883 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-22 06:37:50 +00:00
Paul McMillan d0979a5faf Fixed #6011 -- Improved help text for flush command. Thanks Julien for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16877 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-22 05:21:51 +00:00
Paul McMillan f44c4a5d0f Fixed #7198 -- Improved error message when missing models.py. Thanks Silver_Ghost and for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16876 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-22 05:10:52 +00:00
Paul McMillan 1d96d886e7 Fixed #16026 -- loaddata now identifies which object triggered an error.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16873 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-22 04:30:20 +00:00
Paul McMillan 0781ed8ec8 Fixed #16837 -- Improved error message for admin login.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16872 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-22 04:16:21 +00:00
Paul McMillan 5a01324f20 Fixed #16907 -- Deprecate databrowse.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16871 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-22 04:10:02 +00:00
Carl Meyer f91af72523 Fixed #16353 -- don't try to create Site objects on all databases. Refs #15573, #15346. Thanks Aymeric Augustin for the report and the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16868 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-21 22:46:48 +00:00
Julien Phalip 8f750bf6e5 Fixed #16897 -- Fixed some docstrings and help texts for the `makemessages` management command. Thanks, Simon Meers.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16864 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-21 17:25:13 +00: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 eb5df8e98d Fixed the relative static file resolution of the CachedStaticFilesStorage backend and the post processing of deeply nested static files.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16862 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-21 15:58:21 +00:00
Carl Meyer 75199e8f6d Fixed #16866 -- Clearer error message if empty list is passed to select_template. Thanks Silver_Ghost for report and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16861 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-21 14:20:18 +00:00
Carl Meyer 09a01435de Fixed #16838 -- Corrected broken add-another inline JS in admin with related_name="+". Thanks jamesp for report and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16860 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-21 14:00:58 +00:00
Ramiro Morales aaf77c1676 Converted internal link generation in the admin and admin document generator to use named URLs.
Thanks to Florian Apolloner for both the initial patch and his final push to get
this fixed, to Dario Ocles for his great work on the admin templates and
switching the admin_doc application to also use named URLs, to Mikko Hellsing
for his comments and to Jannis and Julien for their review and design guidance.

Fixes #15294.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16857 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-20 18:30:06 +00:00
Julien Phalip 212b048564 Fixed #16659 -- Made the admin's date drilldown links in the changelist have a variable width to play nicer with languages with long month names.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16854 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-19 07:25:59 +00:00
Justin Bronn e5aeba018f Updated geoadmin tests to reflect that OSM js is no longer required as of r16847.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16853 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-18 22:28:17 +00:00
Paul McMillan d15ef4532e Removed an unused function definition.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16852 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-18 21:33:14 +00:00
Julien Phalip 436aeb6e15 Fixed #16676 -- Corrected the behavior of the 'add' template filter to return an empty string instead of the given value unchanged in the case of an invalid use. Thanks to dtrebbien for the report and to Aymeric Augustin for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16851 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-18 08:33:39 +00:00
Chris Beaven e63fa0ff83 Fixes #8103 -- Select widget should only allow for one selected option
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16848 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-18 04:09:44 +00:00
Justin Bronn 1ec25c4fb7 OpenLayers has had built-in OSM support since 2.10, no need for extra JS.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16847 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-17 23:01:46 +00:00
Justin Bronn 30745b2e65 Updated the geographic admin to use OpenLayers 2.11.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16846 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-17 20:06:00 +00:00
Justin Bronn 3ac877840a Fixed #15277 -- Cleaned up `ogrinspect` command, added tests and extended support beyond file-based OGR data sources. Thanks, willinoed for bug report and jpaulett for initial patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16845 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-17 19:54:52 +00:00
Justin Bronn f97a574196 Fixed #16864 -- WKT regex now allows negative SRIDs. Thanks, Marcel Dancak for bug report and initial patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16843 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-16 21:19:30 +00:00
Carl Meyer 343004c4de Fixed #16568 -- Added RequireDebugFalse filter to prevent sending 500 error emails when DEBUG is True in projects with no explicit LOGGING setting. Thanks to Andreas Pelme for report and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16840 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-16 16:41:38 +00:00
Carl Meyer f9dad46d36 Fixed #16803 -- Use model verbose_name directly as ContentType unicode representation so it can be translated. Thanks to bronger for the report and Ivan Sagalaev for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16839 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-16 11:57:03 +00:00
Carl Meyer 568681c6da Fixed #16812 -- Percent-encode URLs in verify_exists, to fix test failures on Python 2.5 and 2.6.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16838 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-16 11:12:35 +00:00
Julien Phalip def775ae5e Reverted the change in r16683, which, while fixing an alignment issue in IE7 with the admin's "Save and continue editing" and "Save and add another" buttons, caused the swapping of those buttons' order. Thanks to jocmeh for the report. Refs #16852.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16835 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-16 06:30:05 +00:00
Carl Meyer 4397c587a4 Fixed #16770 -- Eliminated TemplateSyntaxError wrapping of exceptions. Thanks to Justin Myles-Holmes for report and draft patch.
Exceptions raised in templates were previously wrapped in TemplateSyntaxError
(in TEMPLATE_DEBUG mode only) in order to provide template source details on
the debug 500 page. The same debug information is now provided by annotating
exceptions rather than wrapping them. This makes catching exceptions raised
from templates more sane, as it's consistent in or out of DEBUG, and you can
catch the specific exception(s) you care about rather than having to also catch
TemplateSyntaxError and unwrap it.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16833 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-16 01:16:25 +00:00
Alex Gaynor 608548baa2 Fixed #16854 -- corrected an AttributeError coming from the contenttypes post-syncdb hook. Thanks to desh for the report.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16832 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-15 23:55:30 +00:00
Carl Meyer ce48e8e940 Fixed #16848 - Adjusted SimpleTemplateResponse.__init__ to be less brittle.
Could have reverted r16830 instead, but HttpResponse shouldn't have to dance
around and do non-obvious things to keep TemplateResponse happy,
TemplateResponse should be robust against the possibility that
HttpResponse.__init__ might set self.content.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16831 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-15 07:26:35 +00:00
Paul McMillan 2fa433ed55 Slight cleanup to r16829, thanks Alex Gaynor for the note.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16830 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-14 23:58:12 +00:00
Paul McMillan 50255e3305 Fixed #16494 by normalizing HttpResponse behavior with non-string input. HttpResponse now always converts content to string on output, regardless of input type.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16829 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-14 23:27:35 +00:00
Justin Bronn 67e05fcd39 Fixed #16778 -- Improved escaping of geometries on PostgreSQL, allowing GeoDjango to work on 9.1. Thanks, piro for ticket and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16826 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-13 20:43:33 +00:00
Jannis Leidel f3ae496201 Fixed #16833 -- Removed undocumented `mixin` parameter from the `Storage.open()` method as this was an undocumented and obscure feature. Thanks to Marty and Russell for sanity-checking.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16824 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-13 15:10:49 +00:00
Julien Phalip c76112cf1d Fixed #4198 -- Fixed a small styling issue in the admin calendar widget. Thanks to Gary Wilson and fcurella.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16822 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-13 03:10:07 +00:00
Ramiro Morales 9fe050a275 Added an implementation of bulk insert via the ORM to the Oracle DB backend.
Refs #7596, r16739 and http://troels.arvin.dk/db/rdbms/#insert-multiple

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16819 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-11 23:02:53 +00:00
Ramiro Morales 26b8122087 Fixed #14675 -- Completed removal of `from django.conf.urls.default import *` usage.
This applies to both our own [test] code and documentation examples. Also:
 * Moved the functions and handlers from `django.conf.urls.defaults` up to
   `django.conf.urls` deprecating the former module.
 * Added documentation for `handler403`.
 * Tweaked the URLs topic document a bit.

Thanks to pupeno and cdestigter for their great work contributing patches.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16818 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-11 22:36:16 +00:00
Justin Bronn 28cb5bf162 Fixed #16231 -- Added support for GML and KML on the SpatiaLite backend. Thanks, steko for the bug report and jpaulett for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16800 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-11 00:52:08 +00:00
Ramiro Morales 83484cc109 Fixed #14138 -- Removed a superfluous import in the sqlite3 DB backend.
This could be of help with some issues people were seeing when deploying
Django with sqlite and Apache.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16799 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-11 00:52:03 +00:00
Justin Bronn a25413bf86 Fixed #15305 -- Made `Count` aggregate and `.values()` play nice together on `GeoQuerySets`. Thanks, vrehak for the bug report and milosu for initial patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16797 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-11 00:00:15 +00:00
Justin Bronn 2918c3de74 Fixed #14648 -- Fixed annotated date querysets when `GeoManager` is used. Thanks, codysoyland, for the bug report.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16796 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-10 22:53:26 +00:00
Alex Gaynor 8e1226b4a0 Kill some more dead code.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16795 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-10 22:46:44 +00:00
Alex Gaynor 345c4c4629 Remove a bunch of deadcode/dead imports.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16794 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-10 22:31:38 +00:00
Alex Gaynor 807b2a8216 Fixed bulk_insertion on databases which don't yet support it. Thanks to Justin Bronn for his Oracle wizardry.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16793 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-10 22:02:13 +00:00
Alex Gaynor b45a4acf6f Ensure bulk_create returns the right value if the argument is an empty list.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16792 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-10 21:46:59 +00:00
Alex Gaynor f2bc919ec0 Ensure bulk_create returns what it is supposed to.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16791 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-10 21:44:57 +00:00
Alex Gaynor e95d0afe9e Fixed #16810, corrected a bad docstring. Thanks to kenkam for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16790 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-10 21:29:21 +00:00
Alex Gaynor e130dc3275 Removed the deprecated-since-1.2 "supports_object_permissions" and "supports_anonymous_user" flags on authentication backends. If you have an authenication backend it now *must* suport these.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16789 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-10 21:00:32 +00:00
Alex Gaynor 0609255dd2 Remove this deprecated alias.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16788 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-10 21:00:25 +00:00
Alex Gaynor dafb4951a7 Make a comment more accurate.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16786 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-10 19:45:16 +00:00
Russell Keith-Magee fcee0c1b66 Fixed #16809 -- Forced MySQL to behave like a database. This avoids a problem where queries that do IS NONE checks can return the wrong result the first time they are executed if there is a recently inserted row. Thanks to James Pyrich for the debug work and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16785 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-10 18:58:30 +00:00
Justin Bronn 05e29716b4 Fixed #16553 -- Refactored the `GeoIP` module, moving it `django.contrib.gis.geoip`; fixed memory leaks, and encoding issues.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16783 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-10 18:04:27 +00:00
Alex Gaynor efb8327444 Fixed #16808, removed some dead code from teh ORM. Thanks to aaugustin for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16782 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-10 17:38:58 +00:00
Justin Bronn 36120f41a9 Fixed #16537 -- Fixed multi-db issues with GeoDjango utilities. Thanks, Shane Shifflett for the bug report and aaugustin for the initial patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16779 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-10 17:19:05 +00:00
Alex Gaynor 67dde2f52f Fixed #16162. Added timeout arg to `DummyCache.set_many`, for compatiblity with other caches. Thanks to aaugustin for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16778 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-10 17:09:23 +00:00
Justin Bronn eaea9deca8 Fixed #16790 -- Modified the geographic admin to work after r16594. Thanks, jdiego, for the bug report and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16775 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-10 03:04:30 +00:00
Alex Gaynor d14bf8c62b Fixed #11404. Added ``FormSet.has_changed``, for consistancy with ``Form.has_changed``. Thanks to michelts for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16773 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-10 02:42:05 +00:00
Alex Gaynor 01b0eb50fd Make ``Formset.__getitem__`` O(1), rather than O(n). If you override ``__iter__`` you now need to also override ``__getitem__`` for consistant behavior. Thanks to Carl and Russ for the review.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16770 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-10 01:53:56 +00:00
Russell Keith-Magee 5f287f75f2 Altered the behavior of URLField to avoid a potential DOS vector, and to avoid potential leakage of local filesystem data. A security announcement will be made shortly.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16760 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-10 00:47:00 +00:00
Russell Keith-Magee 33076af6f2 Corrected an issue which could allow attackers to manipulate session data using the cache. A security announcement will be made shortly.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16759 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-10 00:46:48 +00:00
Russell Keith-Magee 893cea211a Added protection against spoofing of X_FORWARDED_HOST headers. A security announcement will be made shortly.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16758 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-10 00:46:38 +00:00
Justin Bronn 0516ac3d28 Fixed #13670 -- Comparisons with the spatial adapter won't blow up in some corner cases. Thanks, milosu for the bug report and jpaulett for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16757 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-10 00:29:34 +00:00
Karen Tracey e061b036a5 Fixed #15722: ensure formsets evaluate to True even if they have no forms. Thanks mlavin.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16756 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-10 00:05:48 +00:00
Chris Beaven 470c70f876 Fixes #16664 -- URLField's to_python method fails with ValueError on some urls on python 2.7. Based on patch by zigzag.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16752 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-09 22:57:12 +00:00
Justin Bronn c4d8b4c0b2 Removed extra call to `syncdb` that slipped in with r16749.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16750 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-09 22:47:18 +00:00
Justin Bronn 43329af2e3 Fixed #16408 -- Fixed conversion of dates, and other problems with the SpatiaLite backend.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16749 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-09 22:34:23 +00:00
Chris Beaven fe88584589 Fix and test for cleaning a non-string value in a URLField
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16747 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-09 22:32:38 +00:00
Alex Gaynor 699688dc2c Switch to using explicit new-style division behavior, rather than relying on teh classic behavior.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16745 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-09 21:45:58 +00:00
Justin Bronn 6273db307e Fixed a brittle test in the `LayerMapping` tests.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16741 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-09 19:51:06 +00:00
Jannis Leidel fb590bfa9b Replaced `has_key()` calls with `in` to ease Python 3 port. Thanks, Martin von Löwis.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16740 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-09 19:33:40 +00:00
Alex Gaynor 7deb25b8dd Fixed #7596. Added Model.objects.bulk_create, and make use of it in several places. This provides a performance benefit when inserting multiple objects. THanks to Russ for the review, and Simon Meers for the MySQl implementation.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16739 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-09 19:22:28 +00:00
Jannis Leidel e55bbf4c3c Fixed #15237 -- Fixed a typo in specifying UTF-8 encoding in the feed generator and signing tests. Thanks, Aymeric Augustin.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16738 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-09 18:34:33 +00:00
Jannis Leidel 8258fe7845 Fixed #16042 -- Use the content types caching in the comments contrib app. Thanks, ptone, Julien Phalip and Thejaswi Puthraya.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16737 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-09 18:34:24 +00:00
Alex Gaynor d036b87126 Remove no-longer-valid references to the DATABASE_* settings, the legacy code for them was already removed.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16733 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-09 17:14:47 +00:00
Jacob Kaplan-Moss 4584069c8a Fixed #16746 - added more HTTP code/string mappings.
This moves the arbitrary line on which HTTP codes to include away from
RFC 2616 and to the IANA assignments, thus picking up WebDAV and a couple
others.

Thanks to vfaronov for the patch.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16732 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-09 16:57:35 +00:00
Jannis Leidel ddaca29d3d Fixed a bunch of imports of the email stdlib module now that we are on Python 2.5 to ease the Python 3 port. Thanks, Martin von Löwis.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16731 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-09 16:18:38 +00:00
Jannis Leidel 387e192f25 Fixed #16721 -- Made sure that blocktrans correctly handles percents (%), even in the plural block. Thanks for the initial patch, Claude Paroz.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16730 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-08 13:25:41 +00:00
Jannis Leidel 7cb140e6d8 Fixed #16003 -- Restored compatibility of the admin when using USE_ETAGS. Thanks for the initial patch, pterk.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16729 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-08 13:25:31 +00:00
Jannis Leidel 944ef3bb60 Fixed #16404 -- Fixed a regression in the localization changes in the humanize app made in r16168. Thanks, grepsd@gmail.com.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16726 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-08 13:25:11 +00:00
Jannis Leidel cf70c96ce0 Fixed #15997 -- Added `list_max_show_all` option to `ModelAdmin` in replacement for a global module level variable. Thanks, jsdalton.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16725 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-08 13:25:00 +00:00
Jannis Leidel 414c762c3a Fixed #16349 -- Fixed Brazilian localization formats. Thanks, Claude Paroz, semente and Guiljerme Gondim.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16724 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-08 13:24:49 +00:00
Jannis Leidel 16bb9c594c Fixed #16516 -- Relaxed the blocktrans rendering a little by falling back to the default language if resolving one of the arguments fails, raising a KeyError. Thanks, Claude Paroz and Aymeric Augustin.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16723 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-08 13:24:41 +00:00
Ramiro Morales 2b4341d532 Also copy `__module__` to our dynamically created TestCase subclass when override_settings acts as a class decorator.
Otherwise, an error in e.g. a test in tests/modeltests/proxy_model_inheritance/tests.py
was being reported as:

ERROR: test_table_exists (django.test.utils.ProxyModelInheritanceTests)

Refs #16672 and [16650].

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16722 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-04 22:51:53 +00:00
Alex Gaynor 9110257a32 `is` should not be used on primitive objects, use == instead, correctly.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16719 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-03 19:50:45 +00:00
Julien Phalip 09fc775f42 Fixed #16412 -- Prevented a `contrib.auth` test from failing in the potential case where `contrib.sites` was not installed. Thanks to haras for the report and to Aymeric Augustin for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16717 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-03 12:53:08 +00:00
Julien Phalip de35a3ab14 Fixed #16736 -- Enabled the merging of user-supplied arguments to format the error emails' subject in `AdminEmailHandler`.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16715 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-09-02 03:04:02 +00:00
Julien Phalip 71f017b2a6 Fixed #16059 -- Improved the usability of the admin's vertical and horizontal "filter" widgets, in particular by providing a better visual representation of the buttons' enabled and disabled states, and by providing more elaborate, yet less cluttered, help texts.
Note that this commit is an exception to the current tacit rule that javascript code changes should be avoided until a proper javascript testing framework for Django core is in place. This exception is commanded by the fact that it is to fix a recognized usability issue and that the patch has been (manually) extensively tested in IE6+, Chrome, Safari, Firefox and Opera.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16714 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-08-31 08:07:07 +00:00
Jannis Leidel 3a2e15abd9 Fixed indentation introduced in r16706.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16713 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-08-30 12:11:09 +00:00
Jannis Leidel 3256862f5f Fixed #16717 -- Added ability to store result of trans template tag in context variable.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16712 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-08-30 12:09:45 +00:00
Honza Král 93f92635b6 Follow the same convention as the rest of the file.
Still cleanup after [16708]

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16710 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-08-29 23:01:25 +00:00
Honza Král 0037ca44d6 Forgotten import in [16708]
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16709 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-08-29 17:28:15 +00:00
Honza Král 7c657b2416 Fixed #15802 -- pyscopg2 sometimes fail to close the connection when it's already closed by the server, Thanks Rick van Hattem
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16708 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-08-29 15:55:06 +00:00
Julien Phalip 6757568bfa Fixed #16202 -- Added a Slovenian localflavor. Thanks to Jure Cuhalev < gandalf@owca.info>, Gasper Zejn and Domen Kozar for the patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16706 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-08-28 13:51:28 +00:00
Julien Phalip 93fbb77d9b Fixed #16716 -- Fixed two small regressions in the development version introduced in r16144 where the changelist crashed with a 500 error instead of nicely operating a 302 redirection back to the changelist.
The two specific cases were:

* a lookup through a non-existing field and apparently spanning multiple relationships (e.g. "?nonexistant__whatever=xxxx").
* a proper list_filter's queryset failing with an exception. In Django 1.3 the queryset was only directly manipulated by the changelist, whereas in 1.4 the list_filters may manipulate the queryset themselves. The fix here implies catching potential failures from the list_filters too.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16705 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-08-28 07:57:56 +00:00
Chris Beaven 0f8f46802a Fixed #15525 -- Custom template tags loading breaks whenever templatetags is a python file
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16703 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-08-28 02:37:16 +00:00
Chris Beaven f85b96121a Fix a small thread safety issue in ExtendsNode. No tests, but Malcolm said that's ok, honest.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16700 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-08-27 04:55:02 +00:00
Julien Phalip 3e65f9633b Further improved on the work done in r16622 by making the help text icons look hoverable in the admin tabular inline headers.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16690 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-08-26 04:36:31 +00:00
Julien Phalip bf9ba45f6b Fixed #16677 -- Fixed the future version of the ssi template tag to work with template file names that contain spaces. Note that this fix cannot be applied to the currently deprecated version of the ssi tag since it requires an unquoted literal as parameter. Many thanks to Aymeric Augustin for the report and patch.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16687 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-08-25 23:02:15 +00:00
Julien Phalip 7e66ccac4c Fixed a small admin CSS issue where the "Save and continue editing" and "Save and add another" buttons were wrongly aligned with left-to-right languages in IE7.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@16683 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-08-25 08:01:21 +00:00
Malcolm Tredinnick 587fbff3dd Make ManyToManyField model references more robust.
In r16679 a test was added to verify something had been fixed when a
unicode string type was passed in as a model name. The name has to be
ASCII convertible, but in Python 2.6 and earlier, it must also have str
type.

This commit fixes the problem for earlier Python versions and is almost
identical to a patch from b.leskes in #6045.

Fixes #16689. Refs #6045.

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16682 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-08-25 06:07:28 +00:00
Malcolm Tredinnick 20473057d1 Modify validity check from r16678 slightly to work with Oracle.
We now skip this particular check on Oracle backends. Change is based on
a backend feature check, so it also works with other backends that may
treat NULL as equal to an empty string.

Fixes #16694 (with luck).

git-svn-id: http://code.djangoproject.com/svn/django/trunk@16681 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2011-08-25 05:44:18 +00:00