This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [patch][python] 0 of 5 - Frame filters and Wrappers


On 16/05/13 12:50, Joel Brobecker wrote:
> Hi Phil,
> 
>> This patch-series has been committed in its entirety.  Thank you for
>> the reviews, it is very much appreciated.  I have attached the
>> ChangeLog entries as merged for committing the patch.
> 
> There is something I noticed while using a debugger where the gdb
> modules cannot be found:
> 
>   (gdb) bt
>   Python Exception <type 'exceptions.ImportError'> No module named gdb.frames: 
> 
> This is because I am using a debugger where python module path relocation
> is not working for some reason I am yet to investigate. But this would
> happen to someone improperly installing GDB as well.  This can actually
> happen fairly often, because it's usual in emergency situations to just
> copy the gdb binary where you need it instead of the full blown install,
> knowingly letting go of the Python capabilities when you don't need them.

We can, I have no real opinion.  In a case of an error importing that
module, we can set a flag to turn frame filters off.  While I am
sympathetic, this scenario should never really happen if GDB was
compiled and installed with Python. (Well, obviously it did in your
scenario ;) But that's another bug).

But this I think is the tip of the iceberg with an improperly
installed Python GDB.  I suspect pretty-printing will also suffer
failures, and other automatically instantiated Python bits within GDB.

Anyway, I'll write a patch to be more fault tolerant if nobody else
objects or has a differing opinion.

Cheers,

Phil



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]