DebugClients/Python/DebugClientBase.py

branch
5_3_x
changeset 2487
75ee609c3241
parent 2378
5fa59ceba7e1
child 2636
f3dd3c8d4aa4
equal deleted inserted replaced
2485:05b056d48e28 2487:75ee609c3241
1482 vlist = self.__formatVariablesList(dictkeys, dict, scope, filter, 1482 vlist = self.__formatVariablesList(dictkeys, dict, scope, filter,
1483 formatSequences) 1483 formatSequences)
1484 varlist.extend(vlist) 1484 varlist.extend(vlist)
1485 1485
1486 if obj is not None and not formatSequences: 1486 if obj is not None and not formatSequences:
1487 if unicode(repr(obj)).startswith('{'): 1487 try:
1488 varlist.append(('...', 'dict', "%d" % len(obj.keys()))) 1488 if unicode(repr(obj)).startswith('{'):
1489 elif unicode(repr(obj)).startswith('['): 1489 varlist.append(('...', 'dict', "%d" % len(obj.keys())))
1490 varlist.append(('...', 'list', "%d" % len(obj))) 1490 elif unicode(repr(obj)).startswith('['):
1491 elif unicode(repr(obj)).startswith('('): 1491 varlist.append(('...', 'list', "%d" % len(obj)))
1492 varlist.append(('...', 'tuple', "%d" % len(obj))) 1492 elif unicode(repr(obj)).startswith('('):
1493 varlist.append(('...', 'tuple', "%d" % len(obj)))
1494 except:
1495 pass
1493 1496
1494 self.write('%s%s\n' % (DebugProtocol.ResponseVariable, unicode(varlist))) 1497 self.write('%s%s\n' % (DebugProtocol.ResponseVariable, unicode(varlist)))
1495 1498
1496 def __formatQt4Variable(self, value, vtype): 1499 def __formatQt4Variable(self, value, vtype):
1497 """ 1500 """

eric ide

mercurial