Alex Gaynor
1dafb9ad6c
[soc2009/multidb] Resolved a number of strange merge conflicts that had arisen throughout various merges.
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11777 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-11-23 16:46:07 +00:00
Alex Gaynor
4e36fffab2
[soc2009/multidb] Renaming of database attributes - you now use NAME, ENGINE, etc rather than DATABASE_NAME, DATABASE_ENGINE inside DATABASES. Also deprecates the use of short names (.e.g., `sqlite3` for backends in ENGINE). Patch from Russell Keith-Magee.
...
Conflicts:
docs/releases/1.2.txt
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11775 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-11-23 16:45:41 +00:00
Alex Gaynor
3e6ae729bc
[soc2009/multidb] Added test cases for cross-database assignment. Patch from Russell Keith-Magee.
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11774 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-11-23 16:44:47 +00:00
Alex Gaynor
ca0698553e
[soc2009/multidb] Cleaned up check in aggregation_regress to remove the assumption that the only objects in __dict__ are field attributes. Patch from Russell Keith-Magee.
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11773 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-11-23 16:44:38 +00:00
Alex Gaynor
da909ae3a0
[soc2009/multidb] Made instances sticky to the database that created them.
...
This involves:
* Adding a _state attribute to instances to track instance state
* Making db a state attribute, and making the db a public attribute on querysets.
Patch from Russell Keith-Magee.
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11769 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-11-23 16:43:54 +00:00
Alex Gaynor
f2604c331d
[soc2009/multidb] Updated testing services to handle multiple databases better. Includes extra tests (some failing) for multiple database support. Patch from Russell Keith-Magee.
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11764 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-11-23 16:42:56 +00:00
Alex Gaynor
1fc8f9a279
[soc2009/multidb] Merged up to trunk r11760.
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11762 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-11-23 14:25:44 +00:00
Alex Gaynor
4f40925785
[soc2009/multidb] Split SQL construction into two seperate classes, the Query class which stores data about a query being constructed, and a Compiler class which generates SQL.
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11759 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-11-21 07:03:40 +00:00
Alex Gaynor
e9e73c4b68
[soc2009/multidb] Merged up to trunk r11756.
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11758 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-11-21 06:55:11 +00:00
Alex Gaynor
2bc7422b52
[soc2009/multidb] Updated to trunk r11603. This includes a critical security fix.
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11614 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-10-09 22:16:10 +00:00
Alex Gaynor
0d62f50271
[soc2009/multidb] Added tests for using foreign keys across multipled databases, ManyToMany tests will come after the merger of my many-to-many refactor work.
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11425 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-08-09 22:03:24 +00:00
Alex Gaynor
fde0bfe929
[soc2009/multidb] Fix the extra_regress tests to be more forward compatible.
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11422 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-08-09 02:55:45 +00:00
Alex Gaynor
2231e64115
[soc2009/multidb] Fixed some exceptionally weird merging that git did. Bad git.
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11408 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-08-06 00:48:45 +00:00
Alex Gaynor
b7b5493fc3
[soc2009/multidb] Fix the remaining tests that were depending on the out of date setting.
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11407 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-08-06 00:46:53 +00:00
Alex Gaynor
8ad4ea7b04
[soc2009/multidb] Fix a number of tests that were looking at settings.DATABASE_ENGINE, which has been deprecated in favor of the DATABASES interface
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11406 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-08-06 00:27:53 +00:00
Alex Gaynor
e2fecde4a9
[soc2009/multidb] Removed several tests that were no longer needed as they're tested elsehwere
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11405 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-08-05 21:49:24 +00:00
Alex Gaynor
3cd611b89c
[soc2009/multidb] Switched from using an ugly hacky wrapper to a Metaclass for maitaing backwards compatibility in the get_db_prep_* and db_type methods. Thanks to Jacob for the good idea.
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11375 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-08-01 05:26:02 +00:00
Alex Gaynor
1a98f6ff26
[soc2009/multidb] Updated to trunk r11371.
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11373 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-07-31 18:29:06 +00:00
Alex Gaynor
ac74fa7e32
[soc2009/multidb] Correctly handle pickling of Query objects, restoring them to the correct database.
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11274 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-07-20 18:52:47 +00:00
Alex Gaynor
502d4982c9
[soc2009/multidb] Raise an exception at an attempt to do a subquery with 2 different databases. Eventually we'll just evaluate the 2 queries seperates.
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11273 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-07-19 21:57:08 +00:00
Alex Gaynor
8395544774
[soc2009/multidb] Added connection parameter to the get_db_prep_* family of functions. This allows us to generate the lookup and save values for Fields in a backend specific manner.
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11264 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-07-17 15:57:43 +00:00
Alex Gaynor
24b66ace9d
[soc2009/multidb] Merged up to trunk r11251.
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11252 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-07-16 23:13:49 +00:00
Alex Gaynor
08ab082480
[soc2009/multidb] Merged up to trunk r11240.
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11247 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-07-16 03:02:08 +00:00
Alex Gaynor
94e002c6e4
[soc2009/multidb] Merged up to trunk r11205
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11209 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-07-09 17:45:59 +00:00
Alex Gaynor
5d462b9ec1
[soc2009/multidb] Added a using option to a Model's Meta class. This allows you to select the default database for a specific model, in addition to the global default
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11135 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-07-01 05:01:59 +00:00
Alex Gaynor
2ab1840a9d
[soc2009/multidb] Merged up to trunk r11127
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11133 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-07-01 04:20:38 +00:00
Alex Gaynor
b4e069fab4
[soc2009/multidb] Fixed running the admin_scripts tests under sqlite without having DATABASE_NAME set
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11078 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-06-19 01:09:21 +00:00
Alex Gaynor
903ff126b0
[soc2009/multidb] Added tests to ensure that objects aren't being created before they are supposed to be, which would indicate we weren't creating objects in the right DB.
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11076 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-06-19 00:29:18 +00:00
Alex Gaynor
4f461542b5
[soc2009/multidb] Ensure that when a QuerySet is given a Query object in its construct that we correct the detect the connection that is being used
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11073 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-06-18 17:31:36 +00:00
Alex Gaynor
bc3cd5d952
[soc2009/multidb] Merged up to trunk r11068
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11071 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-06-18 17:03:52 +00:00
Alex Gaynor
f6db1dd357
[soc2009/multidb] Merged up to trunk r11009
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@11011 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-06-16 01:36:05 +00:00
Alex Gaynor
83df1f1056
[soc2009/multidb] Merged up to trunk r10973. Resolved merge conflicts
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@10978 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-06-10 23:30:30 +00:00
Alex Gaynor
1653ffb571
[soc2009/multidb] Updated DateQuery to work correctly with multiple databases
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@10943 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-06-07 23:56:42 +00:00
Alex Gaynor
f57bc92842
[soc2009/multidb] Merged upto trunk r10941
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@10942 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-06-07 23:42:26 +00:00
Alex Gaynor
4d6c6d0596
[soc2009/multidb] Fixed the usage of the connection during Query construction, and defer it until actual SQL construction. In practice this means the GROUP BY optimization we do will be correctly applied based on the connection the Query is executed against, as oppossed to the on the QuerySet is targeting at the time the GROUP BY items are added
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@10934 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-06-06 19:38:29 +00:00
Alex Gaynor
6aca03c24d
[soc2009/multidb] Merged up to trunk r10931. Resolved the slight merge conflict
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@10933 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-06-06 18:01:43 +00:00
Alex Gaynor
91520ec364
[soc2009/multidb] Made filter SQL generation lazy when we aren't filtering on a specific field, also added additional tests
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@10923 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-06-04 16:53:45 +00:00
Alex Gaynor
fbb6fda5f6
[soc2009/multidb] Fixed the usage of using() on QuerySets in conjuction with create(), added tests for this
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@10922 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-06-04 16:13:14 +00:00
Alex Gaynor
2f2cfac142
[soc2009/multidb] Merged multidb up to trunk r10914
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@10917 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-06-03 19:13:11 +00:00
Alex Gaynor
23da5c0ac1
[soc2009/multidb] Bring this branch up to date with my external work. This means implementing the using method on querysets as well as a using kwarg on save and delete, plus many internal changes to facilitae this
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@10904 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-06-03 02:37:33 +00:00
Alex Gaynor
9286db5145
[soc2009/multidb] Updated the test runner to support syncing all the databases django knows about so that tests can operate against more than one database
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@10895 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-06-03 02:13:01 +00:00
Alex Gaynor
bce55b1aa8
[soc2009/multidb] Implemented a connections object that is responsible for tracking multiple database connections and lazily instantiating them. Also implemneted the DATABASES setting which replaces the various DATABASE_* settings
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@10892 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-06-03 01:58:33 +00:00
Alex Gaynor
4cd29f2520
[soc2009/multidb] Merged up to trunk r10865
...
git-svn-id: http://code.djangoproject.com/svn/django/branches/soc2009/multidb@10887 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-06-02 02:46:02 +00:00
Russell Keith-Magee
4567b44909
Modified a test from r10787 so that the comparison order is reliable. Thanks to Alex Gaynor and Tom Tobin for the report via IRC.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10828 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-05-20 00:19:13 +00:00
Karen Tracey
8c8625bde3
Fixed #11149 -- Don't call save_form_data on file-type fields multiple times when saving a model form.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10826 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-05-19 23:13:33 +00:00
Karen Tracey
50745cc31e
Fixed #11066 -- Corrected 15 duplicate "the"s found in docs and code comments. Thanks kaikuehne.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10801 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-05-17 16:45:28 +00:00
Matt Boersma
56f3ed7f54
Fixed import statement in admin_views test to work with Python 2.3.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10789 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-05-15 15:01:40 +00:00
Russell Keith-Magee
a00be66311
Fixed #11120 -- Corrected handling of inlines attached to inherited classes, broken by r10756. Thanks to George Song and Michael Strickland for the simultaneous reports.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10787 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-05-15 12:44:51 +00:00
James Bennett
bcb0d124b4
Corrected tests from [10784]; instead of retrieving two comments, it was retrieving one comment twice.
...
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10785 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-05-15 02:54:55 +00:00
Jacob Kaplan-Moss
d246401552
Fixed #11113 : fixed a couple of issues that slipped through the cracks when comment moderation was added to django.contrib.comments.
...
The is a potentially backwards-incompatible change for users already relying on the internals of comment moderaration. To wit:
* The moderation system now listens to the new `comment_will_be_posted`/`comment_was_posted` signals instead of `pre/post_save`. This means that import request-based information is available to moderation as it should be.
* Some experimental code from `django.contrib.comments.moderation` has been removed. It was never intended to be merged into Django, and was completely untested and likely buggy.
git-svn-id: http://code.djangoproject.com/svn/django/trunk@10784 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2009-05-14 15:20:50 +00:00