summaryrefslogtreecommitdiff
path: root/django/db/migrations/questioner.py
AgeCommit message (Collapse)Author
2024-12-19Fixed #36016 -- Prevented traceback when quitting makemigrations with Ctrl-C.Aman Sharma
2024-11-18Fixed #35882 -- Made migration questioner loop on all errors.Adam Johnson
2022-02-07Refs #33476 -- Reformatted code with Black.django-bot
2022-01-03Refs #29026 -- Allowed customizing InteractiveMigrationQuestioner's prompt ↵Jacob Walls
destination. Previously, the questioner did not obey the value of stdout provided to the command.
2021-10-12Fixed #29470 -- Logged makemigrations automatic decisions in non-interactive ↵Jacob Walls
mode.
2021-10-11Refs #32900 -- Restored '[y/N]' in questioner prompt when merging migrations.Seonghyeon Cho
Regression in 02bc7161ec477afd4a7b328936eb8adac078d7b9.
2021-10-06Fixed #23408 -- Added migrations questioner prompt for adding unique fields ↵Jacob Walls
with a callable default.
2021-08-27Fixed #32900 -- Improved migrations questioner prompts.Mateo Radman
2021-02-10Fixed #32355 -- Dropped support for Python 3.6 and 3.7Mariusz Felisiak
2020-02-04Simplified imports from django.db and django.contrib.gis.db.Nick Pope
2018-10-09Capitalized "Python" in docs and comments.Jon Dufresne
2018-07-27Fixed #29595 -- Allowed using timedelta in migrations questioner.Tim Graham
Refs #29600 -- Removed usage of django.utils.datetime_safe in migrations.
2018-02-05Refs #28814 -- Fixed migrations crash with namespace packages on Python 3.7.Tim Graham
Due to https://bugs.python.org/issue32303.
2018-01-31Fixed #29091 -- Fixed makemigrations crash if migrations directory doesn't ↵Tim Graham
have __init__.py. Regression in aadd3aeb2ba3153e35bd805c80c901f289a6f333.
2017-12-04Fixed #28860 -- Removed unnecessary len() calls.Дилян Палаузов
2017-07-31Avoided creating temporary lists for obtaining the first item.Sergey Fedoseev
2017-06-28Fixed #27818 -- Replaced try/except/pass with contextlib.suppress().Mads Jensen
2017-02-28Refs #27656 -- Updated django.db docstring verbs according to PEP 257.Anton Samarchyan
2017-01-19Refs #23919 -- Stopped inheriting from object to define new style classes.Simon Charette
2017-01-18Refs #23919 -- Removed most of remaining six usageClaude Paroz
Thanks Tim Graham for the review.
2017-01-18Refs #23919 -- Removed six.PY2/PY3 usageClaude Paroz
Thanks Tim Graham for the review.
2017-01-18Refs #23919 -- Removed encoding preambles and future importsClaude Paroz
2016-08-30Fixed #25109 -- Stopped silencing explicitly specified migration modules ↵Simon Charette
import errors. Thanks Tim for the review.
2016-07-14Reverted "Fixed #25388 -- Added an option to allow disabling of migrations ↵Tim Graham
during test database creation" This reverts commit 157d7f1f1de4705daddebb77f21bd7097a74513d since it disables migrations all the time, not just during tests.
2016-05-09Fixed #25005 -- Made date and time fields with auto_now/auto_now_add use ↵Iacopo Spalletti
effective default. Thanks to Andriy Sokolovskiy for initial patch.
2016-04-03Fixed #26075 -- Added clearer wording for one-off values in makemigrationsSusan Tan
2016-04-03Fixed #26443 -- Corrected timezone.now in MigrationQuestioner promptIacopo Spalletti
2016-03-23Fixed #25388 -- Added an option to allow disabling of migrations during test ↵Berker Peksag
database creation
2016-01-25Fixed #26135 -- Adjusted the migration questioner's handling of disabled apps.Simon Charette
This was causing an issue when calling the `migrate` command in a test case with the `available_apps` attribute pointing to an application with migrations disabled using the `MIGRATION_MODULES` setting. Thanks to Tim Graham for the review. Refs #24919
2015-09-23Fixed #25453 -- Reworded makemigration's ask_not_null_alteration suggestion.Benjamin Wohlwend
2015-08-26Fixed #25308 -- Made MigrationQuestioner respect MIGRATION_MODULES setting.Jeremy Satterfield
2015-03-08Fixed #23407 -- Extended coverage of makemigrations --noinput option.Marten Kenbeek
Changed --noinput option in makemigrations to suppress all user prompts, not just when combined with --merge.
2014-10-29Limited lines to 119 characters in django/{contrib,db}.Berker Peksag
Refs #23395.
2014-10-09Fixed #23609 -- Fixed IntegrityError that prevented altering a NULL column ↵Markus Holtermann
into a NOT NULL one due to existing rows Thanks to Simon Charette, Loic Bistuer and Tim Graham for the review.
2014-09-29Fixed #23365 -- Added support for timezone-aware datetimes to migrations.Rudy Mutter
2014-05-24Fixed #22676 -- makemigrations --dry-run should not ask for defaultsMoayad Mardini
Made the fix in InteractiveMigrationQuestioner class code, rather than MigrationAutodetector, because --dry-run shouldn't affect whether MigrationAutodetector will detect non-nullable fields, but the questioner should skip the question and returns a None for default (since that won't be used anyway) if --dry-run is used.
2014-05-06Added a bunch of missing unicode_literalsClaude Paroz
Refs #22564.
2014-03-10Fixed #22239 -- Add auto detection of renamed modelsChris Beaven
2014-02-09Fixed #21868: Don't die when seeing py3 namespace packages for mig dirsAndrew Godwin
2014-01-19Fix unicode default input on py3Andrew Godwin
2014-01-16Fixed #21784: Correctly decode stdin input for migration defaultsAndrew Godwin
2013-12-27Created a constant for the migrations module name.Aymeric Augustin
Mostly for consistency with MODELS_MODULE_NAME; it's unlikely to change.
2013-12-24Renamed AppCache to Apps.Aymeric Augustin
Also renamed app_cache to apps and "app cache" to "app registry". Deprecated AppCache.app_cache_ready() in favor of Apps.ready().
2013-12-22Moved apps back in the toplevel django namespace.Aymeric Augustin
Reverted 4a56a93cc458e9ab4dcab95d9f5067d4975dd1a2.
2013-12-17Moved the new app cache inside core.Aymeric Augustin
2013-12-17Deprecated get_app().Aymeric Augustin
2013-12-17Removed module-level functions for the app cache.Aymeric Augustin
Since the original ones in django.db.models.loading were kept only for backwards compatibility, there's no need to recreate them. However, many internals of Django still relied on them. They were also imported in django.db.models. They never appear in the documentation, except a quick mention of get_models and get_app in the 1.2 release notes to document an edge case in GIS. I don't think that makes them a public API. This commit doesn't change the overall amount of global state but clarifies that it's tied to the app_cache object instead of hiding it behind half a dozen functions.
2013-12-17Moved django.db.models.loading to django.apps.cache.Aymeric Augustin
This commit doesn't contain any code changes; it's purely a refactoring.
2013-12-06Removed unreachable `else` in `try` block.maurycyp
2013-12-04Migration VCS conflict detection and --merge for makemigrationsAndrew Godwin