mongoid-cached-json 1.7.0 → 1.7.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.github/workflows/danger-comment.yml +10 -2
- data/.github/workflows/danger.yml +9 -2
- data/.github/workflows/lint.yml +29 -0
- data/.github/workflows/release.yml +31 -0
- data/.github/workflows/test.yml +22 -16
- data/.gitignore +1 -0
- data/.rubocop.yml +142 -3
- data/.rubocop_todo.yml +97 -75
- data/.spellcheck.txt +84 -0
- data/CHANGELOG.md +6 -2
- data/CONTRIBUTING.md +18 -19
- data/Gemfile +13 -1
- data/README.md +60 -76
- data/RELEASING.md +35 -0
- data/Rakefile +22 -3
- data/UPGRADING.md +3 -3
- data/lib/mongoid-cached-json/cached_json.rb +1 -1
- data/lib/mongoid-cached-json/version.rb +1 -1
- data/mongoid-cached-json.gemspec +1 -2
- data/script/release.rb +16 -0
- data/spec/coverage_spec.rb +44 -0
- data/spec/release/release_spec.rb +77 -0
- metadata +10 -3
data/.rubocop_todo.yml
CHANGED
|
@@ -1,23 +1,20 @@
|
|
|
1
1
|
# This configuration was generated by
|
|
2
|
-
# `rubocop --auto-gen-config`
|
|
3
|
-
#
|
|
2
|
+
# `rubocop --auto-gen-config --no-exclude-limit --no-offense-counts --no-auto-gen-timestamp`
|
|
3
|
+
# using RuboCop version 1.92.3.
|
|
4
4
|
# The point is for the user to remove these configuration records
|
|
5
5
|
# one by one as the offenses are removed from the code base.
|
|
6
6
|
# Note that changes in the inspected code, or installation of new
|
|
7
7
|
# versions of RuboCop, may require this file to be generated again.
|
|
8
8
|
|
|
9
|
-
# Offense count: 1
|
|
10
9
|
Gemspec/RequiredRubyVersion:
|
|
11
10
|
Exclude:
|
|
12
11
|
- 'mongoid-cached-json.gemspec'
|
|
13
12
|
|
|
14
|
-
# Offense count: 4
|
|
15
13
|
# This cop supports safe autocorrection (--autocorrect).
|
|
16
14
|
Layout/EmptyLineAfterGuardClause:
|
|
17
15
|
Exclude:
|
|
18
16
|
- 'lib/mongoid-cached-json/cached_json.rb'
|
|
19
17
|
|
|
20
|
-
# Offense count: 4
|
|
21
18
|
# This cop supports safe autocorrection (--autocorrect).
|
|
22
19
|
# Configuration parameters: NumberOfEmptyLines.
|
|
23
20
|
Layout/EmptyLineAfterMagicComment:
|
|
@@ -27,14 +24,12 @@ Layout/EmptyLineAfterMagicComment:
|
|
|
27
24
|
- 'lib/mongoid-cached-json/config.rb'
|
|
28
25
|
- 'lib/mongoid-cached-json/key_references.rb'
|
|
29
26
|
|
|
30
|
-
# Offense count: 16
|
|
31
27
|
# This cop supports safe autocorrection (--autocorrect).
|
|
32
28
|
# Configuration parameters: IndentationWidth.
|
|
33
29
|
# SupportedStyles: special_inside_parentheses, consistent, align_brackets
|
|
34
30
|
Layout/FirstArrayElementIndentation:
|
|
35
31
|
EnforcedStyle: consistent
|
|
36
32
|
|
|
37
|
-
# Offense count: 1
|
|
38
33
|
# This cop supports safe autocorrection (--autocorrect).
|
|
39
34
|
# Configuration parameters: AllowMultipleStyles, EnforcedHashRocketStyle, EnforcedColonStyle, EnforcedLastArgumentHashStyle.
|
|
40
35
|
# SupportedHashRocketStyles: key, separator, table
|
|
@@ -44,7 +39,6 @@ Layout/HashAlignment:
|
|
|
44
39
|
Exclude:
|
|
45
40
|
- 'lib/mongoid-cached-json/cached_json.rb'
|
|
46
41
|
|
|
47
|
-
# Offense count: 1
|
|
48
42
|
# This cop supports safe autocorrection (--autocorrect).
|
|
49
43
|
# Configuration parameters: EnforcedStyle.
|
|
50
44
|
# SupportedStyles: symmetrical, new_line, same_line
|
|
@@ -52,7 +46,6 @@ Layout/MultilineArrayBraceLayout:
|
|
|
52
46
|
Exclude:
|
|
53
47
|
- 'spec/cached_json_spec.rb'
|
|
54
48
|
|
|
55
|
-
# Offense count: 4
|
|
56
49
|
# This cop supports safe autocorrection (--autocorrect).
|
|
57
50
|
# Configuration parameters: EnforcedStyle.
|
|
58
51
|
# SupportedStyles: symmetrical, new_line, same_line
|
|
@@ -60,7 +53,6 @@ Layout/MultilineHashBraceLayout:
|
|
|
60
53
|
Exclude:
|
|
61
54
|
- 'spec/cached_json_spec.rb'
|
|
62
55
|
|
|
63
|
-
# Offense count: 2
|
|
64
56
|
# This cop supports safe autocorrection (--autocorrect).
|
|
65
57
|
# Configuration parameters: EnforcedStyle.
|
|
66
58
|
# SupportedStyles: symmetrical, new_line, same_line
|
|
@@ -68,14 +60,12 @@ Layout/MultilineMethodCallBraceLayout:
|
|
|
68
60
|
Exclude:
|
|
69
61
|
- 'spec/cached_json_spec.rb'
|
|
70
62
|
|
|
71
|
-
# Offense count: 1
|
|
72
63
|
# This cop supports unsafe autocorrection (--autocorrect-all).
|
|
73
64
|
# Configuration parameters: AllowSafeAssignment.
|
|
74
65
|
Lint/AssignmentInCondition:
|
|
75
66
|
Exclude:
|
|
76
67
|
- 'lib/mongoid-cached-json/cached_json.rb'
|
|
77
68
|
|
|
78
|
-
# Offense count: 7
|
|
79
69
|
# Configuration parameters: AllowedMethods.
|
|
80
70
|
# AllowedMethods: enums
|
|
81
71
|
Lint/ConstantDefinitionInBlock:
|
|
@@ -85,71 +75,72 @@ Lint/ConstantDefinitionInBlock:
|
|
|
85
75
|
- 'spec/field_cache_spec.rb'
|
|
86
76
|
- 'spec/model_cache_spec.rb'
|
|
87
77
|
|
|
88
|
-
# Offense count: 1
|
|
89
78
|
# This cop supports unsafe autocorrection (--autocorrect-all).
|
|
90
79
|
Lint/NonDeterministicRequireOrder:
|
|
91
80
|
Exclude:
|
|
92
81
|
- 'spec/spec_helper.rb'
|
|
93
82
|
|
|
94
|
-
# Offense count: 1
|
|
95
83
|
# Configuration parameters: AllowKeywordBlockArguments.
|
|
96
84
|
Lint/UnderscorePrefixedVariableName:
|
|
97
85
|
Exclude:
|
|
98
86
|
- 'lib/mongoid-cached-json/cached_json.rb'
|
|
99
87
|
|
|
100
|
-
# Offense count: 2
|
|
101
88
|
# This cop supports safe autocorrection (--autocorrect).
|
|
102
89
|
Lint/UselessAssignment:
|
|
103
90
|
Exclude:
|
|
104
91
|
- 'lib/mongoid-cached-json/cached_json.rb'
|
|
105
92
|
- 'spec/cached_json_spec.rb'
|
|
106
93
|
|
|
107
|
-
#
|
|
108
|
-
# Configuration parameters: AllowedMethods, AllowedPatterns, CountRepeatedAttributes.
|
|
94
|
+
# Configuration parameters: AllowedMethods, AllowedPatterns, CountRepeatedAttributes, Max.
|
|
109
95
|
Metrics/AbcSize:
|
|
110
|
-
|
|
96
|
+
Exclude:
|
|
97
|
+
- 'lib/mongoid-cached-json/cached_json.rb'
|
|
111
98
|
|
|
112
|
-
#
|
|
113
|
-
# Configuration parameters: CountComments, CountAsOne, AllowedMethods, AllowedPatterns.
|
|
99
|
+
# Configuration parameters: CountComments, Max, CountAsOne, AllowedMethods, AllowedPatterns.
|
|
114
100
|
# AllowedMethods: refine
|
|
115
101
|
Metrics/BlockLength:
|
|
116
|
-
|
|
102
|
+
Exclude:
|
|
103
|
+
- 'spec/all_fields_spec.rb'
|
|
104
|
+
- 'spec/array_spec.rb'
|
|
105
|
+
- 'spec/benchmark_spec.rb'
|
|
106
|
+
- 'spec/cache_version_spec.rb'
|
|
107
|
+
- 'spec/cached_json_spec.rb'
|
|
108
|
+
- 'spec/coverage_spec.rb'
|
|
109
|
+
- 'spec/dalli_spec.rb'
|
|
110
|
+
- 'spec/field_cache_spec.rb'
|
|
111
|
+
- 'spec/hash_spec.rb'
|
|
112
|
+
- 'spec/model_cache_spec.rb'
|
|
113
|
+
- 'spec/mongoid_criteria_spec.rb'
|
|
117
114
|
|
|
118
|
-
#
|
|
119
|
-
# Configuration parameters: CountBlocks, CountModifierForms.
|
|
115
|
+
# Configuration parameters: CountBlocks, CountModifierForms, Max.
|
|
120
116
|
Metrics/BlockNesting:
|
|
121
|
-
|
|
117
|
+
Exclude:
|
|
118
|
+
- 'lib/mongoid-cached-json/cached_json.rb'
|
|
122
119
|
|
|
123
|
-
#
|
|
124
|
-
# Configuration parameters: AllowedMethods, AllowedPatterns.
|
|
120
|
+
# Configuration parameters: AllowedMethods, AllowedPatterns, Max.
|
|
125
121
|
Metrics/CyclomaticComplexity:
|
|
126
|
-
|
|
122
|
+
Exclude:
|
|
123
|
+
- 'lib/mongoid-cached-json/cached_json.rb'
|
|
127
124
|
|
|
128
|
-
#
|
|
129
|
-
# Configuration parameters: CountComments, CountAsOne, AllowedMethods, AllowedPatterns.
|
|
125
|
+
# Configuration parameters: CountComments, Max, CountAsOne, AllowedMethods, AllowedPatterns.
|
|
130
126
|
Metrics/MethodLength:
|
|
131
|
-
|
|
127
|
+
Exclude:
|
|
128
|
+
- 'lib/mongoid-cached-json/array.rb'
|
|
129
|
+
- 'lib/mongoid-cached-json/cached_json.rb'
|
|
130
|
+
- 'lib/mongoid-cached-json/config.rb'
|
|
131
|
+
- 'lib/mongoid-cached-json/hash.rb'
|
|
132
|
+
- 'lib/mongoid-cached-json/mongoid_criteria.rb'
|
|
132
133
|
|
|
133
|
-
#
|
|
134
|
-
# Configuration parameters: CountComments, CountAsOne.
|
|
134
|
+
# Configuration parameters: CountComments, Max, CountAsOne.
|
|
135
135
|
Metrics/ModuleLength:
|
|
136
|
-
|
|
136
|
+
Exclude:
|
|
137
|
+
- 'lib/mongoid-cached-json/cached_json.rb'
|
|
137
138
|
|
|
138
|
-
#
|
|
139
|
-
# Configuration parameters: AllowedMethods, AllowedPatterns.
|
|
139
|
+
# Configuration parameters: AllowedMethods, AllowedPatterns, Max.
|
|
140
140
|
Metrics/PerceivedComplexity:
|
|
141
|
-
Max: 22
|
|
142
|
-
|
|
143
|
-
# Offense count: 1
|
|
144
|
-
# Configuration parameters: ExpectMatchingDefinition, CheckDefinitionPathHierarchy, CheckDefinitionPathHierarchyRoots, Regex, IgnoreExecutableScripts, AllowedAcronyms.
|
|
145
|
-
# CheckDefinitionPathHierarchyRoots: lib, spec, test, src
|
|
146
|
-
# AllowedAcronyms: CLI, DSL, ACL, API, ASCII, CPU, CSS, DNS, EOF, GUID, HTML, HTTP, HTTPS, ID, IP, JSON, LHS, QPS, RAM, RHS, RPC, SLA, SMTP, SQL, SSH, TCP, TLS, TTL, UDP, UI, UID, UUID, URI, URL, UTF8, VM, XML, XMPP, XSRF, XSS
|
|
147
|
-
Naming/FileName:
|
|
148
141
|
Exclude:
|
|
149
|
-
- '
|
|
150
|
-
- 'lib/mongoid-cached-json.rb'
|
|
142
|
+
- 'lib/mongoid-cached-json/cached_json.rb'
|
|
151
143
|
|
|
152
|
-
# Offense count: 1
|
|
153
144
|
# This cop supports safe autocorrection (--autocorrect).
|
|
154
145
|
# Configuration parameters: EnforcedStyle.
|
|
155
146
|
# SupportedStyles: prefer_alias, prefer_alias_method
|
|
@@ -157,7 +148,6 @@ Style/Alias:
|
|
|
157
148
|
Exclude:
|
|
158
149
|
- 'lib/mongoid-cached-json/cached_json.rb'
|
|
159
150
|
|
|
160
|
-
# Offense count: 1
|
|
161
151
|
# This cop supports safe autocorrection (--autocorrect).
|
|
162
152
|
# Configuration parameters: EnforcedStyle, SingleLineConditionsOnly, IncludeTernaryExpressions.
|
|
163
153
|
# SupportedStyles: assign_to_condition, assign_inside_condition
|
|
@@ -165,12 +155,9 @@ Style/ConditionalAssignment:
|
|
|
165
155
|
Exclude:
|
|
166
156
|
- 'lib/mongoid-cached-json/cached_json.rb'
|
|
167
157
|
|
|
168
|
-
# Offense count: 7
|
|
169
158
|
# Configuration parameters: AllowedConstants.
|
|
170
159
|
Style/Documentation:
|
|
171
160
|
Exclude:
|
|
172
|
-
- 'spec/**/*'
|
|
173
|
-
- 'test/**/*'
|
|
174
161
|
- 'lib/mongoid-cached-json/array.rb'
|
|
175
162
|
- 'lib/mongoid-cached-json/cached_json.rb'
|
|
176
163
|
- 'lib/mongoid-cached-json/config.rb'
|
|
@@ -178,7 +165,6 @@ Style/Documentation:
|
|
|
178
165
|
- 'lib/mongoid-cached-json/key_references.rb'
|
|
179
166
|
- 'lib/mongoid-cached-json/mongoid_criteria.rb'
|
|
180
167
|
|
|
181
|
-
# Offense count: 2
|
|
182
168
|
# This cop supports unsafe autocorrection (--autocorrect-all).
|
|
183
169
|
# Configuration parameters: EnforcedStyle.
|
|
184
170
|
# SupportedStyles: allowed_in_returns, forbidden
|
|
@@ -186,13 +172,11 @@ Style/DoubleNegation:
|
|
|
186
172
|
Exclude:
|
|
187
173
|
- 'lib/mongoid-cached-json/cached_json.rb'
|
|
188
174
|
|
|
189
|
-
# Offense count: 1
|
|
190
175
|
# This cop supports safe autocorrection (--autocorrect).
|
|
191
176
|
Style/EachWithObject:
|
|
192
177
|
Exclude:
|
|
193
178
|
- 'lib/mongoid-cached-json/hash.rb'
|
|
194
179
|
|
|
195
|
-
# Offense count: 3
|
|
196
180
|
# This cop supports safe autocorrection (--autocorrect).
|
|
197
181
|
Style/Encoding:
|
|
198
182
|
Exclude:
|
|
@@ -200,27 +184,73 @@ Style/Encoding:
|
|
|
200
184
|
- 'lib/mongoid-cached-json/cached_json.rb'
|
|
201
185
|
- 'lib/mongoid-cached-json/config.rb'
|
|
202
186
|
|
|
203
|
-
# Offense count: 1
|
|
204
187
|
# This cop supports safe autocorrection (--autocorrect).
|
|
205
188
|
Style/EvalWithLocation:
|
|
206
189
|
Exclude:
|
|
207
190
|
- 'lib/mongoid-cached-json/config.rb'
|
|
208
191
|
|
|
209
|
-
# Offense count: 50
|
|
210
192
|
# This cop supports unsafe autocorrection (--autocorrect-all).
|
|
211
193
|
# Configuration parameters: EnforcedStyle.
|
|
212
194
|
# SupportedStyles: always, always_true, never
|
|
213
195
|
Style/FrozenStringLiteralComment:
|
|
214
|
-
|
|
196
|
+
Exclude:
|
|
197
|
+
- 'Gemfile'
|
|
198
|
+
- 'Rakefile'
|
|
199
|
+
- 'lib/mongoid-cached-json.rb'
|
|
200
|
+
- 'lib/mongoid-cached-json/array.rb'
|
|
201
|
+
- 'lib/mongoid-cached-json/cached_json.rb'
|
|
202
|
+
- 'lib/mongoid-cached-json/config.rb'
|
|
203
|
+
- 'lib/mongoid-cached-json/hash.rb'
|
|
204
|
+
- 'lib/mongoid-cached-json/key_references.rb'
|
|
205
|
+
- 'lib/mongoid-cached-json/mongoid_criteria.rb'
|
|
206
|
+
- 'lib/mongoid-cached-json/version.rb'
|
|
207
|
+
- 'mongoid-cached-json.gemspec'
|
|
208
|
+
- 'spec/all_fields_spec.rb'
|
|
209
|
+
- 'spec/array_spec.rb'
|
|
210
|
+
- 'spec/benchmark_spec.rb'
|
|
211
|
+
- 'spec/cache_version_spec.rb'
|
|
212
|
+
- 'spec/cached_json_spec.rb'
|
|
213
|
+
- 'spec/config_spec.rb'
|
|
214
|
+
- 'spec/coverage_spec.rb'
|
|
215
|
+
- 'spec/dalli_spec.rb'
|
|
216
|
+
- 'spec/field_cache_spec.rb'
|
|
217
|
+
- 'spec/hash_spec.rb'
|
|
218
|
+
- 'spec/model_cache_spec.rb'
|
|
219
|
+
- 'spec/mongoid_criteria_spec.rb'
|
|
220
|
+
- 'spec/spec_helper.rb'
|
|
221
|
+
- 'spec/support/awesome_artwork.rb'
|
|
222
|
+
- 'spec/support/awesome_image.rb'
|
|
223
|
+
- 'spec/support/fast_json_artwork.rb'
|
|
224
|
+
- 'spec/support/fast_json_image.rb'
|
|
225
|
+
- 'spec/support/fast_json_url.rb'
|
|
226
|
+
- 'spec/support/json_embedded_foobar.rb'
|
|
227
|
+
- 'spec/support/json_employee.rb'
|
|
228
|
+
- 'spec/support/json_foobar.rb'
|
|
229
|
+
- 'spec/support/json_manager.rb'
|
|
230
|
+
- 'spec/support/json_math.rb'
|
|
231
|
+
- 'spec/support/json_parent_foobar.rb'
|
|
232
|
+
- 'spec/support/json_polymorphic_embedded_foobar.rb'
|
|
233
|
+
- 'spec/support/json_polymorphic_referenced_foobar.rb'
|
|
234
|
+
- 'spec/support/json_referenced_foobar.rb'
|
|
235
|
+
- 'spec/support/json_supervisor.rb'
|
|
236
|
+
- 'spec/support/json_transform.rb'
|
|
237
|
+
- 'spec/support/matchers/invalidate.rb'
|
|
238
|
+
- 'spec/support/person.rb'
|
|
239
|
+
- 'spec/support/poly_company.rb'
|
|
240
|
+
- 'spec/support/poly_person.rb'
|
|
241
|
+
- 'spec/support/poly_post.rb'
|
|
242
|
+
- 'spec/support/prison_cell.rb'
|
|
243
|
+
- 'spec/support/prison_inmate.rb'
|
|
244
|
+
- 'spec/support/secret_parent.rb'
|
|
245
|
+
- 'spec/support/sometimes_secret.rb'
|
|
246
|
+
- 'spec/support/tool.rb'
|
|
247
|
+
- 'spec/support/tool_box.rb'
|
|
215
248
|
|
|
216
|
-
# Offense count: 5
|
|
217
249
|
# This cop supports safe autocorrection (--autocorrect).
|
|
218
250
|
Style/IfUnlessModifier:
|
|
219
251
|
Exclude:
|
|
220
252
|
- 'lib/mongoid-cached-json/cached_json.rb'
|
|
221
|
-
- 'spec/cached_json_spec.rb'
|
|
222
253
|
|
|
223
|
-
# Offense count: 5
|
|
224
254
|
# This cop supports safe autocorrection (--autocorrect).
|
|
225
255
|
# Configuration parameters: EnforcedStyle.
|
|
226
256
|
# SupportedStyles: line_count_dependent, lambda, literal
|
|
@@ -232,7 +262,6 @@ Style/Lambda:
|
|
|
232
262
|
- 'spec/support/poly_person.rb'
|
|
233
263
|
- 'spec/support/sometimes_secret.rb'
|
|
234
264
|
|
|
235
|
-
# Offense count: 1
|
|
236
265
|
# This cop supports unsafe autocorrection (--autocorrect-all).
|
|
237
266
|
# Configuration parameters: EnforcedStyle, Autocorrect.
|
|
238
267
|
# SupportedStyles: module_function, extend_self, forbidden
|
|
@@ -240,7 +269,6 @@ Style/ModuleFunction:
|
|
|
240
269
|
Exclude:
|
|
241
270
|
- 'lib/mongoid-cached-json/config.rb'
|
|
242
271
|
|
|
243
|
-
# Offense count: 1
|
|
244
272
|
# This cop supports unsafe autocorrection (--autocorrect-all).
|
|
245
273
|
# Configuration parameters: EnforcedStyle, Recursive.
|
|
246
274
|
# SupportedStyles: literals, strict
|
|
@@ -248,27 +276,23 @@ Style/MutableConstant:
|
|
|
248
276
|
Exclude:
|
|
249
277
|
- 'lib/mongoid-cached-json/version.rb'
|
|
250
278
|
|
|
251
|
-
# Offense count: 1
|
|
252
279
|
# Configuration parameters: AllowedMethods.
|
|
253
280
|
# AllowedMethods: respond_to_missing?
|
|
254
281
|
Style/OptionalBooleanParameter:
|
|
255
282
|
Exclude:
|
|
256
283
|
- 'lib/mongoid-cached-json/cached_json.rb'
|
|
257
284
|
|
|
258
|
-
# Offense count: 3
|
|
259
285
|
# This cop supports safe autocorrection (--autocorrect).
|
|
260
286
|
Style/OrAssignment:
|
|
261
287
|
Exclude:
|
|
262
288
|
- 'lib/mongoid-cached-json/cached_json.rb'
|
|
263
289
|
|
|
264
|
-
# Offense count: 2
|
|
265
290
|
# This cop supports safe autocorrection (--autocorrect).
|
|
266
291
|
# Configuration parameters: PreferredDelimiters.
|
|
267
292
|
Style/PercentLiteralDelimiters:
|
|
268
293
|
Exclude:
|
|
269
294
|
- 'spec/array_spec.rb'
|
|
270
295
|
|
|
271
|
-
# Offense count: 1
|
|
272
296
|
# This cop supports unsafe autocorrection (--autocorrect-all).
|
|
273
297
|
# Configuration parameters: EnforcedStyle, AllowedCompactTypes.
|
|
274
298
|
# SupportedStyles: compact, exploded
|
|
@@ -276,13 +300,11 @@ Style/RaiseArgs:
|
|
|
276
300
|
Exclude:
|
|
277
301
|
- 'lib/mongoid-cached-json/cached_json.rb'
|
|
278
302
|
|
|
279
|
-
# Offense count: 1
|
|
280
303
|
# This cop supports unsafe autocorrection (--autocorrect-all).
|
|
281
304
|
Style/RedundantInterpolation:
|
|
282
305
|
Exclude:
|
|
283
306
|
- 'spec/cached_json_spec.rb'
|
|
284
307
|
|
|
285
|
-
# Offense count: 2
|
|
286
308
|
# This cop supports unsafe autocorrection (--autocorrect-all).
|
|
287
309
|
# Configuration parameters: ConvertCodeThatCanStartToReturnNil, AllowedMethods, MaxChainLength.
|
|
288
310
|
# AllowedMethods: present?, blank?, presence, try, try!
|
|
@@ -291,7 +313,6 @@ Style/SafeNavigation:
|
|
|
291
313
|
- 'lib/mongoid-cached-json/cached_json.rb'
|
|
292
314
|
- 'lib/mongoid-cached-json/key_references.rb'
|
|
293
315
|
|
|
294
|
-
# Offense count: 2
|
|
295
316
|
# This cop supports safe autocorrection (--autocorrect).
|
|
296
317
|
# Configuration parameters: EnforcedStyle.
|
|
297
318
|
# SupportedStyles: only_raise, only_fail, semantic
|
|
@@ -300,14 +321,13 @@ Style/SignalException:
|
|
|
300
321
|
- 'lib/mongoid-cached-json/cached_json.rb'
|
|
301
322
|
- 'spec/cached_json_spec.rb'
|
|
302
323
|
|
|
303
|
-
# Offense count: 14
|
|
304
324
|
# This cop supports safe autocorrection (--autocorrect).
|
|
305
|
-
# Configuration parameters:
|
|
325
|
+
# Configuration parameters: .
|
|
306
326
|
# SupportedStyles: percent, brackets
|
|
307
327
|
Style/SymbolArray:
|
|
308
|
-
EnforcedStyle:
|
|
328
|
+
EnforcedStyle: percent
|
|
329
|
+
MinSize: 22
|
|
309
330
|
|
|
310
|
-
# Offense count: 1
|
|
311
331
|
# This cop supports unsafe autocorrection (--autocorrect-all).
|
|
312
332
|
# Configuration parameters: AllowMethodsWithArguments, AllowedMethods, AllowedPatterns, AllowComments.
|
|
313
333
|
# AllowedMethods: define_method
|
|
@@ -315,7 +335,6 @@ Style/SymbolProc:
|
|
|
315
335
|
Exclude:
|
|
316
336
|
- 'spec/support/json_manager.rb'
|
|
317
337
|
|
|
318
|
-
# Offense count: 1
|
|
319
338
|
# This cop supports safe autocorrection (--autocorrect).
|
|
320
339
|
# Configuration parameters: EnforcedStyle, AllowSafeAssignment.
|
|
321
340
|
# SupportedStyles: require_parentheses, require_no_parentheses, require_parentheses_when_complex
|
|
@@ -323,9 +342,12 @@ Style/TernaryParentheses:
|
|
|
323
342
|
Exclude:
|
|
324
343
|
- 'lib/mongoid-cached-json/cached_json.rb'
|
|
325
344
|
|
|
326
|
-
# Offense count: 56
|
|
327
345
|
# This cop supports safe autocorrection (--autocorrect).
|
|
328
|
-
# Configuration parameters: AllowHeredoc, AllowURI, AllowQualifiedName, URISchemes, AllowRBSInlineAnnotation, AllowCopDirectives, AllowedPatterns, SplitStrings.
|
|
346
|
+
# Configuration parameters: Max, AllowHeredoc, AllowURI, AllowQualifiedName, URISchemes, AllowRBSInlineAnnotation, AllowCopDirectives, AllowedPatterns, SplitStrings.
|
|
329
347
|
# URISchemes: http, https
|
|
348
|
+
# AllowedPatterns: (?-mix:^\#)
|
|
330
349
|
Layout/LineLength:
|
|
331
|
-
|
|
350
|
+
Exclude:
|
|
351
|
+
- 'lib/mongoid-cached-json/cached_json.rb'
|
|
352
|
+
- 'spec/cached_json_spec.rb'
|
|
353
|
+
- 'spec/mongoid_criteria_spec.rb'
|
data/.spellcheck.txt
ADDED
|
@@ -0,0 +1,84 @@
|
|
|
1
|
+
aaw
|
|
2
|
+
ActiveSupport
|
|
3
|
+
allowlist
|
|
4
|
+
api
|
|
5
|
+
APIs
|
|
6
|
+
BAZ
|
|
7
|
+
Baz
|
|
8
|
+
Benchmarking
|
|
9
|
+
Bundler
|
|
10
|
+
CachedJson
|
|
11
|
+
CHANGELOG
|
|
12
|
+
Changelog
|
|
13
|
+
changelog
|
|
14
|
+
changelogs
|
|
15
|
+
Config
|
|
16
|
+
Dalli
|
|
17
|
+
dblock
|
|
18
|
+
defs
|
|
19
|
+
Doubrovkine
|
|
20
|
+
DOWNCASE
|
|
21
|
+
downcase
|
|
22
|
+
DSL
|
|
23
|
+
eg
|
|
24
|
+
eLiTe
|
|
25
|
+
Gemfile
|
|
26
|
+
gemspec
|
|
27
|
+
HABTM
|
|
28
|
+
habtm
|
|
29
|
+
JRuby
|
|
30
|
+
JSON
|
|
31
|
+
json
|
|
32
|
+
json's
|
|
33
|
+
JsonEmployee
|
|
34
|
+
JsonFoobar
|
|
35
|
+
JsonManager
|
|
36
|
+
JsonSupervisor
|
|
37
|
+
linter
|
|
38
|
+
localhost
|
|
39
|
+
lookups
|
|
40
|
+
Macreery
|
|
41
|
+
macreery
|
|
42
|
+
marbemac
|
|
43
|
+
matcher
|
|
44
|
+
md
|
|
45
|
+
memcached
|
|
46
|
+
MemoryStore
|
|
47
|
+
Mongoid
|
|
48
|
+
mongoid
|
|
49
|
+
MongoidCachedJsonRelease
|
|
50
|
+
mzikherman
|
|
51
|
+
namespace
|
|
52
|
+
Naz
|
|
53
|
+
nitpicky
|
|
54
|
+
param
|
|
55
|
+
Pathy
|
|
56
|
+
PlainCoverageDocument
|
|
57
|
+
PolyCompany
|
|
58
|
+
PolyPerson
|
|
59
|
+
prefetch
|
|
60
|
+
PrisonInmate
|
|
61
|
+
Quickstart
|
|
62
|
+
Rakefile
|
|
63
|
+
rb
|
|
64
|
+
rdoc
|
|
65
|
+
README
|
|
66
|
+
Rebase
|
|
67
|
+
rebase
|
|
68
|
+
roundtrips
|
|
69
|
+
RSpec
|
|
70
|
+
RuboCop
|
|
71
|
+
rubocop
|
|
72
|
+
RubyGems
|
|
73
|
+
schemas
|
|
74
|
+
SimpleCov
|
|
75
|
+
Taz
|
|
76
|
+
ToolBox
|
|
77
|
+
TransformCoverageDocument
|
|
78
|
+
TTL
|
|
79
|
+
uncached
|
|
80
|
+
unmaterialized
|
|
81
|
+
UPCASE
|
|
82
|
+
upcase
|
|
83
|
+
updatedBAR
|
|
84
|
+
YAML
|
data/CHANGELOG.md
CHANGED
|
@@ -1,6 +1,10 @@
|
|
|
1
|
-
### 1.7.1 (
|
|
1
|
+
### 1.7.1 (2026/11/24)
|
|
2
2
|
|
|
3
|
-
*
|
|
3
|
+
* [#40](https://github.com/mongoid/mongoid-cached-json/pull/40): Cover plain criteria and uncached transforms, and combine coverage across actual legacy and modern association APIs - [@dblock](https://github.com/dblock).
|
|
4
|
+
* [#46](https://github.com/mongoid/mongoid-cached-json/pull/46): Upgrade danger-pr-comment to 0.3.0 from the `danger` organization and skip empty Danger report comments - [@dblock](https://github.com/dblock).
|
|
5
|
+
* [#42](https://github.com/mongoid/mongoid-cached-json/pull/42): Lint Markdown, YAML, and spelling with rubocop-md, rubocop-prose, rubocop-spellcheck, and rubocop-yaml in a separate Lint workflow, and clean up documentation - [@dblock](https://github.com/dblock).
|
|
6
|
+
* [#43](https://github.com/mongoid/mongoid-cached-json/pull/43): Run CI pushes only on the default branch, cancel superseded pull request runs, skip duplicate lint in the test matrix, and bound job times - [@dblock](https://github.com/dblock).
|
|
7
|
+
* [#44](https://github.com/mongoid/mongoid-cached-json/pull/44): Release with ruby-gem-release from a manually dispatched GitHub Actions workflow using RubyGems Trusted Publishing, with dry runs - [@dblock](https://github.com/dblock).
|
|
4
8
|
|
|
5
9
|
### 1.7.0 (2026/10/16)
|
|
6
10
|
|
data/CONTRIBUTING.md
CHANGED
|
@@ -1,23 +1,22 @@
|
|
|
1
|
-
Contributing to Mongoid::CachedJson
|
|
2
|
-
===================================
|
|
1
|
+
# Contributing to Mongoid::CachedJson
|
|
3
2
|
|
|
4
|
-
Mongoid::CachedJson is work of [many
|
|
3
|
+
Mongoid::CachedJson is the work of [many contributors](https://github.com/mongoid/mongoid-cached-json/graphs/contributors). You're encouraged to submit [pull requests](https://github.com/mongoid/mongoid-cached-json/pulls), [propose features and discuss issues](https://github.com/mongoid/mongoid-cached-json/issues). When in doubt, ask a question in the [Google Group](http://groups.google.com/group/mongoid-cached-json).
|
|
5
4
|
|
|
6
|
-
|
|
5
|
+
## Fork the Project
|
|
7
6
|
|
|
8
|
-
Fork the [project on
|
|
7
|
+
Fork the [project on GitHub](https://github.com/mongoid/mongoid-cached-json) and check out your copy.
|
|
9
8
|
|
|
10
|
-
```
|
|
9
|
+
```sh
|
|
11
10
|
git clone https://github.com/contributor/mongoid-cached-json.git
|
|
12
11
|
cd mongoid-cached-json
|
|
13
12
|
git remote add upstream https://github.com/mongoid/mongoid-cached-json.git
|
|
14
13
|
```
|
|
15
14
|
|
|
16
|
-
|
|
15
|
+
### Create a Topic Branch
|
|
17
16
|
|
|
18
17
|
Make sure your fork is up-to-date and create a topic branch for your feature or bug fix.
|
|
19
18
|
|
|
20
|
-
```
|
|
19
|
+
```sh
|
|
21
20
|
git checkout master
|
|
22
21
|
git pull upstream master
|
|
23
22
|
git checkout -b my-feature-branch
|
|
@@ -27,7 +26,7 @@ git checkout -b my-feature-branch
|
|
|
27
26
|
|
|
28
27
|
MongoDB and Memcached are required, use your favorite OS installer.
|
|
29
28
|
|
|
30
|
-
```
|
|
29
|
+
```sh
|
|
31
30
|
brew install mongodb
|
|
32
31
|
brew install memcached
|
|
33
32
|
```
|
|
@@ -36,7 +35,7 @@ brew install memcached
|
|
|
36
35
|
|
|
37
36
|
Ensure that you can build the project and run tests.
|
|
38
37
|
|
|
39
|
-
```
|
|
38
|
+
```sh
|
|
40
39
|
bundle install
|
|
41
40
|
bundle exec rake
|
|
42
41
|
```
|
|
@@ -51,7 +50,7 @@ We definitely appreciate pull requests that highlight or reproduce a problem, ev
|
|
|
51
50
|
|
|
52
51
|
Implement your feature or bug fix.
|
|
53
52
|
|
|
54
|
-
Ruby style is enforced with [
|
|
53
|
+
Ruby style is enforced with [RuboCop](https://github.com/bbatsov/rubocop), run `bundle exec rubocop` and fix any style issues highlighted.
|
|
55
54
|
|
|
56
55
|
Make sure that `bundle exec rake` completes without errors.
|
|
57
56
|
|
|
@@ -61,7 +60,7 @@ Document any external behavior in the [README](README.md).
|
|
|
61
60
|
|
|
62
61
|
#### Update Changelog
|
|
63
62
|
|
|
64
|
-
Add a line to [CHANGELOG](CHANGELOG.md) under *Next Release*. Make it look like every other line, including your name and link to your
|
|
63
|
+
Add a line to [CHANGELOG](CHANGELOG.md) under *Next Release*. Make it look like every other line, including your name and link to your GitHub account.
|
|
65
64
|
|
|
66
65
|
Danger checks pull requests with `danger-changelog` and reports missing changelog entries in a PR comment. Include the pull request number in your entry once it is available.
|
|
67
66
|
|
|
@@ -69,21 +68,21 @@ Danger checks pull requests with `danger-changelog` and reports missing changelo
|
|
|
69
68
|
|
|
70
69
|
Make sure git knows your name and email address:
|
|
71
70
|
|
|
72
|
-
```
|
|
71
|
+
```sh
|
|
73
72
|
git config --global user.name "Your Name"
|
|
74
73
|
git config --global user.email "contributor@example.com"
|
|
75
74
|
```
|
|
76
75
|
|
|
77
76
|
Writing good commit logs is important. A commit log should describe what changed and why.
|
|
78
77
|
|
|
79
|
-
```
|
|
78
|
+
```sh
|
|
80
79
|
git add ...
|
|
81
80
|
git commit
|
|
82
81
|
```
|
|
83
82
|
|
|
84
83
|
#### Push
|
|
85
84
|
|
|
86
|
-
```
|
|
85
|
+
```sh
|
|
87
86
|
git push origin my-feature-branch
|
|
88
87
|
```
|
|
89
88
|
|
|
@@ -95,7 +94,7 @@ Go to https://github.com/contributor/mongoid-cached-json and select your feature
|
|
|
95
94
|
|
|
96
95
|
If you've been working on a change for a while, rebase with upstream/master.
|
|
97
96
|
|
|
98
|
-
```
|
|
97
|
+
```sh
|
|
99
98
|
git fetch upstream
|
|
100
99
|
git rebase upstream/master
|
|
101
100
|
git push origin my-feature-branch -f
|
|
@@ -105,20 +104,20 @@ git push origin my-feature-branch -f
|
|
|
105
104
|
|
|
106
105
|
Update the [CHANGELOG](CHANGELOG.md) with the pull request number. A typical entry looks as follows.
|
|
107
106
|
|
|
108
|
-
```
|
|
107
|
+
```markdown
|
|
109
108
|
* [#123](https://github.com/mongoid/mongoid-cached-json/pull/123): Reticulated splines - [@contributor](https://github.com/contributor).
|
|
110
109
|
```
|
|
111
110
|
|
|
112
111
|
Amend your previous commit and force push the changes.
|
|
113
112
|
|
|
114
|
-
```
|
|
113
|
+
```sh
|
|
115
114
|
git commit --amend
|
|
116
115
|
git push origin my-feature-branch -f
|
|
117
116
|
```
|
|
118
117
|
|
|
119
118
|
#### Check on Your Pull Request
|
|
120
119
|
|
|
121
|
-
Go back to your pull request after a few minutes and see whether it passed muster with
|
|
120
|
+
Go back to your pull request after a few minutes and see whether it passed muster with GitHub Actions. Everything should look green, otherwise fix issues and amend your commit as described above.
|
|
122
121
|
|
|
123
122
|
#### Be Patient
|
|
124
123
|
|
data/Gemfile
CHANGED
|
@@ -16,7 +16,6 @@ group :development do
|
|
|
16
16
|
gem 'dalli', RUBY_VERSION >= '3.0' ? '~> 3.0' : '~> 2.6'
|
|
17
17
|
gem 'rake'
|
|
18
18
|
gem 'rdoc', RUBY_VERSION >= '3.0' ? '>= 6' : '~> 4.2'
|
|
19
|
-
gem 'rubocop', ENV.fetch('RUBOCOP_VERSION', '>= 0')
|
|
20
19
|
gem 'yard', '~> 0.6'
|
|
21
20
|
end
|
|
22
21
|
|
|
@@ -25,3 +24,16 @@ group :test do
|
|
|
25
24
|
gem 'rspec', '~> 3.1'
|
|
26
25
|
gem 'simplecov', '~> 0.22' if ENV['COVERAGE'] == 'true'
|
|
27
26
|
end
|
|
27
|
+
|
|
28
|
+
group :development, :test do
|
|
29
|
+
if RUBY_ENGINE == 'ruby' && Gem::Version.new(RUBY_VERSION) >= Gem::Version.new('3.3')
|
|
30
|
+
gem 'commonmarker', '~> 2.10', require: false
|
|
31
|
+
gem 'rubocop', '~> 1.92'
|
|
32
|
+
gem 'rubocop-md', '~> 3.0', require: false
|
|
33
|
+
gem 'rubocop-prose', '~> 0.2', require: false
|
|
34
|
+
gem 'rubocop-rake', '~> 0.7', require: false
|
|
35
|
+
gem 'rubocop-spellcheck', '~> 0.2', require: false
|
|
36
|
+
gem 'rubocop-yaml', '~> 0.1.0', require: false
|
|
37
|
+
gem 'ruby-gem-release', '0.9.0', require: false
|
|
38
|
+
end
|
|
39
|
+
end
|