logging.debug

4 views
Skip to first unread message

Daniel Wong

unread,
Jun 23, 2010, 1:43:57 AM6/23/10
to app-engine-django
Hi,

This is a pretty simple question, so I hope the answer isn't too
obvious. If I do logging.info in my code, log messages show up in the
window where I have my server running. But when I do logging.debug, my
messages do not seem to show up. Is there some setting that I need to
adjust to make this happen?

Thanks,

Daniel

Andy Smith

unread,
Jun 23, 2010, 5:47:50 AM6/23/10
to app-engi...@googlegroups.com

At some point you need to set the logging level to debug, though I'd recommend not going further than info depending on which libraries you use. You need to set it after you import and apply the appengine_django stuff, somewhere like main.py.

> --
> You received this message because you are subscribed to the Google Groups "app-engine-django" group.
> To post to this group, send email to app-engi...@googlegroups.com.
> To unsubscribe from this group, send email to app-engine-dja...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/app-engine-django?hl=en.
>

Daniel Wong

unread,
Jun 23, 2010, 9:09:47 PM6/23/10
to app-engine-django
Thanks, Andy. Can you please give more specific directions? I really
don't know what you need to do in order to set the logging level to
debug. Your advice on where to edit main.py is also pretty vague.

On Jun 23, 2:47 am, Andy Smith <andys...@gmail.com> wrote:
> At some point you need to set the logging level to debug, though I'd
> recommend not going further than info depending on which libraries you use.
> You need to set it after you import and apply the appengine_django stuff,
> somewhere like main.py.
>
> On Jun 23, 2010 6:43 AM, "Daniel Wong" <allyourc...@gmail.com> wrote:> Hi,
>
> > This is a pretty simple question, so I hope the answer isn't too
> > obvious. If I do logging.info in my code, log messages show up in the
> > window where I have my server running. But when I do logging.debug, my
> > messages do not seem to show up. Is there some setting that I need to
> > adjust to make this happen?
>
> > Thanks,
>
> > Daniel
>
> > --
> > You received this message because you are subscribed to the Google Groups
>
> "app-engine-django" group.> To post to this group, send email to app-engi...@googlegroups.com.
> > To unsubscribe from this group, send email to
>
> app-engine-dja...@googlegroups.com<app-engine-django%2Bunsu...@googlegroups.com>
> .> For more options, visit this group at
>
> http://groups.google.com/group/app-engine-django?hl=en.
>
>

Andy Smith

unread,
Jun 23, 2010, 10:06:25 PM6/23/10
to app-engi...@googlegroups.com
set logging level like this:

logging.getLogger().setLevel(logging.DEBUG)

do it in the main() function in main.py

--andy

To unsubscribe from this group, send email to app-engine-dja...@googlegroups.com.

Daniel Wong

unread,
Jun 23, 2010, 10:15:22 PM6/23/10
to app-engine-django
Ah. Thanks, Andy.

Is there any reason I should not use debug level? You seemed to be
hinting at that in your first response.

On Jun 23, 7:06 pm, Andy Smith <andys...@gmail.com> wrote:
> set logging level like this:
>
> logging.getLogger().setLevel(logging.DEBUG)
>
> do it in the main() function in main.py
>
> --andy
>
> > <app-engine-django%2Bunsu...@googlegroups.com<app-engine-django%252Buns...@googlegroups.com>

Andy Smith

unread,
Jun 23, 2010, 11:27:37 PM6/23/10
to app-engi...@googlegroups.com
debug is usually stuff you don't want to see unless you are looking for a specific problem, where as info is stuff that doesn't matter but is informative, so i'd only turn on debug while i am looking for a problem and expect to get more information than i care about.

To unsubscribe from this group, send email to app-engine-dja...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages