diff -r df7025fe26a3 -r d546c4e72f52 eric6/Plugins/CheckerPlugins/CodeStyleChecker/CodeStyleChecker.py --- a/eric6/Plugins/CheckerPlugins/CodeStyleChecker/CodeStyleChecker.py Sat Jun 06 19:42:15 2020 +0200 +++ b/eric6/Plugins/CheckerPlugins/CodeStyleChecker/CodeStyleChecker.py Sun Jun 07 20:19:54 2020 +0200 @@ -24,6 +24,7 @@ from DocStyleChecker import DocStyleChecker from MiscellaneousChecker import MiscellaneousChecker from ComplexityChecker import ComplexityChecker +from Security.SecurityChecker import SecurityChecker def initService(): @@ -264,9 +265,9 @@ excludeMessages, includeMessages, repeatMessages, fixCodes, noFixCodes, fixIssues, maxLineLength, maxDocLineLength, blankLines, hangClosing, docType, codeComplexityArgs, miscellaneousArgs, - annotationArgs, errors, eol, encoding, backup) + annotationArgs, securityArgs, errors, eol, encoding, backup) @type list of (str, str, bool, str, str, bool, int, list of (int, int), - bool, str, dict, dict, list of str, str, str, bool) + bool, str, dict, dict, dict, list of str, str, str, bool) @return tuple of statistics data and list of result dictionaries with keys: <ul> @@ -285,8 +286,8 @@ """ (excludeMessages, includeMessages, repeatMessages, fixCodes, noFixCodes, fixIssues, maxLineLength, maxDocLineLength, blankLines, hangClosing, - docType, codeComplexityArgs, miscellaneousArgs, annotationArgs, errors, - eol, encoding, backup) = args + docType, codeComplexityArgs, miscellaneousArgs, annotationArgs, + securityArgs, errors, eol, encoding, backup) = args stats = {} @@ -319,6 +320,8 @@ else: ignore = [] + # TODO: perform syntax check and report invalid syntax once for all + # check coding style pycodestyle.BLANK_LINES_CONFIG = { # Top level class and function. @@ -372,6 +375,13 @@ annotationsChecker.run() stats.update(annotationsChecker.counters) errors += annotationsChecker.errors + + securityChecker = SecurityChecker( + source, filename, select, ignore, [], repeatMessages, + securityArgs) + securityChecker.run() + stats.update(securityChecker.counters) + errors += securityChecker.errors errorsDict = {} for error in errors: