Having random python stack traces in the middle of your output really isn't helpful. Unless you are hacking on python pretty printers of course. For normal users the default really should be off. Some examples where it really doesn't make sense and is utterly confusing: PR12425 and PR12436 Leave the option there for people who want to hack on python pretty printers, but flip the default please.
CVSROOT: /cvs/src Module name: src Changes by: pmuldoon@sourceware.org 2011-07-11 13:07:38 Modified files: gdb : ChangeLog NEWS gdb/doc : ChangeLog gdb.texinfo gdb/python : python.c gdb/testsuite : ChangeLog gdb/testsuite/gdb.python: py-function.exp py-prettyprint.exp python.exp Log message: 2011-07-11 Phil Muldoon <pmuldoon@redhat.com> PR python/12438 * python/python.c: Set gdbpy_should_print_stack default to off. (set_python): Deprecate maint set python print-stack to class_deprecate. (_initialize_python): Deprecate maint set/show python print-stack. Add new prefix command, python. Add new setting, print-backtrace. * NEWS: Document set python print-stack. Document default change. 2011-07-11 Phil Muldoon <pmuldoon@redhat.com> PR python/12438 * gdb.texinfo (Python Commands): Add deprecate note to maint set/show python print-stack. Document set/show python print-backtrace. 2011-07-11 Phil Muldoon <pmuldoon@redhat.com> PR python/12438 * gdb.python/python.exp: Add maint set/show python print-stack deprecated tests. Add set/show python print-backtrace tests. Patches: http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/ChangeLog.diff?cvsroot=src&r1=1.13179&r2=1.13180 http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/NEWS.diff?cvsroot=src&r1=1.441&r2=1.442 http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/doc/ChangeLog.diff?cvsroot=src&r1=1.1197&r2=1.1198 http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/doc/gdb.texinfo.diff?cvsroot=src&r1=1.845&r2=1.846 http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/python/python.c.diff?cvsroot=src&r1=1.65&r2=1.66 http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/testsuite/ChangeLog.diff?cvsroot=src&r1=1.2787&r2=1.2788 http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/testsuite/gdb.python/py-function.exp.diff?cvsroot=src&r1=1.8&r2=1.9 http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/testsuite/gdb.python/py-prettyprint.exp.diff?cvsroot=src&r1=1.19&r2=1.20 http://sourceware.org/cgi-bin/cvsweb.cgi/src/gdb/testsuite/gdb.python/python.exp.diff?cvsroot=src&r1=1.22&r2=1.23
Thanks for the bug report. The fix is now in CVS and will be released in the next GDB release (7.4). If you see any regressions, or you do not think the bug is fixed, please reopen this PR. Cheers