Jean-Louis Fuchs
1ae2df6bfc
[1.8.x] Fixed #24447 -- Made migrations add FK constraints for existing columns
...
When altering from e.g. an IntegerField to a ForeignKey, Django didn't
add a constraint.
Backport of f4f0060fea
from master
2015-03-07 14:15:27 +01:00
Shai Berger
66d37e593c
[1.8.x] Fixed #24307 : Avoided redundant column nullability modifications on Oracle
...
Thanks Joris Benschop for the report, and Tim Graham for the tests.
Backport of ceadc94f09
from master
2015-02-19 02:44:08 +02:00
Tim Graham
a8b70d251d
[1.8.x] Sorted imports with isort; refs #23860 .
...
Backport of 0ed7d15563
from master
2015-02-09 14:24:06 -05:00
Markus Holtermann
c9addfd4bf
[1.8.x] Fixed small regression caused by e3702dc3f2
...
Since 1.7 models need to declare an explicit app_label if they are not
in an application in INSTALLED_APPS or were imported before their
application was loaded.
Backport of 235124d3ea
from master
2015-02-06 00:50:42 +01:00
Markus Holtermann
e3702dc3f2
[1.8.x] Cleaned up schema tests
...
Thanks Tim Graham for the review.
Backport of 0204714b0b
from master
2015-02-05 20:15:18 +01:00
Andriy Sokolovskiy
11a5e45b96
[1.8.x] Fixed #24104 -- Fixed check to look on field.many_to_many instead of class instance
...
Backport of 38c17871bb
from master
2015-01-22 18:53:47 +01:00
Markus Holtermann
20f1aafa14
[1.8.x] Refs #24163 -- Fixed failing Oracle test when migrating from ForeignKey to OneToOneField
...
Thanks Tim Graham for review
Backport of 64ecb3f07d
from master
2015-01-20 17:45:29 +01:00
Markus Holtermann
e55cb91bd4
[1.8.x] Fixed #24163 -- Removed unique constraint after index on MySQL
...
Thanks Łukasz Harasimowicz for the report.
Backport of 5792e6a88c
from master
2015-01-19 16:55:25 +01:00
Daniel Pyrathon
fb48eb0581
Fixed #12663 -- Formalized the Model._meta API for retrieving fields.
...
Thanks to Russell Keith-Magee for mentoring this Google Summer of
Code 2014 project and everyone else who helped with the patch!
2015-01-06 19:25:12 -05:00
Tim Graham
ab4f709da4
Fixed #23581 -- Prevented extraneous DROP DEFAULT statements.
...
Thanks john_scott for the report and Markus Holtermann for review.
2014-12-30 07:54:05 -05:00
Tim Graham
ac5f2a4ef7
Fixed refs #23987 test on Oracle.
2014-12-15 18:15:55 -05:00
Andriy Sokolovskiy
089047331d
Fixed #23987 -- Made SQLite SchemaEditor always use effective_default().
2014-12-15 13:40:24 -05:00
Jon Dufresne
4468c08d70
Fixed #23968 -- Replaced list comprehension with generators and dict comprehension
2014-12-08 07:58:23 -05:00
Tim Graham
765fa36d57
Fixed #23920 -- Fixed MySQL crash when adding blank=True to TextField.
...
Thanks wkornewald for the report and Markus Holtermann for review.
2014-12-04 10:57:10 -05:00
Veres Lajos
a71a2ea756
Fixed typos using https://github.com/vlajos/misspell_fixer
2014-11-03 20:59:30 -05:00
Markus Holtermann
715ccfde24
Fixed #23738 -- Allowed migrating from NULL to NOT NULL with the same default value
...
Thanks to Andrey Antukh for the report.
2014-10-31 13:30:30 -04:00
Tim Graham
92269b7b53
Fixed #23702 -- Fixed adding an explicit id field on SQLite.
...
Thanks gavinwahl for the report.
2014-10-23 12:24:34 -04:00
Markus Holtermann
f633ba778d
Fixed #23609 -- Fixed IntegrityError that prevented altering a NULL column into a NOT NULL one due to existing rows
...
Thanks to Simon Charette, Loic Bistuer and Tim Graham for the review.
2014-10-09 21:32:06 +07:00
Shai Berger
c1ae0621ba
Fixed #22738 -- made finer distinctions for when Boolean is not detected on Oracle
...
Thanks Claude Paroz for partial fix and Simon Charrette for review
2014-09-27 09:49:50 +03:00
Claude Paroz
dbdae3a755
Fixed #22738 -- Abstracted boolean field type introspection
...
Thanks maxi for the report, Shai Berger for his help with the patch
and Tim Graham for the review.
2014-09-26 20:03:44 +02:00
Sergey Fedoseev
83cd18633f
Fixed #23065 -- Quoted constraint names in SQL generated by migrations.
2014-09-23 09:25:31 -04:00
Tim Graham
e0cf030194
Removed unnecessary absolute_imports.
2014-08-25 10:07:14 -04:00
Shai Berger
56252e7f46
Fixed schema test for Oracle 11.2.0.1 which is used in Django Project's CI.
...
Refs #23073 Workaround.
Refs #22738 Repeats the mysql "offense". When the issue is solved, the
Oracle special case should be made to play with the solution (that is,
Oracle should be fixed the same way that mysql and the 3rd-party backneds
are).
2014-08-22 05:08:53 +03:00
Andrew Godwin
27b6f28435
Fixed #23264 : Schema backends honour db_constraint
2014-08-09 17:50:00 +10:00
Andrew Godwin
c06e124b5e
Fixed #23091 : CreateModel and AddField were clashing with deferred SQL
2014-08-04 11:59:29 +10:00
Andrew Godwin
7dacc6ae46
Fixed #23009 : Shorten FK identifiers in add_field and make consistent
2014-07-21 10:50:21 +01:00
Alex Gaynor
d015c9d11c
Fixed several flake8 errors
2014-06-18 07:47:13 -07:00
Andrew Godwin
61d7ae31cf
Fix test breakage on MySQL
2014-06-17 00:36:27 -07:00
Andrew Godwin
b22917bd50
Fixed #22851 : BinaryView wasn't getting a binary default
2014-06-16 18:44:08 -07:00
Tim Graham
82c935d44c
Renamed DatabaseFeature.supports_check_constraints to supports_column_check_constraints.
...
Thanks maxi for the suggestion.
2014-06-16 19:25:13 -04:00
Aymeric Augustin
b1432bfc22
Appeased flake8.
2014-05-08 21:49:54 +02:00
Andrew Godwin
b25aee3b7b
Fixed #22476 : Couldn't alter attributes on M2Ms with through= set
2014-05-08 10:34:24 -07:00
Andrew Godwin
e9a456d11b
Fixed #22581 : Pass default values for schema through get_db_prep_save()
2014-05-07 13:46:23 -07:00
Alex Gaynor
2bcb8bfc8d
Fix many many typos in comments throughout the codebase
2014-04-26 10:18:45 -07:00
Daniel Hahler
1edfa155e3
Fixed #22293 -- Avoided renaming many-to-many tables to themselves.
...
Fixed this for both implementations of _alter_many_to_many, instead of
in `alter_db_table` itself (more implementations).
2014-03-24 13:24:52 -04:00
Andrew Godwin
6b07804474
Fixed #22183 : Through M2Ms now correctly handled
2014-03-08 15:58:04 -08:00
Michael Manfre
3ffeb93186
Ensure cursors are closed when no longer needed.
...
This commit touchs various parts of the code base and test framework. Any
found usage of opening a cursor for the sake of initializing a connection
has been replaced with 'ensure_connection()'.
2014-02-02 12:47:21 -05:00
Simon Charette
3acdb3068a
Fixed a failing schema assertion.
...
BooleanFields are stored as TINYINT(1) on MySQL.
2014-01-25 10:59:38 -05:00
Andrew Godwin
2a30b39f40
Fixed #21783 : More SQLite default fun with nulls.
2014-01-25 00:10:25 +00:00
Shai Berger
056be4358d
Fixed two test failures under Oracle
2014-01-20 13:01:14 +02:00
Andrew Godwin
e802c97581
Fixed #21783 : Use defaults for adding NOT NULL on sqlite
2014-01-19 17:10:24 +00:00
Ramiro Morales
3518e9ec1f
Amend test table name so it doesn't clash.
...
Refs #21692 and 3efd1b8b93
.
2013-12-27 21:02:39 -03:00
Ramiro Morales
3efd1b8b93
Fixed #21692 -- Quote table name when creating it.
2013-12-27 18:43:52 -03:00
Aymeric Augustin
1716b7ce5a
Renamed AppCache to Apps.
...
Also renamed app_cache to apps and "app cache" to "app registry".
Deprecated AppCache.app_cache_ready() in favor of Apps.ready().
2013-12-24 12:25:17 +01:00
Aymeric Augustin
2fef9e5375
Moved apps back in the toplevel django namespace.
...
Reverted 4a56a93cc4
.
2013-12-22 11:39:55 +01:00
Aymeric Augustin
0242c56fd8
Deborgified the app cache.
...
Improved Andrew's hack to create temporary app caches to handle
migrations. Now the main app cache has a "master" flag set to True
(which is a non-default keyword argument, thus unlikely to be used by
mistake). Other app cache instances have "master" set to False.
The only sanctioned way to access the app cache is by importing
django.core.apps.app_cache.
If you were instanciating an app cache and relying on the Borg pattern,
you'll have to refactor your code.
2013-12-17 21:53:18 +01:00
Aymeric Augustin
4a56a93cc4
Moved the new app cache inside core.
2013-12-17 10:17:46 +01:00
Aymeric Augustin
860c2c8bc5
Moved django.db.models.loading to django.apps.cache.
...
This commit doesn't contain any code changes; it's purely a refactoring.
2013-12-17 10:17:43 +01:00
Andrew Godwin
5db028affb
Fix altering of SERIAL columns and InnoDB being picky about FK changes
2013-12-11 14:19:05 +00:00
Alex Gaynor
7349a22d29
flake8 fix
2013-11-25 09:21:25 -06:00