--- a/RadonMetrics/CyclomaticComplexityCalculator.py Sat Dec 31 16:27:44 2022 +0100 +++ b/RadonMetrics/CyclomaticComplexityCalculator.py Sat May 27 15:33:58 2023 +0200 @@ -29,7 +29,7 @@ return batchCyclomaticComplexity -def cyclomaticComplexity(file, text=""): +def cyclomaticComplexity(file, text=""): # noqa: U100 """ Private function to calculate the cyclomatic complexity of one file. @@ -40,7 +40,7 @@ @return tuple containing the result dictionary @rtype (tuple of dict) """ - return __cyclomaticComplexity(file, text) + return __cyclomaticComplexity(text) def batchCyclomaticComplexity(argumentsList, send, fx, cancelled, maxProcesses=0): @@ -133,17 +133,15 @@ @type multiprocessing.Queue """ for filename, source in iter(inputQueue.get, "STOP"): - result = __cyclomaticComplexity(filename, source) + result = __cyclomaticComplexity(source) outputQueue.put((filename, result)) -def __cyclomaticComplexity(file, text=""): +def __cyclomaticComplexity(text): """ Private function to calculate the cyclomatic complexity for one Python file. - @param file source filename - @type str @param text source text @type str @return tuple containing the result dictionary