Showing 3 of 3 total issues
Function _do_dot
has a Cognitive Complexity of 18 (exceeds 5 allowed). Consider refactoring. Open
def _do_dot(targets, components, tasks, layer_fn):
print("digraph dependencies {")
try:
def _make_attribute_fn():
- 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 _print_layers
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def _print_layers(targets, components, tasks):
"""
Print dependency information, grouping components based on their position
in the dependency graph. Components with no dependnecies will be in layer
0, components that only depend on layer 0 will be in layer 1, and so on.
- 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 _execute
has a Cognitive Complexity of 6 (exceeds 5 allowed). Consider refactoring. Open
def _execute(arguments):
def _list_methods():
for key in sorted(_ORDER_OUTPUTS):
print("{} - {}".format(key, _ORDER_OUTPUTS[key][1]))
- 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"