newmen/versatile-diamond

View on GitHub

Showing 197 of 197 total issues

Class AtomProperties has 73 methods (exceeds 20 allowed). Consider refactoring.
Open

    class AtomProperties
      include Modules::ListsComparer
      include Modules::OrderProvider
      include Lattices::BasicRelations

Severity: Major
Found in analyzer/lib/organizers/atom_properties.rb - About 1 day to fix

    File atom_properties.rb has 571 lines of code (exceeds 250 allowed). Consider refactoring.
    Open

    module VersatileDiamond
      using Patches::RichArray
      using Patches::RichString
    
      module Organizers
    Severity: Major
    Found in analyzer/lib/organizers/atom_properties.rb - About 1 day to fix

      Class BaseContextProvider has 57 methods (exceeds 20 allowed). Consider refactoring.
      Open

              class BaseContextProvider
                include Modules::ListsComparer
      
                # @param [Units::Expressions::VarsDictionary] dict
                # @param [Hash] nodes_graph
      Severity: Major
      Found in analyzer/lib/generators/code/algorithm/units/base_context_provider.rb - About 1 day to fix

        Class ContextBaseUnit has 53 methods (exceeds 20 allowed). Consider refactoring.
        Open

                class ContextBaseUnit < GenerableUnit
                  include Modules::ProcsReducer
                  include Modules::ListsComparer
                  extend Forwardable
        
        
        Severity: Major
        Found in analyzer/lib/generators/code/algorithm/units/context_base_unit.rb - About 7 hrs to fix

          Class DependentWrappedSpec has 53 methods (exceeds 20 allowed). Consider refactoring.
          Open

              class DependentWrappedSpec < DependentSpec
                include MinuendSpec
          
                # TODO: own there objects that described below are not used
                collector_methods :there, :child
          Severity: Major
          Found in analyzer/lib/organizers/dependent_wrapped_spec.rb - About 7 hrs to fix

            Class Specie has 52 methods (exceeds 20 allowed). Consider refactoring.
            Open

                  class Specie < BaseSpecie
                    include Modules::SpecNameConverter
                    include SpeciesUser
                    include ReactionsUser
                    extend Forwardable
            Severity: Major
            Found in analyzer/lib/generators/code/specie.rb - About 7 hrs to fix

              Method convert_rate has a Cognitive Complexity of 43 (exceeds 5 allowed). Consider refactoring.
              Open

                      def convert_rate(value, gases_num, dimension = nil)
                        return 0 if value == 0
              
                        dimension ||= @rate
                        syntax_error('.is_not_set') unless dimension
              Severity: Minor
              Found in analyzer/lib/tools/dimension.rb - About 6 hrs to fix

              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

              Class AtomClassifier has 43 methods (exceeds 20 allowed). Consider refactoring.
              Open

                  class AtomClassifier
              
                    # Initialize a classifier by empty sets of properties
                    # @param [Array] danglings the list of termination species
                    def initialize(danglings = [])
              Severity: Minor
              Found in analyzer/lib/organizers/atom_classifier.rb - About 5 hrs to fix

                Class EngineCode has 40 methods (exceeds 20 allowed). Consider refactoring.
                Open

                    class EngineCode < Base
                
                      MAIN_CODE_INST_NAMES =
                        %w(atom_builder config env finder handbook names rates_reader).freeze
                
                
                Severity: Minor
                Found in analyzer/lib/generators/engine_code.rb - About 5 hrs to fix

                  Class BasePureUnit has 39 methods (exceeds 20 allowed). Consider refactoring.
                  Open

                          class BasePureUnit < GenerableUnit
                            include Modules::OrderProvider
                            include Modules::ProcsReducer
                  
                            attr_reader :nodes
                  Severity: Minor
                  Found in analyzer/lib/generators/code/algorithm/units/base_pure_unit.rb - About 5 hrs to fix

                    Method initialize has a Cognitive Complexity of 33 (exceeds 5 allowed). Consider refactoring.
                    Open

                          def initialize(g1, g2, comparer: nil, bonds_checker: nil, &block)
                            @g1, @g2 = g1, g2
                    
                            comparer ||= -> _, _, v, w { v.same?(w) }
                    
                    
                    Severity: Minor
                    Found in analyzer/lib/mcs/assoc_graph.rb - About 4 hrs to fix

                    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 context_base_unit.rb has 363 lines of code (exceeds 250 allowed). Consider refactoring.
                    Open

                    module VersatileDiamond
                      using Patches::RichArray
                    
                      module Generators
                        module Code
                    Severity: Minor
                    Found in analyzer/lib/generators/code/algorithm/units/context_base_unit.rb - About 4 hrs to fix

                      Class ContextSpecieUnit has 35 methods (exceeds 20 allowed). Consider refactoring.
                      Open

                              class ContextSpecieUnit < ContextBaseUnit
                                # @param [Array] _
                                def initialize(*)
                                  super
                      
                      
                      Severity: Minor
                      Found in analyzer/lib/generators/code/algorithm/units/context_specie_unit.rb - About 4 hrs to fix

                        Class ChunksCombiner has 33 methods (exceeds 20 allowed). Consider refactoring.
                        Open

                            class ChunksCombiner
                              include Mcs::SpecsAtomsComparator
                              include Modules::ExtendedCombinator
                              include Modules::ListsComparer
                        
                        
                        Severity: Minor
                        Found in analyzer/lib/organizers/chunks_combiner.rb - About 4 hrs to fix

                          Class BaseGroupedNodes has 31 methods (exceeds 20 allowed). Consider refactoring.
                          Open

                                  class BaseGroupedNodes
                                    include Modules::ExtendedCombinator
                                    include Modules::GraphDupper
                                    include Modules::ListsComparer
                                    extend Forwardable
                          Severity: Minor
                          Found in analyzer/lib/generators/code/algorithm/base_grouped_nodes.rb - About 3 hrs to fix

                            Class SpecificSpec has 31 methods (exceeds 20 allowed). Consider refactoring.
                            Open

                                class SpecificSpec
                                  include Modules::RelationBetweenChecker
                                  include Modules::GraphDupper
                                  include BondsCounter
                                  extend Forwardable
                            Severity: Minor
                            Found in analyzer/lib/concepts/specific_spec.rb - About 3 hrs to fix

                              Class Reaction has 31 methods (exceeds 20 allowed). Consider refactoring.
                              Open

                                  class Reaction < UbiquitousReaction
                                    include Modules::GraphDupper
                                    include Modules::SpecAtomSwapper
                                    include Linker
                                    include SurfaceLinker
                              Severity: Minor
                              Found in analyzer/lib/concepts/reaction.rb - About 3 hrs to fix

                                File chunks_combiner.rb has 326 lines of code (exceeds 250 allowed). Consider refactoring.
                                Open

                                module VersatileDiamond
                                  using Patches::RichArray
                                
                                  module Organizers
                                
                                
                                Severity: Minor
                                Found in analyzer/lib/organizers/chunks_combiner.rb - About 3 hrs to fix

                                  Method to_s has a Cognitive Complexity of 26 (exceeds 5 allowed). Consider refactoring.
                                  Open

                                        def to_s
                                          return @_to_s if @_to_s
                                  
                                          name = atom_name.to_s
                                  
                                  
                                  Severity: Minor
                                  Found in analyzer/lib/organizers/atom_properties.rb - About 3 hrs to fix

                                  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

                                  Class Spec has 28 methods (exceeds 20 allowed). Consider refactoring.
                                  Open

                                      class Spec < Named
                                        include Modules::RelationBetweenChecker
                                        include AtomsSwapper
                                        include BondsCounter
                                        include Linker
                                  Severity: Minor
                                  Found in analyzer/lib/concepts/spec.rb - About 3 hrs to fix
                                    Severity
                                    Category
                                    Status
                                    Source
                                    Language