Update rubocop todo

This commit is contained in:
Tom Hughes 2020-07-31 19:14:32 +01:00
parent 3cf383522e
commit 06952ea2b3

View file

@ -1,26 +1,19 @@
# This configuration was generated by # This configuration was generated by
# `rubocop --auto-gen-config` # `rubocop --auto-gen-config`
# on 2019-10-19 16:05:52 +0000 using RuboCop version 0.75.0. # on 2020-07-31 18:09:40 UTC using RuboCop version 0.86.0.
# The point is for the user to remove these configuration records # The point is for the user to remove these configuration records
# one by one as the offenses are removed from the code base. # one by one as the offenses are removed from the code base.
# Note that changes in the inspected code, or installation of new # Note that changes in the inspected code, or installation of new
# versions of RuboCop, may require this file to be generated again. # versions of RuboCop, may require this file to be generated again.
# Work around erblint issues. # Offense count: 565
# https://github.com/openstreetmap/openstreetmap-website/issues/2472
require:
- rubocop-minitest
- rubocop-performance
- rubocop-rails
# Offense count: 3338
# Cop supports --auto-correct. # Cop supports --auto-correct.
# Configuration parameters: AutoCorrect, AllowHeredoc, AllowURI, URISchemes, IgnoreCopDirectives, IgnoredPatterns. # Configuration parameters: AutoCorrect, AllowHeredoc, AllowURI, URISchemes, IgnoreCopDirectives, IgnoredPatterns.
# URISchemes: http, https # URISchemes: http, https
Layout/LineLength: Layout/LineLength:
Max: 370 Max: 370
# Offense count: 35 # Offense count: 36
# Configuration parameters: AllowSafeAssignment. # Configuration parameters: AllowSafeAssignment.
Lint/AssignmentInCondition: Lint/AssignmentInCondition:
Exclude: Exclude:
@ -39,19 +32,12 @@ Lint/AssignmentInCondition:
- 'lib/osm.rb' - 'lib/osm.rb'
- 'script/deliver-message' - 'script/deliver-message'
# Offense count: 4 # Offense count: 739
# Configuration parameters: AllowComments. # Configuration parameters: IgnoredMethods.
Lint/SuppressedException:
Exclude:
- 'app/controllers/api/amf_controller.rb'
- 'app/controllers/users_controller.rb'
- 'app/controllers/site_controller.rb'
# Offense count: 701
Metrics/AbcSize: Metrics/AbcSize:
Max: 189 Max: 189
# Offense count: 39 # Offense count: 72
# Configuration parameters: CountComments, ExcludedMethods. # Configuration parameters: CountComments, ExcludedMethods.
# ExcludedMethods: refine # ExcludedMethods: refine
Metrics/BlockLength: Metrics/BlockLength:
@ -67,26 +53,23 @@ Metrics/BlockNesting:
Metrics/ClassLength: Metrics/ClassLength:
Max: 645 Max: 645
# Offense count: 74 # Offense count: 68
# Configuration parameters: IgnoredMethods.
Metrics/CyclomaticComplexity: Metrics/CyclomaticComplexity:
Max: 28 Max: 28
# Offense count: 722 # Offense count: 735
# Configuration parameters: CountComments, ExcludedMethods. # Configuration parameters: CountComments, ExcludedMethods.
Metrics/MethodLength: Metrics/MethodLength:
Max: 179 Max: 179
# Offense count: 2
# Configuration parameters: CountComments.
Metrics/ModuleLength:
Max: 117
# Offense count: 4 # Offense count: 4
# Configuration parameters: CountKeywordArgs. # Configuration parameters: CountKeywordArgs.
Metrics/ParameterLists: Metrics/ParameterLists:
Max: 9 Max: 9
# Offense count: 72 # Offense count: 73
# Configuration parameters: IgnoredMethods.
Metrics/PerceivedComplexity: Metrics/PerceivedComplexity:
Max: 25 Max: 25
@ -100,10 +83,10 @@ Naming/AccessorMethodName:
- 'lib/potlatch.rb' - 'lib/potlatch.rb'
# Offense count: 8 # Offense count: 8
# Configuration parameters: NamePrefix, NamePrefixBlacklist, NameWhitelist, MethodDefinitionMacros. # Configuration parameters: NamePrefix, ForbiddenPrefixes, AllowedMethods, MethodDefinitionMacros.
# NamePrefix: is_, has_, have_ # NamePrefix: is_, has_, have_
# NamePrefixBlacklist: is_, has_, have_ # ForbiddenPrefixes: is_, has_, have_
# NameWhitelist: is_a? # AllowedMethods: is_a?
# MethodDefinitionMacros: define_method, define_singleton_method # MethodDefinitionMacros: define_method, define_singleton_method
Naming/PredicateName: Naming/PredicateName:
Exclude: Exclude:
@ -123,14 +106,13 @@ Performance/RegexpMatch:
- 'app/validators/characters_validator.rb' - 'app/validators/characters_validator.rb'
- 'app/validators/whitespace_validator.rb' - 'app/validators/whitespace_validator.rb'
# Offense count: 6 # Offense count: 5
# Configuration parameters: Database, Include. # Configuration parameters: Database, Include.
# SupportedDatabases: mysql, postgresql # SupportedDatabases: mysql, postgresql
# Include: db/migrate/*.rb # Include: db/migrate/*.rb
Rails/BulkChangeTable: Rails/BulkChangeTable:
Exclude: Exclude:
- 'db/migrate/20111116184519_update_oauth.rb' - 'db/migrate/20111116184519_update_oauth.rb'
- 'db/migrate/20120208122334_merge_acl_address_and_mask.rb'
- 'db/migrate/20120208194454_add_domain_to_acl.rb' - 'db/migrate/20120208194454_add_domain_to_acl.rb'
- 'db/migrate/20120404205604_add_user_and_description_to_redaction.rb' - 'db/migrate/20120404205604_add_user_and_description_to_redaction.rb'
@ -162,7 +144,7 @@ Rails/NotNullColumn:
- 'db/migrate/025_add_end_time_to_changesets.rb' - 'db/migrate/025_add_end_time_to_changesets.rb'
- 'db/migrate/20120404205604_add_user_and_description_to_redaction.rb' - 'db/migrate/20120404205604_add_user_and_description_to_redaction.rb'
# Offense count: 18 # Offense count: 19
Rails/OutputSafety: Rails/OutputSafety:
Exclude: Exclude:
- 'app/controllers/users_controller.rb' - 'app/controllers/users_controller.rb'
@ -175,7 +157,7 @@ Rails/OutputSafety:
- 'lib/rich_text.rb' - 'lib/rich_text.rb'
- 'test/helpers/application_helper_test.rb' - 'test/helpers/application_helper_test.rb'
# Offense count: 94 # Offense count: 95
# Cop supports --auto-correct. # Cop supports --auto-correct.
# Configuration parameters: EnforcedStyle. # Configuration parameters: EnforcedStyle.
# SupportedStyles: strict, flexible # SupportedStyles: strict, flexible
@ -188,7 +170,7 @@ Style/AsciiComments:
Exclude: Exclude:
- 'test/models/message_test.rb' - 'test/models/message_test.rb'
# Offense count: 27 # Offense count: 32
# Configuration parameters: EnforcedStyle. # Configuration parameters: EnforcedStyle.
# SupportedStyles: annotated, template, unannotated # SupportedStyles: annotated, template, unannotated
Style/FormatStringToken: Style/FormatStringToken:
@ -201,10 +183,10 @@ Style/FormatStringToken:
- 'test/controllers/api/ways_controller_test.rb' - 'test/controllers/api/ways_controller_test.rb'
- 'test/lib/bounding_box_test.rb' - 'test/lib/bounding_box_test.rb'
# Offense count: 539 # Offense count: 572
# Cop supports --auto-correct. # Cop supports --auto-correct.
# Configuration parameters: EnforcedStyle. # Configuration parameters: EnforcedStyle.
# SupportedStyles: always, never # SupportedStyles: always, always_true, never
Style/FrozenStringLiteralComment: Style/FrozenStringLiteralComment:
Enabled: false Enabled: false
@ -214,7 +196,7 @@ Style/IfUnlessModifier:
Exclude: Exclude:
- 'app/controllers/api/ways_controller.rb' - 'app/controllers/api/ways_controller.rb'
# Offense count: 70 # Offense count: 78
# Cop supports --auto-correct. # Cop supports --auto-correct.
# Configuration parameters: Strict. # Configuration parameters: Strict.
Style/NumericLiterals: Style/NumericLiterals: