#30305: Feature to set the returncode of a django custom command
-----------------------------------------+------------------------
Reporter: stephanm | Owner: nobody
Type: Uncategorized | Status: new
Component: Uncategorized | Version: 2.1
Severity: Normal | Keywords:
Triage Stage: Unreviewed | Has patch: 0
Needs documentation: 0 | Needs tests: 0
Patch needs improvement: 0 | Easy pickings: 0
UI/UX: 0 |
-----------------------------------------+------------------------
In the docs:
https://docs.djangoproject.com/en/2.1/howto/custom-management-
commands/#django.core.management.BaseCommand.handle
I can see that the `handle()` function will return a string which goes to
stdout.
But I would like to set (supplementary) an integer returncode like its
done in `sys.exit()` see
https://docs.python.org/3/library/sys.html#sys.exit
I didn't find any "official" way to do this, perhaps this is a new
feature.
Thanks.
--
Ticket URL: <https://code.djangoproject.com/ticket/30305>
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 post to this group, send email to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/django-updates/051.8a694a9f18b7380670ec28f238e5697c%40djangoproject.com.
For more options, visit https://groups.google.com/d/optout.