Files
codeql/python/ql/src/Imports/SyntaxError.ql
2018-11-19 15:10:42 +00:00

17 lines
449 B
Plaintext

/**
* @name Syntax error
* @description Syntax errors cause failures at runtime and prevent analysis of the code.
* @kind problem
* @tags reliability
* correctness
* @problem.severity error
* @sub-severity high
* @precision high
* @id py/syntax-error
*/
import python
from SyntaxError error
where not error instanceof EncodingError
select error, error.getMessage() + " (in Python " + major_version() + "." + minor_version() + ")."