sul_orcid_client 0.3.0 → 0.3.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: a962456d9d06f989b7fe1fa4a95922ee3bfab33234baa35f6192398380016dc1
4
- data.tar.gz: 7a2b53f1c0fc01c27748e6ec226f6ca271a2f356e78f3f5ac45fc9e920758fa3
3
+ metadata.gz: 57218fe5c199745f0479d48ffde6483d94ec7dac3f33d278bb37a796bcd5534a
4
+ data.tar.gz: 21824eef4efdb0c1c668483b1d4b1c4e42f7d8417db77c0ef85eb79d6cbe1fa6
5
5
  SHA512:
6
- metadata.gz: 5d41466f03921824b3325bfec46018a0874bca2f01f8e7609171cbf90f0b077c428806b61483b66158699bafbf2ad2eb4afd1d24e5613bbbef7a477c011359a3
7
- data.tar.gz: 1fbe6359f523713b2c851c85e249e4b55b4436c4092b4f9b239059750fa6c83507385352d92b78c943c5d8117537904b928c864c13c5b83fef1b24ae150190e7
6
+ metadata.gz: 5623cd78ba366d9ddf1e33aa6eb858d787aca52deee5c569a7ae6fa1333e8f2134b39781aac6c47e772367ed4d51a4eea348ea728acb2ba4b8c64697d3041ff4
7
+ data.tar.gz: 64c1672225217bbd8b6cc7b962bea2549ef2432558902a396919778ede223fa78922b54dc73a7eee4087c5bada798c53fb4abe86e385afc35cf87199a989bf38
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- sul_orcid_client (0.3.0)
4
+ sul_orcid_client (0.3.1)
5
5
  activesupport (>= 4.2, < 8)
6
6
  cocina-models (~> 0.90)
7
7
  faraday
@@ -12,15 +12,16 @@ PATH
12
12
  GEM
13
13
  remote: https://rubygems.org/
14
14
  specs:
15
- activesupport (7.0.6)
15
+ activesupport (7.0.7)
16
16
  concurrent-ruby (~> 1.0, >= 1.0.2)
17
17
  i18n (>= 1.6, < 2)
18
18
  minitest (>= 5.1)
19
19
  tzinfo (~> 2.0)
20
- addressable (2.8.4)
20
+ addressable (2.8.5)
21
21
  public_suffix (>= 2.0.2, < 6.0)
22
22
  ast (2.4.2)
23
23
  attr_extras (7.1.0)
24
+ base64 (0.1.1)
24
25
  byebug (11.1.3)
25
26
  cocina-models (0.90.0)
26
27
  activesupport
@@ -37,7 +38,7 @@ GEM
37
38
  super_diff
38
39
  thor
39
40
  zeitwerk (~> 2.1)
40
- commonmarker (0.23.9)
41
+ commonmarker (0.23.10)
41
42
  concurrent-ruby (1.2.2)
42
43
  crack (0.4.5)
43
44
  rexml
@@ -45,7 +46,7 @@ GEM
45
46
  activesupport
46
47
  diff-lcs (1.5.0)
47
48
  docile (1.4.0)
48
- dry-core (1.0.0)
49
+ dry-core (1.0.1)
49
50
  concurrent-ruby (~> 1.0)
50
51
  zeitwerk (~> 2.6)
51
52
  dry-inflector (1.0.0)
@@ -85,12 +86,12 @@ GEM
85
86
  jwt (2.7.1)
86
87
  language_server-protocol (3.17.0.3)
87
88
  lint_roller (1.1.0)
88
- minitest (5.18.1)
89
+ minitest (5.19.0)
89
90
  multi_json (1.15.0)
90
91
  multi_xml (0.6.0)
91
- nokogiri (1.15.3-x86_64-darwin)
92
+ nokogiri (1.15.4-x86_64-darwin)
92
93
  racc (~> 1.4)
93
- nokogiri (1.15.3-x86_64-linux)
94
+ nokogiri (1.15.4-x86_64-linux)
94
95
  racc (~> 1.4)
95
96
  oauth2 (2.0.9)
96
97
  faraday (>= 0.17.3, < 3.0)
@@ -102,7 +103,7 @@ GEM
102
103
  openapi3_parser (0.9.2)
103
104
  commonmarker (~> 0.17)
104
105
  openapi_parser (0.15.0)
105
- optimist (3.0.1)
106
+ optimist (3.1.0)
106
107
  parallel (1.23.0)
107
108
  parser (3.2.2.3)
108
109
  ast (~> 2.4.1)
@@ -115,7 +116,7 @@ GEM
115
116
  rainbow (3.1.1)
116
117
  rake (13.0.6)
117
118
  regexp_parser (2.8.1)
118
- rexml (3.2.5)
119
+ rexml (3.2.6)
119
120
  rspec (3.12.0)
120
121
  rspec-core (~> 3.12.0)
121
122
  rspec-expectations (~> 3.12.0)
@@ -129,16 +130,18 @@ GEM
129
130
  diff-lcs (>= 1.2.0, < 2.0)
130
131
  rspec-support (~> 3.12.0)
131
132
  rspec-support (3.12.1)
132
- rss (0.2.9)
133
+ rss (0.3.0)
133
134
  rexml
134
- rubocop (1.52.1)
135
+ rubocop (1.56.1)
136
+ base64 (~> 0.1.1)
135
137
  json (~> 2.3)
138
+ language_server-protocol (>= 3.17.0)
136
139
  parallel (~> 1.10)
137
140
  parser (>= 3.2.2.3)
138
141
  rainbow (>= 2.2.2, < 4.0)
139
142
  regexp_parser (>= 1.8, < 3.0)
140
143
  rexml (>= 3.2.5, < 4.0)
141
- rubocop-ast (>= 1.28.0, < 2.0)
144
+ rubocop-ast (>= 1.28.1, < 2.0)
142
145
  ruby-progressbar (~> 1.7)
143
146
  unicode-display_width (>= 2.4.0, < 3.0)
144
147
  rubocop-ast (1.29.0)
@@ -147,10 +150,10 @@ GEM
147
150
  rubocop (~> 1.41)
148
151
  rubocop-factory_bot (2.23.1)
149
152
  rubocop (~> 1.33)
150
- rubocop-performance (1.18.0)
153
+ rubocop-performance (1.19.0)
151
154
  rubocop (>= 1.7.0, < 2.0)
152
155
  rubocop-ast (>= 0.4.0)
153
- rubocop-rspec (2.22.0)
156
+ rubocop-rspec (2.23.2)
154
157
  rubocop (~> 1.33)
155
158
  rubocop-capybara (~> 2.17)
156
159
  rubocop-factory_bot (~> 2.22)
@@ -165,18 +168,18 @@ GEM
165
168
  snaky_hash (2.0.1)
166
169
  hashie
167
170
  version_gem (~> 1.1, >= 1.1.1)
168
- standard (1.30.1)
171
+ standard (1.31.0)
169
172
  language_server-protocol (~> 3.17.0.2)
170
173
  lint_roller (~> 1.0)
171
- rubocop (~> 1.52.0)
174
+ rubocop (~> 1.56.0)
172
175
  standard-custom (~> 1.0.0)
173
- standard-performance (~> 1.1.0)
176
+ standard-performance (~> 1.2)
174
177
  standard-custom (1.0.2)
175
178
  lint_roller (~> 1.0)
176
179
  rubocop (~> 1.50)
177
- standard-performance (1.1.1)
180
+ standard-performance (1.2.0)
178
181
  lint_roller (~> 1.1)
179
- rubocop-performance (~> 1.18.0)
182
+ rubocop-performance (~> 1.19.0)
180
183
  super_diff (0.10.0)
181
184
  attr_extras (>= 6.2.4)
182
185
  diff-lcs
@@ -191,7 +194,7 @@ GEM
191
194
  addressable (>= 2.8.0)
192
195
  crack (>= 0.3.2)
193
196
  hashdiff (>= 0.4.0, < 2.0.0)
194
- zeitwerk (2.6.8)
197
+ zeitwerk (2.6.11)
195
198
 
196
199
  PLATFORMS
197
200
  x86_64-darwin-22
data/README.md CHANGED
@@ -29,8 +29,8 @@ require "sul_orcid_client"
29
29
  client = SulOrcidClient.configure(
30
30
  client_id: Settings.orcid.client_id,
31
31
  client_secret: Settings.orcid.client_secret,
32
- base_url: Settings.orcid.base_url
33
- base_public_url: Settings.orcid.base_public_url
32
+ base_url: Settings.orcid.base_url,
33
+ base_public_url: Settings.orcid.base_public_url,
34
34
  base_auth_url: Settings.orcid.base_auth_url
35
35
  )
36
36
  client.fetch_works(orcidid: 'https://sandbox.orcid.org/0000-0002-7262-6251')
@@ -46,8 +46,8 @@ to be sure configuration has already occurred, e.g.:
46
46
  SulOrcidClient.configure(
47
47
  client_id: Settings.orcid.client_id,
48
48
  client_secret: Settings.orcid.client_secret,
49
- base_url: Settings.orcid.base_url
50
- base_public_url: Settings.orcid.base_public_url
49
+ base_url: Settings.orcid.base_url,
50
+ base_public_url: Settings.orcid.base_public_url,
51
51
  base_auth_url: Settings.orcid.base_auth_url
52
52
  )
53
53
 
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  class SulOrcidClient
4
- VERSION = "0.3.0"
4
+ VERSION = "0.3.1"
5
5
  end
@@ -136,6 +136,8 @@ class SulOrcidClient
136
136
  work.merge({"put-code" => put_code}).to_json,
137
137
  "Content-Type" => "application/vnd.orcid+json")
138
138
 
139
+ raise "ORCID.org API returned #{response.status} when updating #{put_code} for #{orcidid}. The author may have previously deleted this work from their ORCID profile." if response.status == 404
140
+
139
141
  raise "ORCID.org API returned #{response.status} when updating #{put_code} for #{orcidid}" unless response.status == 200
140
142
  true
141
143
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sul_orcid_client
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Peter Mangiafico
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: exe
11
11
  cert_chain: []
12
- date: 2023-07-17 00:00:00.000000000 Z
12
+ date: 2023-08-25 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: activesupport
@@ -244,7 +244,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
244
244
  - !ruby/object:Gem::Version
245
245
  version: '0'
246
246
  requirements: []
247
- rubygems_version: 3.4.14
247
+ rubygems_version: 3.4.10
248
248
  signing_key:
249
249
  specification_version: 4
250
250
  summary: Interface for interacting with the ORCID API.