Opened 9 years ago
Last modified 3 years ago
#25684 closed New feature
Runserver doesn't use `LOGGING` configuration — at Initial Version
Reported by: | Flavio Curella | Owned by: | |
---|---|---|---|
Component: | Error reporting | Version: | dev |
Severity: | Normal | Keywords: | runserver logging |
Cc: | Triage Stage: | Accepted | |
Has patch: | yes | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
this is slightly related to https://code.djangoproject.com/ticket/25523
All output in core.servers.basehttp
(and possibly
fastcgi
- I haven't checked that yet) uses
sys.stderr.write
, bypassing the logging subsystem.
In order to have it use the LOGGING
settings, I can see 3 options:
a) make it always use logger.info(msg)
and change the default
LOGGING
settings appropriately
b) make it always use both sys.stdout.write
and
logger.info
c) add an option to runserver to switch behaviour
I'm willing to work on the patch (in fact, I have option 2) already working), I just need to know if this is something we want and what direction we want to go.