Commit 08bc371d authored by Douglas Barbosa Alexandre's avatar Douglas Barbosa Alexandre

Merge branch '220031-investigate-enabling-style-numericpredicate-rubocop-2' into 'master'

Enable Style/NumericPredicate RuboCop

Closes #220031

See merge request gitlab-org/gitlab!36720
parents 4a7ab207 1e458949
......@@ -620,12 +620,122 @@ Style/Next:
Style/NumericLiteralPrefix:
Enabled: false
# Offense count: 255
# Offense count: 130
# Cop supports --auto-correct.
# Configuration parameters: AutoCorrect, EnforcedStyle, IgnoredMethods.
# SupportedStyles: predicate, comparison
# We use EnforcedStyle of comparison here due to it being better
# performing code as seen https://gitlab.com/gitlab-org/gitlab/-/merge_requests/36221#note_375659681
Style/NumericPredicate:
Enabled: false
EnforcedStyle: comparison
Exclude:
- 'spec/**/*'
- 'app/views/**/*'
- 'ee/app/views/**/*'
- 'app/controllers/concerns/issuable_collections.rb'
- 'app/controllers/concerns/paginated_collection.rb'
- 'app/helpers/graph_helper.rb'
- 'app/helpers/timeboxes_helper.rb'
- 'app/models/ci/pipeline.rb'
- 'app/models/ci/stage.rb'
- 'app/models/concerns/update_project_statistics.rb'
- 'app/models/merge_request_diff.rb'
- 'app/models/milestone.rb'
- 'app/models/network/graph.rb'
- 'app/models/postgresql/replication_slot.rb'
- 'app/models/project.rb'
- 'app/models/suggestion.rb'
- 'app/models/user.rb'
- 'app/serializers/merge_request_widget_entity.rb'
- 'app/services/boards/issues/move_service.rb'
- 'app/services/cohorts_service.rb'
- 'app/services/discussions/resolve_service.rb'
- 'app/services/issues/reorder_service.rb'
- 'app/services/notes/create_service.rb'
- 'app/services/packages/nuget/metadata_extraction_service.rb'
- 'app/services/packages/nuget/search_service.rb'
- 'app/services/projects/auto_devops/disable_service.rb'
- 'app/services/projects/update_pages_service.rb'
- 'app/services/search_service.rb'
- 'app/workers/admin_email_worker.rb'
- 'app/workers/gitlab/import/advance_stage.rb'
- 'config/initializers/validate_puma.rb'
- 'ee/app/controllers/security/projects_controller.rb'
- 'ee/app/graphql/mutations/instance_security_dashboard/remove_project.rb'
- 'ee/app/helpers/ee/timeboxes_helper.rb'
- 'ee/app/models/ci/minutes/quota.rb'
- 'ee/app/models/ee/ci/runner.rb'
- 'ee/app/models/geo_node_status.rb'
- 'ee/app/models/license.rb'
- 'ee/app/models/namespace_statistics.rb'
- 'ee/app/services/ee/issues/base_service.rb'
- 'ee/app/services/ee/merge_requests/approval_service.rb'
- 'ee/app/services/ee/quick_actions/target_service.rb'
- 'ee/app/services/elastic/indexing_control_service.rb'
- 'ee/app/services/geo/hashed_storage_migration_service.rb'
- 'ee/app/services/geo/prune_event_log_service.rb'
- 'ee/app/services/security/waf_anomaly_summary_service.rb'
- 'ee/app/services/update_build_minutes_service.rb'
- 'ee/app/workers/geo/container_repository_sync_dispatch_worker.rb'
- 'ee/app/workers/geo/file_download_dispatch_worker.rb'
- 'ee/app/workers/geo/registry_sync_worker.rb'
- 'ee/app/workers/geo/repository_shard_sync_worker.rb'
- 'ee/app/workers/geo/repository_verification/primary/shard_worker.rb'
- 'ee/lib/api/helpers/packages/conan/api_helpers.rb'
- 'ee/lib/ee/gitlab/auth/ldap/person.rb'
- 'ee/lib/ee/gitlab/background_migration/prune_orphaned_geo_events.rb'
- 'ee/lib/ee/gitlab/checks/push_rules/file_size_check.rb'
- 'ee/lib/ee/gitlab/geo_git_access.rb'
- 'ee/lib/gitlab/geo/fdw.rb'
- 'ee/lib/gitlab/geo/log_cursor/lease.rb'
- 'ee/lib/tasks/gitlab/elastic.rake'
- 'lib/api/entities/feature.rb'
- 'lib/api/helpers/pagination_strategies.rb'
- 'lib/backup/files.rb'
- 'lib/banzai/filter/gollum_tags_filter.rb'
- 'lib/bitbucket_server/paginator.rb'
- 'lib/declarative_policy/runner.rb'
- 'lib/gitlab/auth/ldap/adapter.rb'
- 'lib/gitlab/bare_repository_import/importer.rb'
- 'lib/gitlab/ci/config/external/context.rb'
- 'lib/gitlab/ci/reports/accessibility_reports_comparer.rb'
- 'lib/gitlab/cycle_analytics/summary/value.rb'
- 'lib/gitlab/cycle_analytics/summary_helper.rb'
- 'lib/gitlab/danger/teammate.rb'
- 'lib/gitlab/database.rb'
- 'lib/gitlab/database/connection_timer.rb'
- 'lib/gitlab/database/migration_helpers.rb'
- 'lib/gitlab/exclusive_lease.rb'
- 'lib/gitlab/exclusive_lease_helpers/sleeping_lock.rb'
- 'lib/gitlab/experimentation.rb'
- 'lib/gitlab/file_hook.rb'
- 'lib/gitlab/git/commit.rb'
- 'lib/gitlab/git/repository.rb'
- 'lib/gitlab/git/rugged_impl/blob.rb'
- 'lib/gitlab/gitaly_client.rb'
- 'lib/gitlab/github_import/user_finder.rb'
- 'lib/gitlab/hashed_storage/migrator.rb'
- 'lib/gitlab/import_export/command_line_util.rb'
- 'lib/gitlab/multi_collection_paginator.rb'
- 'lib/gitlab/polling_interval.rb'
- 'lib/gitlab/project_search_results.rb'
- 'lib/gitlab/seeder.rb'
- 'lib/gitlab/sidekiq_cluster.rb'
- 'lib/gitlab/sidekiq_daemon/memory_killer.rb'
- 'lib/gitlab/sidekiq_middleware/memory_killer.rb'
- 'lib/gitlab/sidekiq_status.rb'
- 'lib/gitlab/slash_commands/presenters/issue_show.rb'
- 'lib/gitlab/task_helpers.rb'
- 'lib/gitlab/untrusted_regexp.rb'
- 'lib/gitlab/utils.rb'
- 'lib/system_check/sidekiq_check.rb'
- 'lib/tasks/gitlab/gitaly.rake'
- 'lib/tasks/gitlab/snippets.rake'
- 'lib/tasks/gitlab/workhorse.rake'
- 'qa/qa/git/repository.rb'
- 'qa/qa/support/wait_for_requests.rb'
- 'ee/app/models/ee/project.rb'
- 'lib/gitlab/usage_data/topology.rb'
# Offense count: 117
# Cop supports --auto-correct.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment