Showing 1,579 of 1,593 total issues
Module has too many lines. [104/100] Open
module MiGA::Project::Result
include MiGA::Project::Base
include MiGA::Common::WithResult
##
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
This cop checks if the length a module exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable.
Class has too many lines. [103/100] Open
class MiGA::Cli::Action::TaxDist < MiGA::Cli::Action
def parse_cli
cli.parse do |opt|
cli.opt_object(opt, [:project])
cli.opt_filter_datasets(opt)
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
This cop checks if the length a class exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable.
Assignment Branch Condition size for perform is too high. [72.7/15] Open
def perform
cli.ensure_par(result: '-r')
ds = cli.load_and_filter_datasets
cli.say 'Loading results'
k = 0
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
This cop checks that the ABC size of methods is not higher than the configured maximum. The ABC size is based on assignments, branches (method calls), and conditions. See http://c2.com/cgi/wiki?AbcMetric
Method has too many lines. [66/10] Open
def parse_cli
cli.defaults = { daemon_opts: [], show_log: false }
cli.expect_operation = true
cli.parse do |opt|
opt.separator 'Available operations:'
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
This cop checks if the length of a method exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable.
Assignment Branch Condition size for perform is too high. [70.8/15] Open
def perform
ds = cli.load_and_filter_datasets(cli[:silent])
p = cli.load_project
exit(ds.empty? ? 1 : 0) if cli[:silent]
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
This cop checks that the ABC size of methods is not higher than the configured maximum. The ABC size is based on assignments, branches (method calls), and conditions. See http://c2.com/cgi/wiki?AbcMetric
Assignment Branch Condition size for load_and_filter_datasets is too high. [63.78/15] Open
def load_and_filter_datasets(silent = false)
return @objects[:filtered_datasets] unless @objects[:filtered_datasets].nil?
say 'Listing datasets'
ds =
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
This cop checks that the ABC size of methods is not higher than the configured maximum. The ABC size is based on assignments, branches (method calls), and conditions. See http://c2.com/cgi/wiki?AbcMetric
Assignment Branch Condition size for opts_for_wf is too high. [62.59/15] Open
def opts_for_wf(opt, files_desc, params = {})
{
multi: false, cleanup: true, project_type: false, ncbi: true, qual: true
}.each { |k, v| params[k] = v if params[k].nil? }
opt.on(
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
This cop checks that the ABC size of methods is not higher than the configured maximum. The ABC size is based on assignments, branches (method calls), and conditions. See http://c2.com/cgi/wiki?AbcMetric
Method has too many lines. [54/10] Open
def parse_cli
cli.interactive = true
cli.defaults = {
mytaxa: nil,
rdp: nil,
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
This cop checks if the length of a method exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable.
Assignment Branch Condition size for perform is too high. [57.87/15] Open
def perform
unless cli[:value].nil?
cli.ensure_par(
{ key: '-k' },
'%<name>s is mandatory when --value is set: provide %<flag>s'
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
This cop checks that the ABC size of methods is not higher than the configured maximum. The ABC size is based on assignments, branches (method calls), and conditions. See http://c2.com/cgi/wiki?AbcMetric
Method has too many lines. [52/10] Open
def parse_cli
cli.defaults = {
database: :recommended,
version: :latest,
local: File.join(ENV['MIGA_HOME'], '.miga_db'),
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
This cop checks if the length of a method exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable.
Method has too many lines. [50/10] Open
def test_add_result_other
d2 = project.add_dataset('ds_add_result_other')
Dir.mkdir(
File.join(
project.path, 'data', '07.annotation', '01.function', '01.essential',
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
This cop checks if the length of a method exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable.
Assignment Branch Condition size for compute_stats_ssu is too high. [55.34/15] Open
def compute_stats_ssu
stats = {
ssu: 0, complete_ssu: 0, ssu_fragment: [0.0, '%'],
lsu: 0, complete_lsu: 0, lsu_fragment: [0.0, '%']
}
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
This cop checks that the ABC size of methods is not higher than the configured maximum. The ABC size is based on assignments, branches (method calls), and conditions. See http://c2.com/cgi/wiki?AbcMetric
Method has too many lines. [50/10] Open
def seqs_length(file, format, opts = {})
opts[:gc] = true if opts[:skew]
fh = file =~ /\.gz/ ? Zlib::GzipReader.open(file) : File.open(file, 'r')
l = []
gc = 0
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
This cop checks if the length of a method exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable.
Assignment Branch Condition size for advance is too high. [54.48/15] Open
def advance(step, n = 0, total = nil, bin = true)
# Initialize advance timing
@_advance_time ||= { last: nil, n: 0, avg: nil }
if @_advance_time[:n] > n
@_advance_time[:last] = nil
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
This cop checks that the ABC size of methods is not higher than the configured maximum. The ABC size is based on assignments, branches (method calls), and conditions. See http://c2.com/cgi/wiki?AbcMetric
Method has too many lines. [49/10] Open
def perform
# Load environment variables if requested (typically by the daemon)
if cli[:env]
cli[:project] ||= ENV['PROJECT']
cli[:dataset] ||= ENV['DATASET']
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
This cop checks if the length of a method exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable.
Method has too many lines. [48/10] Open
def parse_cli
cli.expect_files = true
cli.defaults = { ref: true, ignore_dups: false }
cli.parse do |opt|
opt.separator 'You can create multiple datasets with a single command; ' \
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
This cop checks if the length of a method exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable.
Assignment Branch Condition size for test_alternative is too high. [52.15/15] Open
def test_alternative
tx = MiGA::Taxonomy.new('ns:a s:Arnie', nil,
['ns:b s:Bernie', 'ns:c s:Cornie', 's:Darnie'])
# Fields
assert_equal('ns:a s:Arnie', tx.to_s)
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
This cop checks that the ABC size of methods is not higher than the configured maximum. The ABC size is based on assignments, branches (method calls), and conditions. See http://c2.com/cgi/wiki?AbcMetric
Method has too many lines. [46/10] Open
def compute_stats_ssu
stats = {
ssu: 0, complete_ssu: 0, ssu_fragment: [0.0, '%'],
lsu: 0, complete_lsu: 0, lsu_fragment: [0.0, '%']
}
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
This cop checks if the length of a method exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable.
Method has too many lines. [46/10] Open
def opt_object(opt, what = %i[project dataset])
what.each do |w|
case w
when :project
opt.on(
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
This cop checks if the length of a method exceeds some maximum value. Comment lines can optionally be ignored. The maximum allowed length is configurable.
Assignment Branch Condition size for compute_stats_essential_genes is too high. [50.65/15] Open
def compute_stats_essential_genes
stats = {}
if source.multi?
stats = { median_copies: 0, mean_copies: 0 }
File.open(file_path(:report), 'r') do |fh|
- Read upRead up
- Create a ticketCreate a ticket
- Exclude checks
This cop checks that the ABC size of methods is not higher than the configured maximum. The ABC size is based on assignments, branches (method calls), and conditions. See http://c2.com/cgi/wiki?AbcMetric