Showing 5 of 5 total issues
Method load
has 119 lines of code (exceeds 25 allowed). Consider refactoring. Open
def load(args)
options = OpenStruct.new
options.libs = nil
options.grep_pattern = nil
options.grep_invert = false
Method load
has a Cognitive Complexity of 15 (exceeds 5 allowed). Consider refactoring. Open
def load(args)
options = OpenStruct.new
options.libs = nil
options.grep_pattern = nil
options.grep_invert = false
- 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 build_riml_path
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
def build_riml_path(dirs, pattern = /.*\.riml$/, spec_pattern = /.*_spec\.riml$/)
libs = []
dirs.each do |dir|
if File.directory?(dir)
Find.find(dir) do |path|
- 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 rake_env
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
def rake_env(key, value)
unless value.nil?
ENV[key] = if value.is_a?(Array) then value.join(';') else value end
puts "rake_env: #{key} = #{ENV[key]}" if debug
end
- 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 get_builder
has a Cognitive Complexity of 7 (exceeds 5 allowed). Consider refactoring. Open
def get_builder
if @source_builder.nil?
@source_builder = Speckle::List::Builder.new
@options.inputs.each do |input|
@source_builder.add_source input
- 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"