[issue26799] gdb support fails with "Invalid cast."

2016-04-21 Thread STINNER Victor
STINNER Victor added the comment: Great! -- ___ Python tracker ___ ___ Python-bugs-list mailing list

[issue26799] gdb support fails with "Invalid cast."

2016-04-21 Thread Thomas
Thomas added the comment: Thank you for the quick integration and fixing the return. I have signed the electronic form yesterday. -- ___ Python tracker

[issue26799] gdb support fails with "Invalid cast."

2016-04-20 Thread STINNER Victor
STINNER Victor added the comment: > The second option seems like the safest choice, attached is a patch that > addresses just that. Thanks, I applied your patch (your a bugfix, you forgot one "return" ;-)). I also inlined _type_void_ptr() into _sizeof_void_p(), since it was only called

[issue26799] gdb support fails with "Invalid cast."

2016-04-20 Thread Roundup Robot
Roundup Robot added the comment: New changeset e4561aad29e6 by Victor Stinner in branch '2.7': Fix python-gdb.py: get C types on demand https://hg.python.org/cpython/rev/e4561aad29e6 New changeset 952c89a10be6 by Victor Stinner in branch '3.5': Issue #26799: Fix typo in Misc/NEWS

[issue26799] gdb support fails with "Invalid cast."

2016-04-20 Thread Roundup Robot
Roundup Robot added the comment: New changeset e1c6f8895fd8 by Victor Stinner in branch '3.5': python-gdb.py: get C types at runtime https://hg.python.org/cpython/rev/e1c6f8895fd8 New changeset 6425728d8dc6 by Victor Stinner in branch 'default': Merge 3.5: Issue #26799

[issue26799] gdb support fails with "Invalid cast."

2016-04-20 Thread Thomas
Thomas added the comment: The second option seems like the safest choice, attached is a patch that addresses just that. -- keywords: +patch Added file: http://bugs.python.org/file42538/gdb-python-invalid-cast.patch ___ Python tracker

[issue26799] gdb support fails with "Invalid cast."

2016-04-19 Thread STINNER Victor
STINNER Victor added the comment: > Turns out the type->length of the the globally initialized ptr types is > wrong: It is 4 instead of 8, causing the cast to fail. I suspect the > initialization is done before the executable is loaded and gdb is using some > default. Hum. I see two options:

[issue26799] gdb support fails with "Invalid cast."

2016-04-19 Thread Thomas
Thomas added the comment: I have done a bit more digging, turns out it is actually no problem at all to debug python in gdb with gdb with python support (at least using a fixed python-gdb-py). Turns out the type->length of the the globally initialized ptr types is wrong: It is 4 instead of

[issue26799] gdb support fails with "Invalid cast."

2016-04-19 Thread STINNER Victor
STINNER Victor added the comment: I tried Python 3.6 with "./configure --with-pydebug --without-pymalloc --with-valgrind". The py-bt commands works as expect in gdb. Can you try to modify python-gdb.py to get a traceback of your Invalid cast error? > I am able to fix it with the following

[issue26799] gdb support fails with "Invalid cast."

2016-04-19 Thread SilentGhost
Changes by SilentGhost : -- nosy: +haypo ___ Python tracker ___ ___ Python-bugs-list

[issue26799] gdb support fails with "Invalid cast."

2016-04-18 Thread Thomas
New submission from Thomas: Trying to use any kind of python gdb integration results in the following error: (gdb) py-bt Traceback (most recent call first): Python Exception Invalid cast.: Error occurred in Python command: Invalid cast. I have tracked it down to the _type_... globals, and I