]> git.openstreetmap.org Git - rails.git/blob - .rubocop_todo.yml
Localisation updates from https://translatewiki.net.
[rails.git] / .rubocop_todo.yml
1 # This configuration was generated by
2 # `rubocop --auto-gen-config`
3 # on 2021-01-11 19:00:54 UTC using RuboCop version 1.8.1.
4 # The point is for the user to remove these configuration records
5 # one by one as the offenses are removed from the code base.
6 # Note that changes in the inspected code, or installation of new
7 # versions of RuboCop, may require this file to be generated again.
8
9 # Work around erblint issues.
10 # https://github.com/openstreetmap/openstreetmap-website/issues/2472
11 require:
12   - rubocop-minitest
13   - rubocop-performance
14   - rubocop-rails
15
16 # Offense count: 544
17 # Cop supports --auto-correct.
18 # Configuration parameters: AutoCorrect, AllowHeredoc, AllowURI, URISchemes, IgnoreCopDirectives, IgnoredPatterns.
19 # URISchemes: http, https
20 Layout/LineLength:
21   Max: 254
22
23 # Offense count: 36
24 # Configuration parameters: AllowSafeAssignment.
25 Lint/AssignmentInCondition:
26   Exclude:
27     - 'app/controllers/api/traces_controller.rb'
28     - 'app/controllers/api/user_preferences_controller.rb'
29     - 'app/controllers/application_controller.rb'
30     - 'app/controllers/geocoder_controller.rb'
31     - 'app/controllers/notes_controller.rb'
32     - 'app/controllers/traces_controller.rb'
33     - 'app/controllers/users_controller.rb'
34     - 'app/helpers/application_helper.rb'
35     - 'app/helpers/browse_tags_helper.rb'
36     - 'app/mailers/user_mailer.rb'
37     - 'app/models/client_application.rb'
38     - 'lib/nominatim.rb'
39     - 'lib/osm.rb'
40     - 'script/deliver-message'
41
42 # Offense count: 8
43 # Configuration parameters: IgnoreLiteralBranches, IgnoreConstantBranches.
44 Lint/DuplicateBranch:
45   Exclude:
46     - 'app/controllers/api_controller.rb'
47     - 'app/controllers/diary_entries_controller.rb'
48     - 'app/controllers/geocoder_controller.rb'
49     - 'app/helpers/browse_tags_helper.rb'
50     - 'lib/password_hash.rb'
51
52 # Offense count: 487
53 # Configuration parameters: IgnoredMethods, CountRepeatedAttributes.
54 Metrics/AbcSize:
55   Max: 235
56
57 # Offense count: 62
58 # Configuration parameters: CountComments, CountAsOne, ExcludedMethods, IgnoredMethods.
59 # IgnoredMethods: refine
60 Metrics/BlockLength:
61   Max: 71
62
63 # Offense count: 15
64 # Configuration parameters: CountBlocks.
65 Metrics/BlockNesting:
66   Max: 5
67
68 # Offense count: 24
69 # Configuration parameters: CountComments, CountAsOne.
70 Metrics/ClassLength:
71   Max: 582
72
73 # Offense count: 52
74 # Configuration parameters: IgnoredMethods.
75 Metrics/CyclomaticComplexity:
76   Max: 26
77
78 # Offense count: 553
79 # Configuration parameters: CountComments, CountAsOne, ExcludedMethods, IgnoredMethods.
80 Metrics/MethodLength:
81   Max: 179
82
83 # Offense count: 1
84 # Configuration parameters: CountKeywordArgs, MaxOptionalParameters.
85 Metrics/ParameterLists:
86   Max: 6
87
88 # Offense count: 56
89 # Configuration parameters: IgnoredMethods.
90 Metrics/PerceivedComplexity:
91   Max: 26
92
93 # Offense count: 365
94 Minitest/MultipleAssertions:
95   Max: 97
96
97 # Offense count: 4
98 Naming/AccessorMethodName:
99   Exclude:
100     - 'app/controllers/application_controller.rb'
101     - 'app/helpers/title_helper.rb'
102     - 'lib/osm.rb'
103
104 # Offense count: 8
105 # Configuration parameters: NamePrefix, ForbiddenPrefixes, AllowedMethods, MethodDefinitionMacros.
106 # NamePrefix: is_, has_, have_
107 # ForbiddenPrefixes: is_, has_, have_
108 # AllowedMethods: is_a?
109 # MethodDefinitionMacros: define_method, define_singleton_method
110 Naming/PredicateName:
111   Exclude:
112     - 'app/models/changeset.rb'
113     - 'app/models/old_node.rb'
114     - 'app/models/old_relation.rb'
115     - 'app/models/old_way.rb'
116     - 'app/models/user.rb'
117     - 'lib/classic_pagination/pagination.rb'
118
119 # Offense count: 5
120 # Configuration parameters: Database, Include.
121 # SupportedDatabases: mysql, postgresql
122 # Include: db/migrate/*.rb
123 Rails/BulkChangeTable:
124   Exclude:
125     - 'db/migrate/20111116184519_update_oauth.rb'
126     - 'db/migrate/20120208194454_add_domain_to_acl.rb'
127     - 'db/migrate/20120404205604_add_user_and_description_to_redaction.rb'
128
129 # Offense count: 2
130 # Configuration parameters: Include.
131 # Include: app/models/**/*.rb
132 Rails/HasAndBelongsToMany:
133   Exclude:
134     - 'app/models/changeset.rb'
135     - 'app/models/user.rb'
136
137 # Offense count: 3
138 # Configuration parameters: Include.
139 # Include: app/helpers/**/*.rb
140 Rails/HelperInstanceVariable:
141   Exclude:
142     - 'app/helpers/title_helper.rb'
143
144 # Offense count: 5
145 # Configuration parameters: Include.
146 # Include: db/migrate/*.rb
147 Rails/NotNullColumn:
148   Exclude:
149     - 'db/migrate/002_cleanup_osm_db.rb'
150     - 'db/migrate/020_populate_node_tags_and_remove.rb'
151     - 'db/migrate/021_move_to_innodb.rb'
152     - 'db/migrate/025_add_end_time_to_changesets.rb'
153     - 'db/migrate/20120404205604_add_user_and_description_to_redaction.rb'
154
155 # Offense count: 8
156 Rails/OutputSafety:
157   Exclude:
158     - 'app/controllers/users_controller.rb'
159     - 'app/helpers/application_helper.rb'
160     - 'lib/rich_text.rb'
161     - 'test/helpers/application_helper_test.rb'
162
163 # Offense count: 80
164 # Cop supports --auto-correct.
165 # Configuration parameters: EnforcedStyle.
166 # SupportedStyles: strict, flexible
167 Rails/TimeZone:
168   Enabled: false
169
170 # Offense count: 558
171 # Cop supports --auto-correct.
172 # Configuration parameters: EnforcedStyle.
173 # SupportedStyles: always, always_true, never
174 Style/FrozenStringLiteralComment:
175   Enabled: false
176
177 # Offense count: 54
178 # Cop supports --auto-correct.
179 # Configuration parameters: Strict.
180 Style/NumericLiterals:
181   MinDigits: 15