Showing 1,158 of 1,158 total issues

File mapper.rb has 1184 lines of code (exceeds 250 allowed). Consider refactoring.
Open

require "active_support/core_ext/hash/slice"
require "active_support/core_ext/enumerable"
require "active_support/core_ext/array/extract_options"
require "active_support/core_ext/regexp"
require "action_dispatch/routing/redirection"
Severity: Major
Found in actionpack/lib/action_dispatch/routing/mapper.rb - About 3 days to fix

    File activestorage.js has 942 lines of code (exceeds 250 allowed). Consider refactoring.
    Open

    (function(global, factory) {
      typeof exports === "object" && typeof module !== "undefined" ? factory(exports) : typeof define === "function" && define.amd ? define([ "exports" ], factory) : factory(global.ActiveStorage = {});
    })(this, function(exports) {
      "use strict";
      function createCommonjsModule(fn, module) {
    Severity: Major
    Found in activestorage/app/assets/javascripts/activestorage.js - About 2 days to fix

      Class ToSql has 108 methods (exceeds 20 allowed). Consider refactoring.
      Open

          class ToSql < Arel::Visitors::Visitor
            def initialize(connection)
              super()
              @connection = connection
            end
      Severity: Major
      Found in activerecord/lib/arel/visitors/to_sql.rb - About 2 days to fix

        Function sparkMd5 has 405 lines of code (exceeds 25 allowed). Consider refactoring.
        Open

          var sparkMd5 = createCommonjsModule(function(module, exports) {
            (function(factory) {
              {
                module.exports = factory();
              }
        Severity: Major
        Found in activestorage/app/assets/javascripts/activestorage.js - About 2 days to fix

          Class AbstractAdapter has 101 methods (exceeds 20 allowed). Consider refactoring.
          Open

              class AbstractAdapter
                ADAPTER_NAME = "Abstract"
                include ActiveSupport::Callbacks
                define_callbacks :checkout, :checkin
          
          

            File to_sql.rb has 730 lines of code (exceeds 250 allowed). Consider refactoring.
            Open

            module Arel # :nodoc: all
              module Visitors
                class UnsupportedVisitError < StandardError
                  def initialize(object)
                    super "Unsupported argument type: #{object.class.name}. Construct an Arel node instead."
            Severity: Major
            Found in activerecord/lib/arel/visitors/to_sql.rb - About 1 day to fix

              File migration.rb has 719 lines of code (exceeds 250 allowed). Consider refactoring.
              Open

              require "benchmark"
              require "set"
              require "zlib"
              require "active_support/core_ext/enumerable"
              require "active_support/core_ext/module/attribute_accessors"
              Severity: Major
              Found in activerecord/lib/active_record/migration.rb - About 1 day to fix

                File postgresql_adapter.rb has 712 lines of code (exceeds 250 allowed). Consider refactoring.
                Open

                gem "pg", ">= 0.18", "< 2.0"
                require "pg"
                
                # Use async_exec instead of exec_params on pg versions before 1.1
                class ::PG::Connection # :nodoc:

                  Class Mapper has 85 methods (exceeds 20 allowed). Consider refactoring.
                  Open

                      class Mapper
                        URL_OPTIONS = [:protocol, :subdomain, :domain, :host, :port]
                  
                        class Constraints < Routing::Endpoint #:nodoc:
                          attr_reader :app, :constraints
                  Severity: Major
                  Found in actionpack/lib/action_dispatch/routing/mapper.rb - About 1 day to fix

                    File query_methods.rb has 683 lines of code (exceeds 250 allowed). Consider refactoring.
                    Open

                    require "active_record/relation/from_clause"
                    require "active_record/relation/query_attribute"
                    require "active_record/relation/where_clause"
                    require "active_record/relation/where_clause_factory"
                    require "active_model/forbidden_attributes_protection"
                    Severity: Major
                    Found in activerecord/lib/active_record/relation/query_methods.rb - About 1 day to fix

                      File reflection.rb has 665 lines of code (exceeds 250 allowed). Consider refactoring.
                      Open

                      require "active_support/core_ext/string/filters"
                      require "concurrent/map"
                      
                      module ActiveRecord
                        # = Active Record Reflection
                      Severity: Major
                      Found in activerecord/lib/active_record/reflection.rb - About 1 day to fix

                        File connection_pool.rb has 663 lines of code (exceeds 250 allowed). Consider refactoring.
                        Open

                        require "thread"
                        require "concurrent/map"
                        require "monitor"
                        require "weakref"
                        
                        

                          File route_set.rb has 662 lines of code (exceeds 250 allowed). Consider refactoring.
                          Open

                          require "action_dispatch/journey"
                          require "active_support/core_ext/object/to_query"
                          require "active_support/core_ext/module/redefine_method"
                          require "active_support/core_ext/module/remove_method"
                          require "active_support/core_ext/array/extract_options"
                          Severity: Major
                          Found in actionpack/lib/action_dispatch/routing/route_set.rb - About 1 day to fix

                            Class AbstractMysqlAdapter has 79 methods (exceeds 20 allowed). Consider refactoring.
                            Open

                                class AbstractMysqlAdapter < AbstractAdapter
                                  include MySQL::Quoting
                                  include MySQL::SchemaStatements
                            
                                  ##

                              Class PostgreSQLAdapter has 76 methods (exceeds 20 allowed). Consider refactoring.
                              Open

                                  class PostgreSQLAdapter < AbstractAdapter
                                    ADAPTER_NAME = "PostgreSQL"
                              
                                    ##
                                    # :singleton-method:

                                Class Relation has 70 methods (exceeds 20 allowed). Consider refactoring.
                                Open

                                  class Relation
                                    MULTI_VALUE_METHODS  = [:includes, :eager_load, :preload, :select, :group,
                                                            :order, :joins, :left_outer_joins, :references,
                                                            :extending, :unscope, :optimizer_hints, :annotate]
                                
                                
                                Severity: Major
                                Found in activerecord/lib/active_record/relation.rb - About 1 day to fix

                                  File abstract_mysql_adapter.rb has 594 lines of code (exceeds 250 allowed). Consider refactoring.
                                  Open

                                  require "active_record/connection_adapters/abstract_adapter"
                                  require "active_record/connection_adapters/statement_pool"
                                  require "active_record/connection_adapters/mysql/column"
                                  require "active_record/connection_adapters/mysql/explain_pretty_printer"
                                  require "active_record/connection_adapters/mysql/quoting"

                                    File schema_statements.rb has 581 lines of code (exceeds 250 allowed). Consider refactoring.
                                    Open

                                    module ActiveRecord
                                      module ConnectionAdapters
                                        module PostgreSQL
                                          module SchemaStatements
                                            # Drops the database specified on the +name+ attribute

                                      File schema_statements.rb has 570 lines of code (exceeds 250 allowed). Consider refactoring.
                                      Open

                                      require "active_record/migration/join_table"
                                      require "active_support/core_ext/string/access"
                                      require "digest/sha2"
                                      
                                      module ActiveRecord

                                        Class Parameters has 63 methods (exceeds 20 allowed). Consider refactoring.
                                        Open

                                          class Parameters
                                            cattr_accessor :permit_all_parameters, instance_accessor: false, default: false
                                        
                                            cattr_accessor :action_on_unpermitted_parameters, instance_accessor: false
                                        
                                        
                                        Severity: Major
                                        Found in actionpack/lib/action_controller/metal/strong_parameters.rb - About 1 day to fix
                                          Severity
                                          Category
                                          Status
                                          Source
                                          Language