bundles / IPython 9.13.0 / IPython / core / interactiveshell / InteractiveShell / showsyntaxerror
function
IPython.core.interactiveshell:InteractiveShell.showsyntaxerror
Signature
def showsyntaxerror ( self , filename = None , running_compiled_code = False ) Summary
Display the syntax error that just occurred.
Extended Summary
This doesn't display a stack trace because there isn't one.
If a filename is given, it is stuffed in the exception instead of what was there before (because Python's parser always uses "<string>" when reading from a string).
If the syntax error occurred when running a compiled code (i.e. running_compile_code=True), longer stack trace will be displayed.
Aliases
-
IPython.InteractiveShell.showsyntaxerror