assembly-image 2.1.0 → 2.1.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: '088a4b9c59b50f893f7b50c16898321770006b4ab22dc08a8ddd70cdba9a15da'
4
- data.tar.gz: f22bf6d6acbd4d6885e2102526e7c5e0ac76b93af71eff0d2237d32334afd223
3
+ metadata.gz: 307844d855e2e94047191cbb357f944366345bc9d959b942a26c41ec7f0d6a3c
4
+ data.tar.gz: 966fcaebcf1ef6877da8a9498019b12628f6aa097cfa8b97d22e98fabbba8aac
5
5
  SHA512:
6
- metadata.gz: 91f0be3622982ad69823a45eca8111d05756e0442cd7d7aa16cb8099e71ee2e95c21f17c7f14b7ccab04c11724233c9a9739e24f8b8302f07f42b16738c6400e
7
- data.tar.gz: d1ab206c475413496a6add9376cb246705df18a3142bdc32189b202e31af698b8cfded84464d00e94357fc08396ab142270043b3b862cc0d68cd57834863b649
6
+ metadata.gz: f8c77143ffebd2651796779292d0861aaa9b41f2a7621b8e9991bdc225f297f80d970ef108fdbbd47755b5ac5b65a8f71e64b581042a240d6bc38b19bbf0d2d9
7
+ data.tar.gz: 9870392be2e09567d802d2b5a395feb457e7bbb8d19b1f16a4ce49bcf1cce562f66bab4920c4b5a50d0e5eff41fdae40def644e764d1ee37c3fdee8df30e17bc
data/.circleci/config.yml CHANGED
@@ -1,6 +1,6 @@
1
1
  version: 2.1
2
2
  orbs:
3
- ruby-rails: sul-dlss/ruby-rails@3.1.2
3
+ ruby-rails: sul-dlss/ruby-rails@4.1.0
4
4
  workflows:
5
5
  build:
6
6
  jobs:
data/.rubocop.yml CHANGED
@@ -143,7 +143,7 @@ RSpec/IdenticalEqualityAssertion: # new in 2.4
143
143
  Enabled: true
144
144
  RSpec/SubjectDeclaration: # new in 2.5
145
145
  Enabled: true
146
- RSpec/FactoryBot/SyntaxMethods: # new in 2.7
146
+ FactoryBot/SyntaxMethods: # new in 2.7
147
147
  Enabled: true
148
148
  RSpec/Rails/AvoidSetupHook: # new in 2.4
149
149
  Enabled: false
@@ -180,7 +180,106 @@ Lint/ConstantOverwrittenInRescue: # new in 1.31
180
180
  Lint/NonAtomicFileOperation: # new in 1.31
181
181
  Enabled: true
182
182
 
183
- RSpec/Capybara/SpecificMatcher: # new in 2.12
183
+ Capybara/SpecificMatcher: # new in 2.12
184
184
  Enabled: true
185
185
  RSpec/Rails/HaveHttpStatus: # new in 2.12
186
186
  Enabled: false
187
+
188
+ Gemspec/DevelopmentDependencies: # new in 1.44
189
+ Enabled: false
190
+ Lint/DuplicateMagicComment: # new in 1.37
191
+ Enabled: true
192
+ Lint/DuplicateMatchPattern: # new in 1.50
193
+ Enabled: true
194
+ Lint/RequireRangeParentheses: # new in 1.32
195
+ Enabled: true
196
+ Lint/UselessRescue: # new in 1.43
197
+ Enabled: true
198
+ Metrics/CollectionLiteralLength: # new in 1.47
199
+ Enabled: true
200
+ Style/ArrayIntersect: # new in 1.40
201
+ Enabled: true
202
+ Style/ComparableClamp: # new in 1.44
203
+ Enabled: true
204
+ Style/ConcatArrayLiterals: # new in 1.41
205
+ Enabled: true
206
+ Style/DataInheritance: # new in 1.49
207
+ Enabled: true
208
+ Style/DirEmpty: # new in 1.48
209
+ Enabled: true
210
+ Style/EmptyHeredoc: # new in 1.32
211
+ Enabled: true
212
+ Style/ExactRegexpMatch: # new in 1.51
213
+ Enabled: true
214
+ Style/FileEmpty: # new in 1.48
215
+ Enabled: true
216
+ Style/MagicCommentFormat: # new in 1.35
217
+ Enabled: true
218
+ Style/MapToSet: # new in 1.42
219
+ Enabled: true
220
+ Style/MinMaxComparison: # new in 1.42
221
+ Enabled: true
222
+ Style/OperatorMethodCall: # new in 1.37
223
+ Enabled: true
224
+ Style/RedundantArrayConstructor: # new in 1.52
225
+ Enabled: true
226
+ Style/RedundantConstantBase: # new in 1.40
227
+ Enabled: true
228
+ Style/RedundantDoubleSplatHashBraces: # new in 1.41
229
+ Enabled: true
230
+ Style/RedundantEach: # new in 1.38
231
+ Enabled: true
232
+ Style/RedundantFilterChain: # new in 1.52
233
+ Enabled: true
234
+ Style/RedundantHeredocDelimiterQuotes: # new in 1.45
235
+ Enabled: true
236
+ Style/RedundantLineContinuation: # new in 1.49
237
+ Enabled: true
238
+ Style/RedundantRegexpConstructor: # new in 1.52
239
+ Enabled: true
240
+ Style/RedundantStringEscape: # new in 1.37
241
+ Enabled: true
242
+ Capybara/MatchStyle: # new in 2.17
243
+ Enabled: true
244
+ Capybara/NegationMatcher: # new in 2.14
245
+ Enabled: true
246
+ Capybara/SpecificActions: # new in 2.14
247
+ Enabled: true
248
+ Capybara/SpecificFinders: # new in 2.13
249
+ Enabled: true
250
+ FactoryBot/AssociationStyle: # new in 2.23
251
+ Enabled: true
252
+ FactoryBot/ConsistentParenthesesStyle: # new in 2.14
253
+ Enabled: true
254
+ FactoryBot/FactoryAssociationWithStrategy: # new in 2.23
255
+ Enabled: true
256
+ FactoryBot/FactoryNameStyle: # new in 2.16
257
+ Enabled: true
258
+ FactoryBot/RedundantFactoryOption: # new in 2.23
259
+ Enabled: true
260
+ RSpec/BeEmpty: # new in 2.20
261
+ Enabled: true
262
+ RSpec/ContainExactly: # new in 2.19
263
+ Enabled: true
264
+ RSpec/DuplicatedMetadata: # new in 2.16
265
+ Enabled: true
266
+ RSpec/IndexedLet: # new in 2.20
267
+ Enabled: true
268
+ RSpec/MatchArray: # new in 2.19
269
+ Enabled: true
270
+ RSpec/NoExpectationExample: # new in 2.13
271
+ Enabled: true
272
+ RSpec/PendingWithoutReason: # new in 2.16
273
+ Enabled: true
274
+ RSpec/RedundantAround: # new in 2.19
275
+ Enabled: true
276
+ RSpec/SkipBlockInsideExample: # new in 2.19
277
+ Enabled: true
278
+ RSpec/SortMetadata: # new in 2.14
279
+ Enabled: true
280
+ RSpec/Rails/InferredSpecType: # new in 2.14
281
+ Enabled: true
282
+ RSpec/Rails/MinitestAssertions: # new in 2.17
283
+ Enabled: true
284
+ RSpec/Rails/TravelAround: # new in 2.19
285
+ Enabled: true
data/.rubocop_todo.yml CHANGED
@@ -1,20 +1,20 @@
1
1
  # This configuration was generated by
2
2
  # `rubocop --auto-gen-config`
3
- # on 2022-07-19 17:18:47 UTC using RuboCop version 1.31.2.
3
+ # on 2023-06-20 05:53:05 UTC using RuboCop version 1.52.1.
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
9
  # Offense count: 1
10
- # Configuration parameters: Include.
10
+ # Configuration parameters: Severity, Include.
11
11
  # Include: **/*.gemspec
12
12
  Gemspec/RequiredRubyVersion:
13
13
  Exclude:
14
14
  - 'assembly-image.gemspec'
15
15
 
16
16
  # Offense count: 2
17
- # Configuration parameters: IgnoredMethods, CountRepeatedAttributes.
17
+ # Configuration parameters: AllowedMethods, AllowedPatterns, CountRepeatedAttributes.
18
18
  Metrics/AbcSize:
19
19
  Max: 20
20
20
 
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- assembly-image (2.1.0)
4
+ assembly-image (2.1.1)
5
5
  activesupport (> 6.1)
6
6
  assembly-objectfile (>= 1.6.4)
7
7
  ruby-vips (>= 2.0)
@@ -9,87 +9,100 @@ PATH
9
9
  GEM
10
10
  remote: http://rubygems.org/
11
11
  specs:
12
- activesupport (7.0.3.1)
12
+ activesupport (7.0.8)
13
13
  concurrent-ruby (~> 1.0, >= 1.0.2)
14
14
  i18n (>= 1.6, < 2)
15
15
  minitest (>= 5.1)
16
16
  tzinfo (~> 2.0)
17
- assembly-objectfile (2.1.0)
17
+ assembly-objectfile (2.2.0)
18
18
  activesupport (>= 5.2.0)
19
19
  mime-types (> 3)
20
20
  mini_exiftool
21
21
  ast (2.4.2)
22
+ base64 (0.1.1)
22
23
  byebug (11.1.3)
23
24
  coderay (1.1.3)
24
- concurrent-ruby (1.1.10)
25
+ concurrent-ruby (1.2.2)
25
26
  diff-lcs (1.5.0)
26
27
  docile (1.4.0)
27
28
  ffi (1.15.5)
28
- i18n (1.12.0)
29
+ i18n (1.14.1)
29
30
  concurrent-ruby (~> 1.0)
30
- json (2.6.2)
31
+ json (2.6.3)
32
+ language_server-protocol (3.17.0.3)
31
33
  method_source (1.0.0)
32
- mime-types (3.4.1)
34
+ mime-types (3.5.1)
33
35
  mime-types-data (~> 3.2015)
34
- mime-types-data (3.2022.0105)
36
+ mime-types-data (3.2023.0808)
35
37
  mini_exiftool (2.10.2)
36
- minitest (5.16.2)
37
- parallel (1.22.1)
38
- parser (3.1.2.0)
38
+ minitest (5.20.0)
39
+ parallel (1.23.0)
40
+ parser (3.2.2.3)
39
41
  ast (~> 2.4.1)
40
- pry (0.13.1)
42
+ racc
43
+ pry (0.14.2)
41
44
  coderay (~> 1.1)
42
45
  method_source (~> 1.0)
43
- pry-byebug (3.9.0)
46
+ pry-byebug (3.10.1)
44
47
  byebug (~> 11.0)
45
- pry (~> 0.13.0)
48
+ pry (>= 0.13, < 0.15)
49
+ racc (1.7.1)
46
50
  rainbow (3.1.1)
47
51
  rake (13.0.6)
48
- regexp_parser (2.5.0)
49
- rexml (3.2.5)
50
- rspec (3.11.0)
51
- rspec-core (~> 3.11.0)
52
- rspec-expectations (~> 3.11.0)
53
- rspec-mocks (~> 3.11.0)
54
- rspec-core (3.11.0)
55
- rspec-support (~> 3.11.0)
56
- rspec-expectations (3.11.0)
52
+ regexp_parser (2.8.1)
53
+ rexml (3.2.6)
54
+ rspec (3.12.0)
55
+ rspec-core (~> 3.12.0)
56
+ rspec-expectations (~> 3.12.0)
57
+ rspec-mocks (~> 3.12.0)
58
+ rspec-core (3.12.2)
59
+ rspec-support (~> 3.12.0)
60
+ rspec-expectations (3.12.3)
57
61
  diff-lcs (>= 1.2.0, < 2.0)
58
- rspec-support (~> 3.11.0)
59
- rspec-mocks (3.11.1)
62
+ rspec-support (~> 3.12.0)
63
+ rspec-mocks (3.12.6)
60
64
  diff-lcs (>= 1.2.0, < 2.0)
61
- rspec-support (~> 3.11.0)
62
- rspec-support (3.11.0)
63
- rubocop (1.31.2)
65
+ rspec-support (~> 3.12.0)
66
+ rspec-support (3.12.1)
67
+ rubocop (1.56.3)
68
+ base64 (~> 0.1.1)
64
69
  json (~> 2.3)
70
+ language_server-protocol (>= 3.17.0)
65
71
  parallel (~> 1.10)
66
- parser (>= 3.1.0.0)
72
+ parser (>= 3.2.2.3)
67
73
  rainbow (>= 2.2.2, < 4.0)
68
74
  regexp_parser (>= 1.8, < 3.0)
69
75
  rexml (>= 3.2.5, < 4.0)
70
- rubocop-ast (>= 1.18.0, < 2.0)
76
+ rubocop-ast (>= 1.28.1, < 2.0)
71
77
  ruby-progressbar (~> 1.7)
72
- unicode-display_width (>= 1.4.0, < 3.0)
73
- rubocop-ast (1.19.1)
74
- parser (>= 3.1.1.0)
75
- rubocop-rspec (2.12.1)
76
- rubocop (~> 1.31)
77
- ruby-progressbar (1.11.0)
78
+ unicode-display_width (>= 2.4.0, < 3.0)
79
+ rubocop-ast (1.29.0)
80
+ parser (>= 3.2.1.0)
81
+ rubocop-capybara (2.18.0)
82
+ rubocop (~> 1.41)
83
+ rubocop-factory_bot (2.24.0)
84
+ rubocop (~> 1.33)
85
+ rubocop-rspec (2.24.0)
86
+ rubocop (~> 1.33)
87
+ rubocop-capybara (~> 2.17)
88
+ rubocop-factory_bot (~> 2.22)
89
+ ruby-progressbar (1.13.0)
78
90
  ruby-vips (2.1.4)
79
91
  ffi (~> 1.12)
80
- simplecov (0.21.2)
92
+ simplecov (0.22.0)
81
93
  docile (~> 1.1)
82
94
  simplecov-html (~> 0.11)
83
95
  simplecov_json_formatter (~> 0.1)
84
96
  simplecov-html (0.12.3)
85
97
  simplecov_json_formatter (0.1.4)
86
- tzinfo (2.0.5)
98
+ tzinfo (2.0.6)
87
99
  concurrent-ruby (~> 1.0)
88
- unicode-display_width (2.2.0)
100
+ unicode-display_width (2.4.2)
89
101
 
90
102
  PLATFORMS
91
103
  x86_64-darwin-19
92
104
  x86_64-darwin-21
105
+ x86_64-darwin-22
93
106
  x86_64-linux
94
107
 
95
108
  DEPENDENCIES
@@ -102,4 +115,4 @@ DEPENDENCIES
102
115
  simplecov
103
116
 
104
117
  BUNDLED WITH
105
- 2.3.17
118
+ 2.4.13
@@ -4,7 +4,7 @@ $LOAD_PATH.push File.expand_path('lib', __dir__)
4
4
 
5
5
  Gem::Specification.new do |s|
6
6
  s.name = 'assembly-image'
7
- s.version = '2.1.0'
7
+ s.version = '2.1.1'
8
8
  s.authors = ['Peter Mangiafico', 'Renzo Sanchez-Silva', 'Monty Hindman', 'Tony Calavano']
9
9
  s.email = ['pmangiafico@stanford.edu']
10
10
  s.homepage = ''
@@ -42,6 +42,8 @@ module Assembly
42
42
  end
43
43
 
44
44
  def vips_image
45
+ # Disable cache. Otherwise, Vips gets confused by files with the same filename.
46
+ Vips.cache_set_max_files(0)
45
47
  # autorot will only affect images that need rotation: https://www.libvips.org/API/current/libvips-conversion.html#vips-autorot
46
48
  @vips_image ||= Vips::Image.new_from_file(path).autorot
47
49
  end
data/spec/spec_helper.rb CHANGED
@@ -169,10 +169,10 @@ def generate_test_image(file, params = {})
169
169
 
170
170
  temp_array = color_gauge_values(cg_type)
171
171
  temp_image = Vips::Image.black(width, height, bands: temp_array.first.size)
172
- (0..4).each do |i|
172
+ 5.times do |i|
173
173
  b = (box_size * i) + (line_size * (i + 1))
174
174
  # d = b + box_size - line_size
175
- (0...6).each do |j|
175
+ 6.times do |j|
176
176
  a = (box_size * j) + (line_size * (j + 1))
177
177
  # c = a + box_size - line_size
178
178
  colors = temp_array.shift
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: assembly-image
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.0
4
+ version: 2.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Peter Mangiafico
@@ -11,7 +11,7 @@ authors:
11
11
  autorequire:
12
12
  bindir: exe
13
13
  cert_chain: []
14
- date: 2022-07-19 00:00:00.000000000 Z
14
+ date: 2023-09-21 00:00:00.000000000 Z
15
15
  dependencies:
16
16
  - !ruby/object:Gem::Dependency
17
17
  name: activesupport
@@ -194,7 +194,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
194
194
  - !ruby/object:Gem::Version
195
195
  version: '0'
196
196
  requirements: []
197
- rubygems_version: 3.2.32
197
+ rubygems_version: 3.3.7
198
198
  signing_key:
199
199
  specification_version: 4
200
200
  summary: Ruby immplementation of image services needed to prepare objects to be accessioned