Trivial function with docstring reports complexity of 2
asottile opened this issue · 2 comments
asottile commented
def f():
"""hi"""
x = 1
def g():
"""hi"""
$ python3.5 mccabe.py test.py
1:0: 'f' 1
6:0: 'g' 2
$ git rev-parse HEAD
682145a37fee41fe7b6640244faa0c3f58e3b496
sigmavirus24 commented
I suspect this is related to the computation needing both nodes and edges to calculate the complexity.