Showing 263 of 263 total issues
Method plot_xyft
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
def plot_xyft(t0,tmax,pas,xy,color="#000000",ep=2,&b)
Method draw_curve1
has 7 arguments (exceeds 4 allowed). Consider refactoring. Open
def draw_curve1(curve,i,x0,y0,unit, type, vy)
Method initialize
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def initialize(noc,min,max,label,dxlabel,auto_scale)
Method draw_tile
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def draw_tile(ctx,f,x,y,pdx,pdy)
Method draw_tile
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def draw_tile(ctx,f,x,y,pdx,pdy)
Method _dyn_ientry
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def _dyn_ientry(var,options,slotied)
w= unless slotied
(block_given? ? ientry(var.value,options) : ientry(var.value,options) { |v| var.value=v })
else
(block_given? ? ientry(var.value,options) : ientry(var.value,options) { |v| var.value=v })
- 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 pt_in_bbox?
has 6 arguments (exceeds 4 allowed). Consider refactoring. Open
def pt_in_bbox?(x,y, x0,y0,x1,y1)
Method combo
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def combo(choices,default=nil,option={},&blk)
# TODO Dyn
w=ComboBoxText.new()
choices=choices.inject({}) { |h,k|
h[k]=h.size
- 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 calc_alarme
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def calc_alarme(cote,values)
return [false,false] unless values["last"]
value=values["last"].to_f
p1=cote[:param1]
p2=cote[:param2]
- 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 panel_progress
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def panel_progress(text="",&blk)
dvar= ::DynVar.new(0)
lw=nil
d=panel_async("Progression...") {
lw=label text if text && text.size >0
- 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 run2
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def run2
ii=0
sleep 30
loop {
Open3.popen3("ping 10.177.235.1") { |si,so,se|
- 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 main
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def main(ss)
lth=[]
no=0
Dir.mkdir('mstat') unless Dir.exists?('mstat')
- 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 register_value
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def register_value(data)
if data.is_a? Array
svalue=data[@noc]
return if !svalue || svalue !~ /[\d.]+/
@value=svalue.to_f
- 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 test_crud
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def test_crud()
stack do
$gheader=%w{id first-name last-name age}
$gdata=[%w{regis aubarede 12},%w{siger ederabu 21},%w{baraque aubama 12},%w{ruiby ruby 1}]
i=-1; $gdata.map! { |l| i+=1; [i]+l }
- 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 islider
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def islider(value=0,option={},&b)
if DynVar === value
return _dyn_islider(value,option,&b)
end
w=Scale.new(:horizontal,(option[:min]||0).to_i,(option[:max]||100).to_i,option[:by]||1)
- 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 draw_rounded_rectangle
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def cv.draw_rounded_rectangle(x0,y0,w,h,ar,colorStroke,colorFill,widthStroke)
cv,cr=@currentCanvasCtx
pi=Math::PI
ar=[ar,ar,ar,ar] if ar.kind_of?(Numeric)
if Array === colorFill
- 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 add_curve
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def plot.add_curve(name,config)
c=config.dup
c[:type] = :curve
c[:data] ||= [[0,0],[100,100]]
c[:maxlendata] ||= c[:data].size
- 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 fslider
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def fslider(value=0,option={},&b)
if DynVar === value
return _dyn_fslider(value,option,&b)
end
w=Scale.new(:horizontal,option[:min],option[:max],option[:by])
- 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 _draw_poly
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def cv._draw_poly(lxy,color_fg,color_bg,width)
raise("odd number of coord for lxy") if !lxy || lxy.size==0 || lxy.size%2==1
w,cr=@currentCanvasCtx
cr.set_line_width(width) if width
x0,y0,*poly=*lxy
- 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 log
has a Cognitive Complexity of 8 (exceeds 5 allowed). Consider refactoring. Open
def log(*txt)
if $__mainthread__ && $__mainthread__ != Thread.current
gui_invoke { log(*txt) }
return
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"