Fixed #61 : SheerkaDebugManager: Add get_value()

Fixed #60 : Hash error when ReturnValue is a list of list
Fixed #59 : Implement smart_get()
Fixed #58 : SheerkaPromptCompleter: Cannot parse concept token
Fixed #57 : SheerkaPrompt: Add concept autocompletion
Fixed #56 : automatically backup command
Fixed #54 : I can record execution status
Fixed #53 : ConceptManager: modify_concept fails
This commit is contained in:
2021-04-09 15:47:32 +02:00
parent 6cda2686fb
commit dd3d8f4abe
37 changed files with 1055 additions and 191 deletions
+4
View File
@@ -53,6 +53,7 @@ class Expando:
@dataclass
class PythonEvalError:
error: Exception
source: str
traceback: str = field(repr=False)
concepts: dict = field(repr=False)
@@ -64,6 +65,7 @@ class PythonEvalError:
return False
return isinstance(self.error, type(other.error)) and \
self.source == other.source and \
self.traceback == other.traceback and \
self.concepts == other.concepts
@@ -151,10 +153,12 @@ class PythonEvaluator(OneReturnValueEvaluator):
if concepts_entries is None:
concepts_entries = self.get_concepts_entries_from_globals(my_globals)
eval_error = PythonEvalError(ex,
node.source,
traceback.format_exc() if get_trace_back else None,
self.get_concepts_values_from_globals(globals_, concepts_entries))
errors.append(eval_error)
exception_debugger.debug_var("exception", eval_error.error, is_error=True)
exception_debugger.debug_var("source", eval_error.source, is_error=True)
exception_debugger.debug_var("trace", eval_error.traceback, is_error=True)
if evaluated == NotInit: