job-iteration 1.3.1 → 1.3.2

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 8788b6f2da0dba53c31c57d529a371e3e822091caa3654bcafc6cf25ad031adb
4
- data.tar.gz: 14cba8e6969be4d6aba0f729abd355196324f2eebd00d9b659053b7efe25117d
3
+ metadata.gz: 63917aaf8f527e78cd47f62111dbda8473c90907eeaa8827ed23aaba77f494a0
4
+ data.tar.gz: 4fa0d5ce8eb5c1e7cdc2712daae6ddf689cfd1ae7cc3f840abe7b45628ee7735
5
5
  SHA512:
6
- metadata.gz: 97f3d383f9eb1e82c3c68ee21bdcaf31a5df2923ebd4eb9089b7b78348f64bd69aa0da39acd0eba23cd309263931639e4e6ca702511a0d83a9528e520ff77e89
7
- data.tar.gz: beda68f91cfd51d0d78c2b0c26b20b70bc339fc25591d3ceefe825e687bdc057b448832d2abead1e80c5259eda52ef04d6b6cf83063431766ab8920dd753c396
6
+ metadata.gz: ae0a1330b24adfa55c045cd079806c350e151ee7c12555c9397143919c8f77fdc3023cb23330fc529af3771da31379991830513ce0459e1ff5ff21614e0518d0
7
+ data.tar.gz: 0733a5377c27ff39acd118f3e719e52bd82a7a63d7f03508b61c6ced900baef9bc0e05bdc5b43d87d6e36f05339bf9a84c1ffd5c1ce70c06cb172ee3c3905240
data/CHANGELOG.md CHANGED
@@ -1,7 +1,10 @@
1
1
  ### Master (unreleased)
2
2
 
3
+ ## v1.3.2 (Nov 12, 2021)
4
+ - [148](https://github.com/Shopify/job-iteration/pull/148) - Revert "Do not evaluate enumerator when throttled", due to backwards incompatibility.
5
+
3
6
  ## v1.3.1 (Nov 11, 2021)
4
- - [87](https://github.com/Shopify/job-iteration/pull/87) - Do not evaluate enumerator when throttled
7
+ - [87](https://github.com/Shopify/job-iteration/pull/87) - Do not evaluate enumerator when throttled (REVERTED)
5
8
 
6
9
 
7
10
  ## v1.3.0 (Oct 7, 2021)
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- job-iteration (1.3.1)
4
+ job-iteration (1.3.2)
5
5
  activejob (>= 5.2)
6
6
 
7
7
  GEM
@@ -120,4 +120,4 @@ DEPENDENCIES
120
120
  yard
121
121
 
122
122
  BUNDLED WITH
123
- 2.2.20
123
+ 2.2.22
@@ -28,14 +28,14 @@ module JobIteration
28
28
 
29
29
  def to_enum
30
30
  Enumerator.new(-> { @enum.size }) do |yielder|
31
- loop do
31
+ @enum.each do |*val|
32
32
  if should_throttle?
33
33
  ActiveSupport::Notifications.instrument("throttled.iteration", job_class: @job.class.name)
34
34
  @job.retry_job(wait: @backoff)
35
35
  throw(:abort, :skip_complete_callbacks)
36
36
  end
37
37
 
38
- yielder.yield(*@enum.next_values)
38
+ yielder.yield(*val)
39
39
  end
40
40
  end
41
41
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module JobIteration
4
- VERSION = "1.3.1"
4
+ VERSION = "1.3.2"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: job-iteration
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.3.1
4
+ version: 1.3.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Shopify
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-11-11 00:00:00.000000000 Z
11
+ date: 2021-11-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activerecord