Piotr Jakimiak
4157c502a5
Removed unnecessary arguments in .get method calls
2015-05-13 20:51:18 +02:00
Claude Paroz
f61c4f490d
Fixed #24742 -- Made runserver.check_migrations ignore read-only databases
...
Thanks Luis Del Giudice for the report, and Aymeric Augustin and Markus
Holtermann for the reviews.
2015-05-13 18:30:36 +02:00
Abhaya Agarwal
9de9c24017
Fixed #24105 -- Called Storage.get_valid_name() when upload_to is callable
2015-05-12 20:08:22 -04:00
Andriy Sokolovskiy
f7b2978158
Fixed #24156 -- Fixed inherited related name of ManyToManyField.
...
Fixed situation when parent abstract model declares related_name='+',
and child models had an invalid queryset.
2015-05-12 19:14:55 -04:00
Anssi Kääriäinen
adc57632bc
Fixed #24748 -- Fixed incorrect GROUP BY on MySQL in some queries
...
When the query's model had a self-referential foreign key, the
compiler.get_group_by() code incorrectly used the self-referential
foreign key's column (for example parent_id) as GROUP BY clause
when it should have used the model's primary key column (id).
2015-05-11 11:42:27 -04:00
Anssi Kääriäinen
be9d645346
Fixed #24766 -- Added join promotion for Case expressions
2015-05-11 11:16:16 -04:00
Matt Robenolt
8a54526592
Removed redundant removal of hyphens in UUIDField.
2015-05-11 07:11:50 -04:00
Tim Graham
b99114f67f
Fixed #24758 -- Corrected Options.get_fields() docstring.
2015-05-08 13:18:48 -04:00
Pradeek
6123e6134f
Fixed #24708 -- Handled non-string values in GenericIPAddressField.to_python()
2015-05-06 07:03:31 -04:00
Anssi Kääriäinen
7b05d2fdae
Fixed #24752 -- query crash when reusing Case expressions
...
Case expressions weren't copied deep enough (self.cases list was
reused resulting in an error).
2015-05-05 11:38:12 -04:00
Milan Broum
95058606c8
Allowed using the sqlite3 backend as much as possible without _sqlite3.
...
The inner import was dropped during the reorganizing of the database
backends in commit 28308078f3
.
2015-05-04 12:59:59 -04:00
Luis Del Giudice
69ddc1b3da
Fixed #24693 -- Added label and label_lower property to Model._meta
2015-05-02 16:58:18 +02:00
Markus Holtermann
811d7870a5
Moved migration exception classes to shared module
...
Thanks Aymeric Augustin for the review.
2015-05-02 12:54:44 +02:00
Markus Holtermann
63f9b633f9
Fixed #24725 -- Allowed renaming of target models in ManyToMany relations
...
This is a regression caused by introducing rendered migration states in
1aa3e09c20
and the _meta refactoring in fb48eb0581
.
Thanks to Danilo Bargen for reporting the issue and Marten Kenbeek and
Tim Graham for triaging the bug and providing the initial test case.
2015-04-30 13:27:29 +02:00
Aric Coady
9c2d8cde77
Fixed #24719 -- Restored the ability to use interators as queryset related object filters.
2015-04-28 10:51:27 -04:00
Tim Graham
2d76b61dc2
Fixed #24649 -- Allowed using Avg aggregate on non-numeric field types.
2015-04-25 13:06:14 -04:00
Tim Graham
26996e2d55
Fixed #24499 -- Dropped support for PostGIS 1.5.
2015-04-25 12:21:16 -04:00
Markus Holtermann
faad6070ee
Fixed #24701 -- Converted model manager names to unicode in migrations
...
Thanks to Reto Aebersold for reporting the issue and Tim Graham and
Claude Paroz for the review.
2015-04-25 18:17:06 +02:00
Markus Holtermann
b93690c465
Fixed #24573 -- Considered new related models for reloading
...
Thanks tttomekkk for the report.
2015-04-21 11:35:45 +02:00
Matthew Wilkes
e4b7daec11
Refs #24354 -- Prevented repointing of relations on superclasses when migrating a subclass's name change
...
The issue was hidden on 1.8+ until #24573 due to a bug inside the model
reloading process.
Forwardport of patch from ae87ad005f
2015-04-21 11:28:38 +02:00
Marten Kenbeek
1a1f16d67d
Fixed #24591 -- Optimized cloning of ModelState objects.
...
Changed ModelState.clone() to create a shallow copy of self.fields
and self.managers.
2015-04-20 19:53:21 -04:00
Simon Charette
b44ed404c7
Fixed #24654 -- Based ordering circular references detection on columns.
...
Thanks to Elmar Bucher for the report and Tim for the review.
2015-04-20 15:49:58 -04:00
Jon Dufresne
b5e0eede40
Fixed #22394 -- Refactored built-in datetime lookups to transforms.
2015-04-20 15:11:11 -04:00
Marten Kenbeek
039d7881b4
Refs #24397 -- Sped up model reloading in ProjectState.
...
Created bulk_update() context manager on StateApps. Sped up unregistering
models in reload_models() by using this context mananger.
2015-04-20 14:42:23 -04:00
Curtis Maloney
14ecbd02a3
Removed cases of six.iter* wrapped in a list()
...
There's absolutely no advantage [and a mild performance hit] to using six.iter*
in these cases.
2015-04-18 23:29:29 +10:00
Claude Paroz
8097e54832
Fixed #23879 -- Allowed model migration skip based on feature/vendor
...
Thanks Carl Meyer for the report and review, and Tim Graham for the
review.
2015-04-18 15:17:49 +02:00
Claude Paroz
02260ea3f6
Fixed #24595 -- Prevented loss of null info in MySQL field alteration
...
Thanks Simon Percivall for the report, and Simon Charette and Tim
Graham for the reviews.
2015-04-17 10:25:15 +02:00
Anssi Kääriäinen
355c5edd93
Fixed #24605 -- Fixed incorrect reference to alias in subquery.
...
Thanks to charettes and priidukull for investigating the issue, and to
kurevin for the report.
2015-04-16 09:22:00 -04:00
Anssi Kääriäinen
fb5c7748da
Fixed #24615 -- ordering by expression not part of SELECT
...
Fixed queries where an expression was used in order_by() but the
expression wasn't in the query's select clause (for example the
expression could be masked by .values() call)
Thanks to Trac alias MattBlack85 for the report.
2015-04-16 09:40:47 +02:00
Alex Wilson
99d40c6f65
Fixed #24277 -- Added exception when dict used in QuerySet filtering
2015-04-14 13:28:53 -04:00
peterfarrell
f8e8853b51
Fixed #24637 -- Fixed database introspection with SQLite 3.8.9.
2015-04-14 11:29:59 -04:00
Jay Wineinger
923da0274a
Fixed #24611 -- Fixed update() crash with related UUID pk object.
2015-04-13 12:18:24 -04:00
Christopher Luc
a7bc00e17b
Fixed #24514 -- Made migration writer omit models import if it's unused.
2015-04-10 07:04:26 -04:00
Adam Chainz
9d0c600d8d
Fixed #24609 -- Made ConcatPair use CONCAT_WS() on MySQL
2015-04-09 10:17:27 -04:00
Tim Graham
a10b4c010a
Fixed #24578 -- Fixed crash with QuerySet.update() on FK to O2O fields.
...
Thanks Anssi Kääriäinen for review.
2015-04-09 06:50:21 -04:00
Patryk Zawadzki
0385dad073
Fixed #24513 -- Made sure a model is only rendered once during reloads
...
This also prevents state modifications from corrupting previous states.
Previously, when a model defining a relation was unregistered first,
clearing the cache would cause its related models' _meta to be cleared
and would result in the old models losing track of their relations.
2015-04-07 14:49:47 +02:00
Jon Dufresne
2cf58e80d1
Fixed #24584 -- Fixed microsecond handling with older MySQLdb
2015-04-06 22:43:51 +02:00
Marten Kenbeek
e8e4f978dd
Fixed #24278 -- Fixed serialization of migration operations.
...
Fixed MigrationWriter.serialize() to correctly handle migration
operations by utilizing OperationWriter.
Thanks Piotr Maliński for the report.
2015-04-05 20:26:21 +02:00
Marten Kenbeek
d597174bd4
Refs #24278 -- Allowed multi-line serializations in OperationWriter.
...
Changed OperationWriter to support multi-line serialized values with
correct indentation.
2015-04-05 20:19:24 +02:00
Alex Hill
07ba148d9e
Cleaned up use of context manager in SQLite schema editor
2015-04-03 09:13:55 -04:00
Baptiste Mispelon
30a3c2f74c
Fixed #24566 -- Added support for serializing timedelta
...
Thanks to knbk for the report.
2015-04-02 17:21:20 +02:00
Markus Holtermann
3e7d9d05ac
Refs #24554 -- Prevented rendering of unused migrations
...
Thanks Claude Paroz and Tim Graham for the review
2015-04-01 02:00:34 +02:00
Markus Holtermann
57dc8dd3fa
Fixed #24554 -- Sped up migrations by rendering initial apps when they are first needed
...
Calling Migration.mutate_state() now also allows to do in_place
mutations in case an intermediate state is thrown away later.
Thanks Anssi Kääriäinen for the idea, Ryan Hall for parts of the patch,
and Claude Paroz and Tim Graham for the review
2015-04-01 02:00:05 +02:00
Andriy Sokolovskiy
29b4a3f513
Removed duplicate attribute in MySQL DatabaseSchemaEditor.
2015-03-30 19:23:41 -04:00
Markus Holtermann
c5cc332bf2
Fixed #24550 -- Added migration operation description to sqlmigrate output
...
Thanks Tim Graham for the review.
2015-03-30 16:31:20 +02:00
Simon Charette
dc27f3ee0c
Fixed #19259 -- Added group by selected primary keys support.
2015-03-29 22:03:30 -04:00
Marten Kenbeek
75430be86f
Refs #24366 -- Fixed recursion depth error in migration graph
...
Made MigrationGraph forwards_plan() and backwards_plan() fall back to an
iterative approach in case the recursive approach exceeds the recursion
depth limit.
2015-03-29 16:08:07 +02:00
Marten Kenbeek
bc83add04c
Refs #24366 -- Renamed arguments in MigrationGraph, renamed tests
2015-03-29 16:07:58 +02:00
Markus Holtermann
c7ec3c07e7
Fixed #24537 -- Ignored field order in RenameModel detection
...
Thanks to David Sanders for the report and test and Simon Charette for
the review.
2015-03-28 20:45:15 +01:00
Marco Fucci
4ee08958f1
Fixed #24505 -- Fixed clash with hidden m2m fields.
...
Added support for multiple m2m fields with the same 'to' model
and with related_name set to '+'.
2015-03-26 19:00:37 -04:00