How do I use trace to generate coverage data in multi-threaded programs?

Noah noah at noah.org
Wed Dec 19 22:33:00 EST 2007


I'm trying to use the trace module to build coverage files for
a multi-threaded program.

    http://docs.python.org/lib/module-trace.html

I test my application using trace.py from the command-line like this:

    /usr/lib/python2.5/trace.py --missing --count --summary tools/
testall.py

When I examine the *.cover files that are generated after a test run
I do not see coverage information for the methods that were run
in a separate thread. How can I collect coverage information for
methods that only run in a separate thread (never in the main thread)?

Any tips?

--
Noah Spurrier



More information about the Python-list mailing list