#33430: Calling command via `call_command` with option that is `required` and 
has
set `dest` leads to an error
-------------------------------------+-------------------------------------
     Reporter:  Adam Mičuda          |                    Owner:  ravi
                                     |  kunwar
         Type:  Bug                  |                   Status:  closed
    Component:  Core (Management     |                  Version:  3.2
  commands)                          |
     Severity:  Normal               |               Resolution:  invalid
     Keywords:                       |             Triage Stage:
                                     |  Unreviewed
    Has patch:  0                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  0
Easy pickings:  0                    |                    UI/UX:  0
-------------------------------------+-------------------------------------
Changes (by Mariusz Felisiak):

 * status:  assigned => closed
 * resolution:   => invalid


Comment:

 You should pass `dest` in `options` as
 [https://docs.djangoproject.com/en/dev/ref/django-admin/#running-
 management-commands-from-your-code documented]:

 > Some command options have different names when using `call_command()`
 instead of `django-admin` or `manage.py`. For example, `django-admin
 createsuperuser --no-input` translates to `call_command('createsuperuser',
 interactive=False)`. To find what keyword argument name to use for
 `call_command()`, check the command’s source code for the **`dest`**
 argument passed to `parser.add_argument()`.

-- 
Ticket URL: <https://code.djangoproject.com/ticket/33430#comment:3>
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 [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-updates/064.d63e2fcc4702a4f90e3d8ec3eea6ba82%40djangoproject.com.

Reply via email to