From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 2573 invoked by alias); 8 Jul 2008 04:12:01 -0000 Received: (qmail 2563 invoked by uid 22791); 8 Jul 2008 04:12:00 -0000 X-Spam-Check-By: sourceware.org Received: from igw1.br.ibm.com (HELO igw1.br.ibm.com) (32.104.18.24) by sourceware.org (qpsmtpd/0.31) with ESMTP; Tue, 08 Jul 2008 04:11:39 +0000 Received: from mailhub1.br.ibm.com (mailhub1 [9.18.232.109]) by igw1.br.ibm.com (Postfix) with ESMTP id 2FB4A32C080 for ; Tue, 8 Jul 2008 00:44:39 -0300 (BRT) Received: from d24av01.br.ibm.com (d24av01.br.ibm.com [9.18.232.46]) by mailhub1.br.ibm.com (8.13.8/8.13.8/NCO v9.0) with ESMTP id m684BeLv2322644 for ; Tue, 8 Jul 2008 01:11:40 -0300 Received: from d24av01.br.ibm.com (loopback [127.0.0.1]) by d24av01.br.ibm.com (8.12.11.20060308/8.13.3) with ESMTP id m684BZf1017887 for ; Tue, 8 Jul 2008 01:11:35 -0300 Received: from [9.8.0.156] ([9.8.0.156]) by d24av01.br.ibm.com (8.12.11.20060308/8.12.11) with ESMTP id m684BZbi017551; Tue, 8 Jul 2008 01:11:35 -0300 Subject: Re: [RFC][patch 1/9] initial Python support From: Thiago Jung Bauermann To: tromey@redhat.com Cc: thiagoju@linux.ibm.com, Daniel Jacobowitz , gdb-patches@sourceware.org In-Reply-To: References: <20080429155212.444237503@br.ibm.com> <20080429155304.288626880@br.ibm.com> <20080528205921.GA2969@caradoc.them.org> <20080615181833.uxmo25mg0kko40kw@imap.linux.ibm.com> Content-Type: text/plain Date: Tue, 08 Jul 2008 04:12:00 -0000 Message-Id: <1215490251.1795.67.camel@localhost.localdomain> Mime-Version: 1.0 X-Mailer: Evolution 2.22.2 Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2008-07/txt/msg00111.txt.bz2 On Sun, 2008-07-06 at 11:27 -0600, Tom Tromey wrote: > >>>>> "Tom" == Tom Tromey writes: > > >>> > + if (PyErr_Occurred ()) > >>> > + { > >>> > + PyErr_Print (); > >>> > + error ("error while executing Python code"); > >>> > + } > >>> > +} > > Thiago> This is stillpending, I think. > > FYI -- I fixed this today. I added a new 'maint set python-stack' > variable that controls whether Python stack traces are printed. By > default they are. I changed all the new code to use a new > gdbpy_print_stack which checks this variable. Finally, I set things > up so that gdb overrides Python's sys.stdout and sys.stderr to print > things using printf_filtered. Awesome! This means that there are only three things pending for this patch to go in: 1. I'd like someone to verify if my call to bpstat_do_actions in execute_gdb_command is needed and if I implemented it correctly (I'm not sure I knew what I was doing, I just wanted something there so I could post the patch). 2. Testcases 3. Documentation (both user and internal) I can work on the last two items, but I'd like input on the first. After these are resolved I'll post a refreshed patch to the list. -- []'s Thiago Jung Bauermann Software Engineer IBM Linux Technology Center