#19593: Add flushing of stdout and stderr for the `manage.py runserver` 
management
command
-------------------------------------+-------------------------------------
     Reporter:  chroto24@…           |                    Owner:  nobody
         Type:  New feature          |                   Status:  closed
    Component:  Core (Management     |                  Version:  master
  commands)                          |               Resolution:  wontfix
     Severity:  Normal               |             Triage Stage:  Accepted
     Keywords:                       |      Needs documentation:  0
    Has patch:  1                    |  Patch needs improvement:  0
  Needs tests:  0                    |                    UI/UX:  0
Easy pickings:  0                    |
-------------------------------------+-------------------------------------

Comment (by lemuelf):

 Replying to [comment:1 akaariai]:
 > I am going to wontfix this - you can open the subprocess with 'python
 -u' if needed which should give the semantics wanted.


 Hi, akaariai.

 Just a note: (a long one :-)

 If I do:

 {{{
 $ python -u manage.py runserver
 }}}

 it spawns child python processes without the -u switch:

 {{{
 $ pgrep -fl python
 11968 python -u manage.py runserver
 11972 /Users/lemuelf/.virtualenvs/online_store/bin/python manage.py
 runserver
 }}}

 And if I try to directly run the child-most process, e.g.:

 {{{
 $ /Users/lemuelf/.virtualenvs/online_store/bin/python -u manage.py
 runserver
 }}}

 it still spawns a child python process without the -u switch:

 {{{
 $ pgrep -fL python
 10390 /Users/lemuelf/.virtualenvs/online_store/bin/python -u manage.py
 runserver
 10393 /Users/lemuelf/.virtualenvs/online_store/bin/python manage.py
 runserver
 }}}

 However, I find that setting the PYTHONUNBUFFERED env var works, like the
 following:

 {{{
 $ PYTHONUNBUFFERED=1 python manage.py runserver
 }}}

 Still wontfix?  PYTHONUNBUFFERED=1 is too unwieldy :-)

-- 
Ticket URL: <https://code.djangoproject.com/ticket/19593#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 post to this group, send email to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to