Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #36786

Re: Making a logging handler that produces context.

Path csiph.com!newsfeed.hal-mli.net!feeder3.hal-mli.net!newsfeed.hal-mli.net!feeder1.hal-mli.net!newsfeed.xs4all.nl!newsfeed4.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail
Return-Path <antoon.pardon@rece.vub.ac.be>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.012
X-Spam-Evidence '*H*': 0.98; '*S*': 0.00; 'handler': 0.04; 'method.': 0.05; 'received:134': 0.05; 'reject': 0.05; 'correct.': 0.07; 'logic': 0.09; 'thrown': 0.09; '13:38,': 0.16; 'earlier': 0.21; 'seems': 0.23; 'header:In-Reply-To:1': 0.25; 'header:User- Agent:1': 0.26; 'see,': 0.27; 'turns': 0.33; 'handle': 0.33; 'problem': 0.33; 'to:addr:python-list': 0.33; 'done': 0.34; 'thanks': 0.34; 'filter': 0.35; 'but': 0.36; 'method': 0.36; 'too': 0.36; 'correctly': 0.37; 'level': 0.37; 'subject:: ': 0.38; 'to:addr:python.org': 0.39; 'records': 0.68; 'low': 0.83; 'otten': 0.84; 'pardon': 0.84; 'subject:Making': 0.84
X-IronPort-Anti-Spam-Filtered true
X-IronPort-Anti-Spam-Result AkgRAJwU9FCGuA9G/2dsb2JhbABEiQixFoN2gxIBBXgRCyEWDwkDAgECAUUTCAKIFa1ShwqOBYMpA5YLhViKcYJ2
Date Mon, 14 Jan 2013 15:26:03 +0100
From Antoon Pardon <antoon.pardon@rece.vub.ac.be>
User-Agent Mozilla/5.0 (X11; Linux i686; rv:10.0.11) Gecko/20121123 Icedove/10.0.11
MIME-Version 1.0
To python-list@python.org
Subject Re: Making a logging handler that produces context.
References <50F3E60D.2000503@rece.vub.ac.be> <kd0u6t$k6q$1@ger.gmane.org>
In-Reply-To <kd0u6t$k6q$1@ger.gmane.org>
Content-Type text/plain; charset=ISO-8859-1
Content-Transfer-Encoding 7bit
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.15
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <http://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list/>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <http://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.497.1358173566.2939.python-list@python.org> (permalink)
Lines 15
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1358173567 news.xs4all.nl 6946 [2001:888:2000:d::a6]:44664
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:36786

Show key headers only | View raw


Op 14-01-13 13:38, Peter Otten schreef:
> It turns out the logic of the above is correct. The problem is that the 
> handler has to see the INFO-level records while the filter() method has to 
> reject them. The following configuration seems to achieve that:

I see, I thought trowing away logrecords of too low a level was also
done by the filter method.
But if I now understand correctly logrecords of too low a level are
thrown away earlier and
don't even reach the handle method.

Thanks for the insight.

-- 
Antoon Pardon

Back to comp.lang.python | Previous | Next | Find similar | Unroll thread


Thread

Re: Making a logging handler that produces context. Antoon Pardon <antoon.pardon@rece.vub.ac.be> - 2013-01-14 15:26 +0100

csiph-web