Showing 9,525 of 13,510 total issues
Function try_link
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def try_link(self, body, headers=None, include_dirs=None, libraries=None,
Function make_release_tree
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def make_release_tree(self, base_dir, files):
"""Create the directory tree that will become the source
distribution archive. All directories implied by the filenames in
'files' are created under 'base_dir', and then we hard link or copy
(if hard linking is unavailable) those files into place.
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function create_exe
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def create_exe (self, arcname, fullname, bitmap=None):
import struct
self.mkpath(self.dist_dir)
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function get_outputs
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def get_outputs (self):
# Assemble the outputs of all the sub-commands.
outputs = []
for cmd_name in self.get_sub_commands():
cmd = self.get_finalized_command(cmd_name)
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Avoid deeply nested control flow statements. Open
if os.path.isfile(f):
self.filelist.append(f)
Function preprocess
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def preprocess(self, source, output_file=None, macros=None,
Function get_inidata
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def get_inidata (self):
# Return data describing the installation.
lines = []
metadata = self.distribution.metadata
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function find_config_files
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def find_config_files(self):
"""Find as many configuration files as should be processed for this
platform, and return a list of filenames in the order in which they
should be parsed. The filenames returned are guaranteed to exist
(modulo nasty race conditions).
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Function _setup_compile
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def _setup_compile(self, outdir, macros, incdirs, sources, depends,
Function try_run
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def try_run(self, body, headers=None, include_dirs=None, libraries=None,
Function run
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def run(self):
if not self.libraries:
return
# Yech -- this is cut 'n pasted from build_ext.py!
- Read upRead up
Cognitive Complexity
Cognitive Complexity is a measure of how difficult a unit of code is to intuitively understand. Unlike Cyclomatic Complexity, which determines how difficult your code will be to test, Cognitive Complexity tells you how difficult your code will be to read and comprehend.
A method's cognitive complexity is based on a few simple rules:
- Code is not considered more complex when it uses shorthand that the language provides for collapsing multiple statements into one
- Code is considered more complex for each "break in the linear flow of the code"
- Code is considered more complex when "flow breaking structures are nested"
Further reading
Avoid deeply nested control flow statements. Open
if not choice:
choice = 'n'
if choice.lower() == 'y':
Function _link
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def _link(self, body, headers, include_dirs, libraries, library_dirs,
Avoid deeply nested control flow statements. Open
Function make_archive
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def make_archive(self, base_name, format, root_dir=None, base_dir=None,
Function _compile
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def _compile(self, obj, src, ext, cc_args, extra_postargs, pp_opts):
Function _compile
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def _compile(self, obj, src, ext, cc_args, extra_postargs, pp_opts):
Avoid deeply nested control flow statements. Open
Function preprocess
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def preprocess(self, source,
Function _compile
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def _compile(self, obj, src, ext, cc_args, extra_postargs, pp_opts):