147 @param text source text |
147 @param text source text |
148 @type str |
148 @type str |
149 @return tuple containing the result dictionary |
149 @return tuple containing the result dictionary |
150 @rtype (tuple of dict) |
150 @rtype (tuple of dict) |
151 """ |
151 """ |
152 from radon.complexity import cc_visit, cc_rank |
152 from radon.complexity import cc_rank, cc_visit |
153 |
153 |
154 try: |
154 try: |
155 cc = cc_visit(text) |
155 cc = cc_visit(text) |
156 res = {"result": [v for v in map(__cc2Dict, cc) if v["type"] != "method"]} |
156 res = {"result": [v for v in map(__cc2Dict, cc) if v["type"] != "method"]} |
157 totalCC = 0 |
157 totalCC = 0 |