openapply 1.0.3.5 → 1.0.3.7
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/Gemfile.lock +1 -1
- data/lib/openapply/client.rb +25 -2
- data/lib/openapply/version.rb +1 -1
- data/openapply.gemspec +1 -1
- metadata +3 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: baeb574c2b8b4f3929b9e375f0a25781cfc85591787f1a07939c41e89d83bf36
|
4
|
+
data.tar.gz: 3b504d28b79caa20ed63db7d1918537e0720304356b551f1f81d4339e6dd8877
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ff039ff3ec1a40da9cf2f50fd3cdfb0af5b8dfafe155d292c5b8ad585b5e2ab2565f3cabf8761da8e98d177a2537626d0c19a0e6101ba5dd5f1169e4dfdb7d17
|
7
|
+
data.tar.gz: 2803fde506d4b389b1c3316466b4449f4b74fb2121ea9f41e380f10ec1e9903753f036682c0b17fc4f1e7e0bb6870784e1c229a2dae83be04202f75b8471ec5b
|
data/Gemfile.lock
CHANGED
data/lib/openapply/client.rb
CHANGED
@@ -101,8 +101,18 @@ module Openapply
|
|
101
101
|
raise TooManyRequestError if answer.too_many_requests?
|
102
102
|
|
103
103
|
return answer
|
104
|
+
rescue TooManyRequestError
|
105
|
+
puts "TooManyRequestError"
|
106
|
+
sleep (answer.headers['X-RateLimit-Period'].to_i + 1)
|
107
|
+
retry
|
108
|
+
rescue *NET_EXCEPTIONS => error
|
109
|
+
if ENV['OA_DEBUG']
|
110
|
+
puts "ERROR:"
|
111
|
+
puts "error: #{error}"
|
112
|
+
puts "message: #{error.message}"
|
113
|
+
puts "###"
|
114
|
+
end
|
104
115
|
|
105
|
-
rescue *NET_EXCEPTIONS
|
106
116
|
if times_retried < max_retries
|
107
117
|
times_retried += 1
|
108
118
|
retry
|
@@ -149,9 +159,22 @@ module Openapply
|
|
149
159
|
puts "###"
|
150
160
|
end
|
151
161
|
|
162
|
+
raise TooManyRequestError if answer.too_many_requests?
|
163
|
+
|
152
164
|
return answer
|
153
165
|
|
154
|
-
rescue
|
166
|
+
rescue TooManyRequestError
|
167
|
+
puts "TooManyRequestError"
|
168
|
+
sleep (answer.headers['X-RateLimit-Period'].to_i + 1)
|
169
|
+
retry
|
170
|
+
rescue *NET_EXCEPTIONS => error
|
171
|
+
if ENV['OA_DEBUG']
|
172
|
+
puts "ERROR:"
|
173
|
+
puts "error: #{error}"
|
174
|
+
puts "message: #{error.message}"
|
175
|
+
puts "###"
|
176
|
+
end
|
177
|
+
|
155
178
|
if times_retried < max_retries
|
156
179
|
times_retried += 1
|
157
180
|
retry
|
data/lib/openapply/version.rb
CHANGED
data/openapply.gemspec
CHANGED
@@ -7,7 +7,7 @@ Gem::Specification.new do |spec|
|
|
7
7
|
spec.name = "openapply"
|
8
8
|
spec.version = Openapply::Version::VERSION
|
9
9
|
spec.authors = ["Bill Tihen", "Elliott Hébert"]
|
10
|
-
spec.email = ["btihen@gmail.com","btihen@las.ch","
|
10
|
+
spec.email = ["btihen@gmail.com","btihen@las.ch","ehebert@las.ch"]
|
11
11
|
|
12
12
|
spec.summary = %q{Access OpenApply's APIs with Ruby}
|
13
13
|
spec.homepage = "https://github.com/las-it/openapply"
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: openapply
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.3.
|
4
|
+
version: 1.0.3.7
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Bill Tihen
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: exe
|
11
11
|
cert_chain: []
|
12
|
-
date: 2022-
|
12
|
+
date: 2022-09-20 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: httparty
|
@@ -141,7 +141,6 @@ description:
|
|
141
141
|
email:
|
142
142
|
- btihen@gmail.com
|
143
143
|
- btihen@las.ch
|
144
|
-
- ell.heb@container4.ch
|
145
144
|
- ehebert@las.ch
|
146
145
|
executables: []
|
147
146
|
extensions: []
|
@@ -188,7 +187,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
188
187
|
- !ruby/object:Gem::Version
|
189
188
|
version: '0'
|
190
189
|
requirements: []
|
191
|
-
rubygems_version: 3.
|
190
|
+
rubygems_version: 3.3.20
|
192
191
|
signing_key:
|
193
192
|
specification_version: 4
|
194
193
|
summary: Access OpenApply's APIs with Ruby
|