src/eric7/Plugins/CheckerPlugins/SyntaxChecker/pyCheckSyntax.py

branch
eric7
changeset 10341
3fdffd9cc21d
parent 10188
0f873791d67e
child 10439
21c28b0f9e41
equal deleted inserted replaced
10340:548b4c7f410e 10341:3fdffd9cc21d
105 @type bool 105 @type bool
106 @param ignoreStarImportWarnings flag indicating to ignore 'star import' warnings 106 @param ignoreStarImportWarnings flag indicating to ignore 'star import' warnings
107 @type bool 107 @type bool
108 @param additionalBuiltins list of names pyflakes should consider as builtins 108 @param additionalBuiltins list of names pyflakes should consider as builtins
109 @type list of str 109 @type list of str
110 @return dictionary with the keys 'error', 'py_warnings' and 'warnings' which 110 @return list of dictionaries with the keys 'error', 'py_warnings' and 'warnings'
111 hold a list containing details about the syntax error, Python warnings 111 which contain a tuple with details about the syntax error or a list of
112 and PyFlakes warnings (file name, line number, column, codestring (only 112 tuples with details about Python warnings and PyFlakes warnings. Each tuple
113 for syntax errors), the message and an optional list with arguments for 113 contains the file name, line number, column, code string (only for syntax
114 the message) 114 errors), the message and an optional list with arguments for the message.
115 @rtype dict 115 @rtype list of dict
116 """ 116 """
117 return __pySyntaxAndPyflakesCheck( 117 return __pySyntaxAndPyflakesCheck(
118 filename, codestring, checkFlakes, ignoreStarImportWarnings, additionalBuiltins 118 filename, codestring, checkFlakes, ignoreStarImportWarnings, additionalBuiltins
119 ) 119 )
120 120
124 Module function to check syntax for a batch of files. 124 Module function to check syntax for a batch of files.
125 125
126 @param argumentsList list of arguments tuples as given for pySyntaxAndPyflakesCheck 126 @param argumentsList list of arguments tuples as given for pySyntaxAndPyflakesCheck
127 @type list 127 @type list
128 @param send reference to send function 128 @param send reference to send function
129 @type func 129 @type function
130 @param fx registered service name 130 @param fx registered service name
131 @type str 131 @type str
132 @param cancelled reference to function checking for a cancellation 132 @param cancelled reference to function checking for a cancellation
133 @type func 133 @type function
134 @param maxProcesses number of processes to be used 134 @param maxProcesses number of processes to be used
135 @type int 135 @type int
136 """ 136 """
137 if maxProcesses == 0: 137 if maxProcesses == 0:
138 # determine based on CPU count 138 # determine based on CPU count
236 @param ignoreStarImportWarnings flag indicating to 236 @param ignoreStarImportWarnings flag indicating to
237 ignore 'star import' warnings 237 ignore 'star import' warnings
238 @type bool 238 @type bool
239 @param additionalBuiltins list of names pyflakes should consider as builtins 239 @param additionalBuiltins list of names pyflakes should consider as builtins
240 @type list of str 240 @type list of str
241 @return dictionary with the keys 'error', 'py_warnings' and 'warnings' which 241 @return list of dictionaries with the keys 'error', 'py_warnings' and 'warnings'
242 hold a list containing details about the syntax error, Python warnings 242 which contain a tuple with details about the syntax error or a list of
243 and PyFlakes warnings (file name, line number, column, codestring (only 243 tuples with details about Python warnings and PyFlakes warnings. Each tuple
244 for syntax errors), the message and an optional list with arguments for 244 contains the file name, line number, column, code string (only for syntax
245 the message) 245 errors), the message and an optional list with arguments for the message.
246 @rtype dict 246 @rtype list of dict
247 """ 247 """
248 if codestring: 248 if codestring:
249 errorDict = {} 249 errorDict = {}
250 pyWarnings = [] 250 pyWarnings = []
251 251

eric ide

mercurial