﻿id	summary	reporter	owner	description	type	status	component	version	severity	resolution	keywords	cc	stage	has_patch	needs_docs	needs_tests	needs_better_patch	easy	ui_ux
32184	`manage.py migrate --noinput` should not delete stale modules	uy-rrodriguez	nobody	"When `manage.py migrate` is called with `--noinput` or `no-input`, it deletes stale modules by default. This is not documented in the official documentation (https://docs.djangoproject.com/en/2.2/ref/django-admin/#cmdoption-migrate-noinput) and it's a dangerous feature.

Other tickets have mentioned the addition of parameters like `--force` to force the deletion. I think either that approach or the use of other parameters should be preferred.

The ticket #25036 about deletion of stale content types was closed a long time ago without further comment, for which I assume the automatic deletion was discarded as dangerous.

The ticket #29556 about having `--no-input` in `remove_stale_contenttypes` automatically remove the stale content types was closed as fixed. I wonder whether the changes to fix that ticket affected the behaviour of the `migrate` command...

The tickets #29470 and #29026 comment about the output of the commands when `--no-input` is given. I think the output of `migrate` should list the stale elements without removing them.


''I'm recording this bug with a Django version of 2.2 because we cannot use a newer release (issues with other libraries). But, as I haven't found any mention about this specific issue in other places, and the documentation part has not been changed between 2.2 and 3.1, I think the bug is still present (or at least the documentation is not specific about it).''

Thank you for your time."	Bug	closed	Core (Management commands)	2.2	Normal	wontfix	migrate, no-input, noinput, management		Unreviewed	0	0	0	0	0	0
