#31700: Highlight destructive operations in makemigrations output
-----------------------------+--------------------------------------
     Reporter:  Tom Forbes   |                    Owner:  nobody
         Type:  New feature  |                   Status:  new
    Component:  Migrations   |                  Version:  master
     Severity:  Normal       |               Resolution:
     Keywords:               |             Triage Stage:  Unreviewed
    Has patch:  0            |      Needs documentation:  0
  Needs tests:  0            |  Patch needs improvement:  0
Easy pickings:  0            |                    UI/UX:  0
-----------------------------+--------------------------------------
Description changed by Tom Forbes:

Old description:

> Makemigrations should highlight destructive and potentially destructive
> operations in the console output. We advise that makemigrations is only a
> code generator people sometimes apply them without looking. Highlighting
> dangerous operations in the output will make them stand out, and might
> help them notice issues before they blindly apply.
>
> For example:
>
> {{{
> $ ./manage.py makemigrations ...
> Migrations for 'some_app':
>   some_app/migrations/0002_delete.py
>     - Delete model SomeModel
>     + Add model AnotherModel
>     ~ Alter field X on Y
> }}}
>
> We can use `-` as a prefix for known destructive operations, `+` for
> "safe" operations and `~` for possibly-destructive operations, colour
> coded as green, red and yellow respectively.
>
> Mailing list discussion: https://groups.google.com/d/msg/django-
> developers/A0m8YkPKpZo/Yx8l2P8EAQAJ

New description:

 Makemigrations should highlight destructive and potentially destructive
 operations in the console output. We advise that makemigrations is only a
 code generator people sometimes apply them without looking. Highlighting
 dangerous operations in the output will make them stand out, and might
 help them notice issues before they blindly apply.

 For example:

 {{{
 $ ./manage.py makemigrations ...
 Migrations for 'some_app':
   some_app/migrations/0002_delete.py
     - Delete model SomeModel
     + Add model AnotherModel
     ~ Alter field X on Y
 }}}

 We can use `-` as a prefix for known destructive operations, `+` for
 "safe" operations and `~` for possibly-destructive operations, colour
 coded as red, green and yellow respectively.

 Mailing list discussion: https://groups.google.com/d/msg/django-
 developers/A0m8YkPKpZo/Yx8l2P8EAQAJ

--

-- 
Ticket URL: <https://code.djangoproject.com/ticket/31700#comment:1>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/061.0d656c675f3d2a4e3e394e36863ffe95%40djangoproject.com.

Reply via email to