[py-dev] Logging in the py library

Grig Gheorghiu grig at gheorghiu.net
Thu Jun 9 17:01:26 CEST 2005


Hi, Holger

--- holger krekel <hpk at trillke.net> wrote:

> Hi Grig, hi all, 
> 
> Ok, done that.  It's at 54 lines of code but i feel it's already 
> too convoluted.  You'll find the code in py/misc/trace.py and 
> py/misc/testing/test_trace.py shows some usages.  
> 
> The main missing piece involves thinking more about the dispatching
> (possibly based on partial keyword matches) and the actual 
> API / namespace organization, for example of where to offer 
> logging-module adapter functions.  
> 
> Please consider this trace.py experimental. But it hopefully
> gives a more concrete clue of the ideas.  Feedback or suggestions 
> very welcome (i think especially by using it a bit here and there
> we could gain insights/better approaches). 

I'm currently trying to wrap my tired brain around the trace module :-)
It's deceptively simple if you look just at the number of LOC. I'll
play with it and I'll try to use it in the py library, so that we can
eat our own dog food. This will be a good way of seeing what's still
needed etc. Anyway, thanks for putting this together, for me personally
it's a tutorial in using less obvious features of Python....

Grig



More information about the Pytest-dev mailing list