Showing 66 of 177 total issues
File oopricing1.py
has 553 lines of code (exceeds 250 allowed). Consider refactoring. Open
# -*- coding: utf-8 -*-
'''
rmtoo
Free and Open Source Requirements Management Tool
Function topic_set_pre
has a Cognitive Complexity of 53 (exceeds 5 allowed). Consider refactoring. Open
def topic_set_pre(self, topic_set):
'''This is call in the TopicSet pre-phase.'''
prios_impl, prios_detail, prios_selected, \
prios_assigned, prios_finished = \
self.__get_reqs_impl_detail(topic_set)
- 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
File RequirementSet.py
has 475 lines of code (exceeds 250 allowed). Consider refactoring. Open
'''
rmtoo
Free and Open Source Requirements Management Tool
Collection of topics.
RequirementSet
has 44 functions (exceeds 20 allowed). Consider refactoring. Open
class RequirementSet(Digraph, UsableFlag):
'''A RequirementSet holds one DAG (directed acyclic graph)
of requirements.'''
def __init__(self, config):
Function requirement
has a Cognitive Complexity of 32 (exceeds 5 allowed). Consider refactoring. Open
def requirement(self, req):
'''Write out one requirement.'''
self.__fd.write(u"%% REQ '%s'\n" % req.get_id())
self.__fd.write(u"\\%s{%s}\\label{%s}\n\\textbf{Description:} %s\n"
- 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
oopricing1
has 33 functions (exceeds 20 allowed). Consider refactoring. Open
class oopricing1(StdOutputParams, ExecutorTopicContinuum,
CreateMakeDependencies):
def __setup_coord_lookup(self):
'''Because at some points a requirement will be rendered in a row
Function _get_requirement
has a Cognitive Complexity of 23 (exceeds 5 allowed). Consider refactoring. Open
def _get_requirement(self, req):
'''Write out one requirement.'''
req_template = self._template_env.get_template("singleReq.tex")
template_vars = (
{'req_id': self.__strescape(req.get_id()),
- 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_units_generic
has a Cognitive Complexity of 23 (exceeds 5 allowed). Consider refactoring. Open
def get_units_generic(rset, start_date, end_date, skip_requirement):
"""Run through the requirements and count the not done
depending on the date.
"""
result_vec = Statistics.prepare_result_vector(start_date, end_date)
- 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
Html
has 25 functions (exceeds 20 allowed). Consider refactoring. Open
class Html(ExecutorTopicContinuum, CreateMakeDependencies):
"""HTML output module"""
def __init__(self, oconfig):
'''Create a graph output object.'''
Function output_req
has a Cognitive Complexity of 19 (exceeds 5 allowed). Consider refactoring. Open
def output_req(self, req, doc, sobj):
# Create the req element
req_xml = doc.createElement("requirement")
sobj.appendChild(req_xml)
- 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 strongly_connected_components
has a Cognitive Complexity of 18 (exceeds 5 allowed). Consider refactoring. Open
def strongly_connected_components(digraph):
"""This algorithm is based upon a depth first search. It assigns a
number to each visited node.
"""
# This is the number the next node is assigned. (There is no other
- 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 node_attributes
has a Cognitive Complexity of 18 (exceeds 5 allowed). Consider refactoring. Open
def node_attributes(req, config=default_config):
def get_conf_attr(attr):
return config.is_available("node_attributes") \
and attr in config.get_value("node_attributes")
- 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
File latex2.py
has 262 lines of code (exceeds 250 allowed). Consider refactoring. Open
'''
rmtoo
Free and Open Source Requirements Management Tool
LaTeX output class version 2.
File LatexJinja2.py
has 261 lines of code (exceeds 250 allowed). Consider refactoring. Open
'''
rmtoo
Free and Open Source Requirements Management Tool
LaTeX output with jinja templating engine.
File html.py
has 255 lines of code (exceeds 250 allowed). Consider refactoring. Open
'''
rmtoo
Free and Open Source Requirements Management Tool
HTML output class.
Function output_html_topic_output_content
has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring. Open
def output_html_topic_output_content(self, fd, topic):
# Subtopics go in a ul
ul_open = False
for t in topic.get_tags():
tag = t.get_tag()
- 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 requirement
has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring. Open
def requirement(self, req):
'''Output one requirement.'''
out_fd = self.__fd_stack[-1]
level = len(self.__fd_stack)
- 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 unite
has a Cognitive Complexity of 13 (exceeds 5 allowed). Consider refactoring. Open
def unite(self, oce3s):
"""Try to unite all given ce3s into the local ce3"""
okeys = set()
for oce in oce3s:
okeys = okeys.union(set(oce.keys()))
- 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 main
has a Cognitive Complexity of 13 (exceeds 5 allowed). Consider refactoring. Open
def main():
"""The main function for the pricing graph"""
csvfilename, graphfilename = parse_argv()
# The files must be saved according to this rules:
- 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_reqs_impl_detail
has a Cognitive Complexity of 12 (exceeds 5 allowed). Consider refactoring. Open
def __get_reqs_impl_detail(self, topic_set):
'''Return the implementation details of the requirements.'''
prios_impl = []
prios_detail = []
prios_selected = []
- 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"