mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
PY-18029 Remove obsolete todos and commented-out code from .py files
This commit is contained in:
@@ -255,7 +255,6 @@ class BaseInterpreterInterface:
|
||||
|
||||
def create_std_in(self, debugger=None, original_std_in=None):
|
||||
if debugger is None:
|
||||
# @alexander todo fix `StdIn.readline()`
|
||||
return StdIn(self, self.rpc_client, original_stdin=original_std_in)
|
||||
else:
|
||||
return DebugConsoleStdIn(dbg=debugger, original_stdin=original_std_in)
|
||||
@@ -499,10 +498,7 @@ class BaseInterpreterInterface:
|
||||
return pydevd_thrift.frame_vars_to_struct(self.get_namespace(), hidden_ns)
|
||||
|
||||
def getVariable(self, attributes):
|
||||
# @alexander todo replace xml with thrift object
|
||||
debug_values = []
|
||||
# xml = StringIO.StringIO()
|
||||
# xml.write("<xml>")
|
||||
val_dict = pydevd_vars.resolve_compound_var_object_fields(self.get_namespace(), attributes)
|
||||
if val_dict is None:
|
||||
val_dict = {}
|
||||
@@ -510,14 +506,9 @@ class BaseInterpreterInterface:
|
||||
keys = val_dict.keys()
|
||||
for k in keys:
|
||||
val = val_dict[k]
|
||||
# evaluate_full_value = pydevd_xml.should_evaluate_full_value(val)
|
||||
# xml.write(pydevd_vars.var_to_xml(val, k, evaluate_full_value=evaluate_full_value))
|
||||
evaluate_full_value = pydevd_thrift.should_evaluate_full_value(val)
|
||||
debug_values.append(pydevd_thrift.var_to_struct(val, k, evaluate_full_value=evaluate_full_value))
|
||||
|
||||
# xml.write("</xml>")
|
||||
#
|
||||
# return xml.getvalue()
|
||||
return debug_values
|
||||
|
||||
def getArray(self, attr, roffset, coffset, rows, cols, format):
|
||||
@@ -529,13 +520,7 @@ class BaseInterpreterInterface:
|
||||
def evaluate(self, expression):
|
||||
# returns `DebugValue` of evaluated expression
|
||||
|
||||
# @alexander todo replace xml with thrift object
|
||||
# xml = StringIO.StringIO()
|
||||
# xml.write("<xml>")
|
||||
result = pydevd_vars.eval_in_context(expression, self.get_namespace(), self.get_namespace())
|
||||
# xml.write(pydevd_vars.var_to_xml(result, expression))
|
||||
# xml.write("</xml>")
|
||||
# return xml.getvalue()
|
||||
return [pydevd_thrift.var_to_struct(result, expression)]
|
||||
|
||||
def do_get_completions(self, text, act_tok):
|
||||
|
||||
@@ -16,18 +16,6 @@ try:
|
||||
except:
|
||||
frame_type = None
|
||||
|
||||
## @alexander we do not need xml utility methods now
|
||||
# try:
|
||||
# from xml.sax.saxutils import escape
|
||||
#
|
||||
#
|
||||
# def make_valid_xml_value(s):
|
||||
# return escape(s, {'"': '"'})
|
||||
# except:
|
||||
# # Simple replacement if it's not there.
|
||||
# def make_valid_xml_value(s):
|
||||
# return s.replace('<', '<').replace('>', '>').replace('"', '"')
|
||||
|
||||
|
||||
class ExceptionOnEvaluate:
|
||||
def __init__(self, result):
|
||||
|
||||
@@ -878,7 +878,6 @@ def header_data_to_thrift_struct(rows, cols, dtypes, col_bounds, col_to_format,
|
||||
TYPE_TO_THRIFT_STRUCT_CONVERTERS = {"ndarray": array_to_thrift_struct, "DataFrame": dataframe_to_thrift_struct, "Series": dataframe_to_thrift_struct}
|
||||
|
||||
|
||||
# @alexander todo `GetArrayResponse` should be renamed to `ArrayChunk`
|
||||
def table_like_struct_to_thrift_struct(array, name, roffset, coffset, rows, cols, format):
|
||||
# returns `GetArrayResponse`
|
||||
_, type_name, _ = get_type(array)
|
||||
|
||||
Reference in New Issue
Block a user