pdb question - spew out "steps" until crash needed

J

James Stroud

How do I get pdb to just run my program and spew out what's happening
until it crashes/freezes? (This is a malloc error in a library somewhere
and I can't figure out where--no exceptions thrown, etc.)

I think I might need to live a lot longer to simply hit 's' [enter]
until I get to the crash. Easiest would be run->spew->read last line.

James

--
James Stroud
UCLA-DOE Institute for Genomics and Proteomics
Box 951570
Los Angeles, CA 90095

http://www.jamesstroud.com/
 
P

Paul Rubin

James Stroud said:
How do I get pdb to just run my program and spew out what's happening
until it crashes/freezes? (This is a malloc error in a library
somewhere and I can't figure out where--no exceptions thrown, etc.)

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

However, the malloc problem has probably already screwed things up
long before the application actually freezes. Your best bet is
to recompile Python with malloc debugging enabled and/or run Python
itself under a debugger.
 
L

Lawrence D'Oliveiro

However, the malloc problem has probably already screwed things up
long before the application actually freezes. Your best bet is
to recompile Python with malloc debugging enabled and/or run Python
itself under a debugger.

A simple thing to try would be to invoke Python with MALLOC_CHECK_ set to 3.
This enables extra checking in the glibc malloc routine, which might help
shed some light on the problem.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

extension to list extend 2
WTF? 4
dict subclass and pickle bug (?) 4
3D Vector Type Line-Drawing Program 10
overloading *something 11
Module Importing Question 1
Importing to 0
Help text embedding in C code? 2

Members online

Forum statistics

Threads
473,755
Messages
2,569,536
Members
45,011
Latest member
AjaUqq1950

Latest Threads

Top