This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author larry
Recipients dmalcolm, larry, pitrou, python-dev
Date 2013-11-24.14:03:54
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1385301834.81.0.68865442956.issue19743@psf.upfronthosting.co.za>
In-reply-to
Content
Here's what I've figured out.  If I build trunk then run:

% gdb --batch -iex "add-auto-load-safe-path /home/larry/src/python/buildtrunk/python-gdb.py" --eval-command="set breakpoint pending yes" --eval-command="break builtin_id" --eval-command=run --eval-command=backtrace --args /home/larry/src/python/buildtrunk/python -S -c "id([0, 1, 2, 3, 4])"

I see UnicodeDecodeErrors spat out in the middle of the traceback:

#0  builtin_id (self=<module at remote 0x7ffff7fbfc28>, v=[0, 1, 2, 3, 4]) at Python/bltinmodule
.c:991
#1  0x00000000004d8695 in call_function (oparg=<optimized out>, pp_stack=0x7fffffffdc00) at Pyth
on/ceval.c:4212
#2  PyEval_EvalFrameEx (f=f@entry=Frame 0x7ffff7f3e788, for file <string>, line 1, in <module> (
), throwflag=throwflag@entry=0) at Python/ceval.c:2826
Python Exception <class 'UnicodeDecodeError'> 'utf-8' codec can't decode byte 0x80 in position 0
: invalid start byte: 
Python Exception <class 'UnicodeDecodeError'> 'utf-8' codec can't decode byte 0x80 in position $: invalid start byte: 
#3  0x00000000004d9809 in PyEval_EvalCodeEx (closure=0x0, [...]

If I run the same sequence of commands manually (remove the --batch and the batched commands from the gdb command-line, then type them in myself) I still see the decode error.

If I then set a breakpoint on PyUnicodeDecodeError_Create() and run backtrace again, it still prints the decode errors, but it doesn't stop on the breakpoint.  (I guess this would be like getting to the assault on the ski chalet in Inception?)

Most worrisome of all: if I change the Makefile from -O3 to -O0, the decode errors go away.
History
Date User Action Args
2013-11-24 14:03:54larrysetrecipients: + larry, pitrou, dmalcolm, python-dev
2013-11-24 14:03:54larrysetmessageid: <1385301834.81.0.68865442956.issue19743@psf.upfronthosting.co.za>
2013-11-24 14:03:54larrylinkissue19743 messages
2013-11-24 14:03:54larrycreate