MCPcopy Create free account
hub / github.com/fabioz/PyDev.Debugger / InternalLoadFullValue

Class InternalLoadFullValue

_pydevd_bundle/pydevd_comm.py:1844–1878  ·  view source on GitHub ↗

Loads values asynchronously

Source from the content-addressed store, hash-verified

1842
1843
1844class InternalLoadFullValue(InternalThreadCommand):
1845 """
1846 Loads values asynchronously
1847 """
1848
1849 def __init__(self, seq, thread_id, frame_id, vars):
1850 self.sequence = seq
1851 self.thread_id = thread_id
1852 self.frame_id = frame_id
1853 self.vars = vars
1854
1855 @silence_warnings_decorator
1856 def do_it(self, dbg):
1857 """Starts a thread that will load values asynchronously"""
1858 try:
1859 var_objects = []
1860 for variable in self.vars:
1861 variable = variable.strip()
1862 if len(variable) > 0:
1863 if "\t" in variable: # there are attributes beyond scope
1864 scope, attrs = variable.split("\t", 1)
1865 name = attrs[0]
1866 else:
1867 scope, attrs = (variable, None)
1868 name = scope
1869 var_obj = pydevd_vars.getVariable(dbg, self.thread_id, self.frame_id, scope, attrs)
1870 var_objects.append((var_obj, name))
1871
1872 t = GetValueAsyncThreadDebug(dbg, dbg, self.sequence, var_objects)
1873 t.start()
1874 except:
1875 exc = get_exception_traceback_str()
1876 sys.stderr.write("%s\n" % (exc,))
1877 cmd = dbg.cmd_factory.make_error_message(self.sequence, "Error evaluating variable %s " % exc)
1878 dbg.writer.add_command(cmd)
1879
1880
1881class AbstractGetValueAsyncThread(PyDBDaemonThread):

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected