On Tue, Sep 29, 2009 at 6:29 PM, Simon Willison <si...@simonwillison.net> wrote: > [snip] > > By default, runserver would display no log messages at all.
Runserver currently outputs each request to the commandline. Any reason that couldn't be handled by a logger? I seem to recall people complaining that they couldn't redirect that output elsewhere before when logging discussions came up. [snip] > > My philosophy here is that log messages should be ignored unless > explicitly told otherwise. Django gets run in various different ways - > runserver, test and in deployment under mod_wsgi/FastCGI/etc - and > it's not at all obvious what the default log output behaviour should > be. As long as we make it extremely easy to see log messages if we > want them I think having them off by default makes sense. It also > ensures no surprises for people upgrading from 1.1 to 1.2. Yeah, this was an issue we ran into. People will deploy your code in all sorts of situations and you can't make any assumptions about what would constitute an appropriate handler. They have to define those themselves. Even management commands can be called from scripts and may need output to be logged someplace other than sdterr. > 4. Add a way to configure loggers in Django's settings.py file, in > particular for use in production. I'm not sure if these settings > should be ignored when running under other circumstances (./manage.py > test etc) in favour of the command line option, or if they should > still take effect. Well, a logger can have multiple handlers. I would think we would want to leave the handlers defined in settings.py in tact and add the manage.py handler (most likely output to stderr - but could be different - see my comment above). -- ---- \X/ /-\ `/ |_ /-\ |\| Waylan Limberg --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django developers" group. To post to this group, send email to django-developers@googlegroups.com To unsubscribe from this group, send email to django-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-developers?hl=en -~----------~----~----~----~------~----~------~--~---