New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
return value of InteractiveShell.run_cell and run_ast_nodes #7256
Comments
Are you doing something where some return value from |
Yes there is a use. The |
code ran successfully. I discussed this with Min, who suggested that given the complexity of run_cell, it should return a result object that can store different pieces of information about what happened. This currently stores `execution_count`, `error_before_exec` (i.e. errors transforming, parsing or compiling the code), `error_in_exec` and `result`. It calculates `success` as a boolean that's true if neither of the error fields are set. Closes ipythongh-7256
ipythongh-7256 asked for a boolean return value from run_cell() for whether code ran successfully. I discussed this with Min, who suggested that given the complexity of run_cell, it should return a result object that can store different pieces of information about what happened. This currently stores `execution_count`, `error_before_exec` (i.e. errors transforming, parsing or compiling the code), `error_in_exec` and `result`. It calculates `success` as a boolean that's true if neither of the error fields are set. Closes ipythongh-7256
the raw_cell might need transformation and cannot be tokenized. Fixes ipython#7256
the raw_cell might need transformation and cannot be tokenized. Fixes ipython#7256
the raw_cell might need transformation and cannot be tokenized. Fixes ipython#7256
the (undocumented) return value of InteractiveShell.run_ast_nodes is
the return value of run_cell is always None. This is asymmetric.
The text was updated successfully, but these errors were encountered: