mirror of
https://github.com/hakril/PythonForWindows
synced 2026-06-08 14:31:45 +00:00
Some quick and dirty fix for debugger/breakpoint in python3
This commit is contained in:
@@ -108,11 +108,17 @@ class FunctionParamDumpBPAbstract(object):
|
||||
t = rt(value, cproc)
|
||||
else:
|
||||
t = rt(value)
|
||||
if not hasattr(t, "contents"):
|
||||
try:
|
||||
t = t.value
|
||||
except AttributeError:
|
||||
pass
|
||||
# Will fail in py3..
|
||||
content = None
|
||||
try:
|
||||
content = t.contents
|
||||
except Exception as e:
|
||||
# contents will fail on basic type
|
||||
# Not really an expected behavior
|
||||
# But it works for now.. (and since a while)
|
||||
pass
|
||||
if content is None:
|
||||
t = t.value
|
||||
res[name[1]] = t
|
||||
return res
|
||||
|
||||
|
||||
@@ -924,7 +924,7 @@ class Debugger(object):
|
||||
self.add_pending_breakpoint(bp, None)
|
||||
elif target is not None:
|
||||
# Check that targets are accepted
|
||||
if target not in self.processes.values() + self.threads.values():
|
||||
if target not in list(self.processes.values()) + list(self.threads.values()):
|
||||
# if target == self.target: # Original target (that have not been lauched yet)
|
||||
return self.add_pending_breakpoint(bp, target)
|
||||
# else:
|
||||
|
||||
Reference in New Issue
Block a user