Showing 171 of 292 total issues
Method mkconfig
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def mkconfig(definition, functional_group_def, isa11, gs01, gs08, st01)
Avoid deeply nested control flow statements. Open
Open
unless s.satisfied?(zipper)
raise Exceptions::ParseError,
"for #{zipper.node.descriptor}, #{s.reason(zipper)} at #{zipper.node.position.inspect}"
end
Avoid deeply nested control flow statements. Open
Open
if zipper.node.invalid?
if zipper.up.node.invalid?
# parent is an InvalidEnvelopeVal
raise Exceptions::ParseError,
"#{zipper.first.node.reason} at #{zipper.first.node.position.inspect}"
Avoid deeply nested control flow statements. Open
Open
elsif zipper.node.loop?
critique_occurences zipper, recursive
elsif zipper.node.table?
critique_occurences zipper, recursive
Method pretty_print
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
Open
def pretty_print(q)
id = "% 3s" % @segment_id.to_s
unless @segment_use.nil?
width = 18
- 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
Method initialize
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def initialize(definition, position, requirement, repeat_count, parent)
Method initialize
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def initialize(separators, segment_dict, instructions, zipper, children)
Method initialize
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def initialize(separators, segment_dict, instructions, zipper, children)
Method initialize
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def initialize(separators, segment_dict, instructions, zipper, children)
Method initialize
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def initialize(separators, segment_dict, instructions, zipper, children)
Method initialize
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def initialize(hour, minute, second, usage, position)
Method initialize
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def initialize(year, month, day, usage, position)
Method push
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def push(zipper, parent, segment_tok, segment_use, config)
Method initialize
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def initialize(machine, reader, isa_elements, gs_elements, st_elements)
Method push
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def push(zipper, parent, segment_tok, segment_use, config)
Method initialize
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def initialize(definition, requirement, repeat_count, allowed_values, parent)
Method mod_element
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def mod_element(element_use, descriptor, requirement, name, arguments)
Method initialize
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def initialize(separators, segment_dict, instructions, zipper, children)
Method push
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def push(zipper, parent, segment_tok, segment_use, config)
Method push
has 5 arguments (exceeds 4 allowed). Consider refactoring. Open
Open
def push(zipper, parent, segment_tok, segment_use, config)