Note that this site is in currently in version 1.0.0-alpha.   Some functionality may be limited.

Syntax Errors

Along with traceback errors, syntax errors are a common type of error in Python code. It appears when Python is unable to understand a line of code, meaning that there is a mistake. Often, syntax errors point to typos, indentation, or incomplete expressions, like missing quotation marks or parentheses. When a syntax error occurs, the interpreter will display a caret pointing to the area where the error occured. It will also display the message: SyntaxError: invalid syntax. Take a close look at the display message to get more information about your error, and help you with debugging.

Readings

a comprehensive list of possible errors
To see a comprehensive list of possible errors, check out this resource on Tutorials Teacher.
syntax errors
See a fuller description of syntax errors on Geek University.

Lessons referring to this term