Bug 158693 - UnicodeEncodeError is thrown when "Local varibles" card is tried to be opened.
UnicodeEncodeError is thrown when "Local varibles" card is tried to be opened.
Status: RESOLVED FIXED
Product: python
Classification: Unclassified
Component: Debugger
6.x
PC Linux
: P3 (vote)
: 8.1
Assigned To: vincentvdl
nbpythonqa
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2009-02-17 17:54 UTC by zielmicha
Modified: 2015-08-16 17:16 UTC (History)
0 users

See Also:
Issue Type: DEFECT
:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description zielmicha 2009-02-17 17:54:39 UTC
In case any local varible is non-ascii unicode strings (like u'\u0142' = u'ł') and "Local varibles" card is tried to be 
open, debug session finishes immediately and exception is thrown: 
['Traceback (most recent call last): 
', '  File "/home/michal/.netbeans/6.5/config/nbPython/debug/nbpythondebug/jpydaemon.py", line 393, in dealWithDebug 
    self.run(\'execfile(\' + `fullname` + \')\') 
', '  File "/usr/lib/python2.5/bdb.py", line 366, in run 
    exec cmd in globals, locals 
', '  File "<string>", line 1, in <module> 
', '  File "/home/michal/NetBeansProjects/small/src/youtube.py", line 44, in <module> 
    print list(getItems(u\'st\\xf3\\u0142\')) 
', '  File "/home/michal/NetBeansProjects/small/src/youtube.py", line 18, in getItems 
    root = xml.getRoot(data) 
', '  File "/home/michal/NetBeansProjects/small/src/youtube.py", line 18, in getItems 
    root = xml.getRoot(data) 
', '  File "/usr/lib/python2.5/bdb.py", line 48, in trace_dispatch 
    return self.dispatch_line(frame) 
', '  File "/usr/lib/python2.5/bdb.py", line 66, in dispatch_line 
    self.user_line(frame) 
', '  File "/home/michal/.netbeans/6.5/config/nbPython/debug/nbpythondebug/jpydaemon.py", line 139, in user_line 
    self.checkDbgAction( frame ) 
', '  File "/home/michal/.netbeans/6.5/config/nbPython/debug/nbpythondebug/jpydaemon.py", line 117, in checkDbgAction 
    while ( self._parseSubCommand( self._connection.receiveCommand() , frame ) == FREEZE ): 
', '  File "/home/michal/.netbeans/6.5/config/nbPython/debug/nbpythondebug/jpydaemon.py", line 681, in _parseSubCommand 
    self.variablesSubCommand( frame , verb , arg , LOCALS ) 
', '  File "/home/michal/.netbeans/6.5/config/nbPython/debug/nbpythondebug/jpydaemon.py", line 599, in 
variablesSubCommand 
    self.dealWithVariables( frame , verb , arg ) 
', '  File "/home/michal/.netbeans/6.5/config/nbPython/debug/nbpythondebug/jpydaemon.py", line 469, in 
dealWithVariables 
    xmlVariables.append(\'content="\'+ _utils.removeForXml(__builtin__.str(mapElement[1]))+\'" \') 
', "UnicodeEncodeError: 'ascii' codec can't encode characters in position 17-18: ordinal not in range(128) 
"]
Comment 1 Lou Dasaro 2015-04-28 16:24:22 UTC
Vincent, please take a look at this using the upgraded Jython. Thank you.


By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2014, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo