globus_client 0.11.1 → 0.12.0

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: 0412735516a2cde5c06f65eff24feeedbcdfa68fd845c4ddb02291c1c08e91bb
4
- data.tar.gz: f58c3b2f559a1a99f64e8b426fc926085f96b82e0afd85876143fee6f1ac7a4d
3
+ metadata.gz: bb50d72f725c17c845856c0f00f8753c1c709ee1adbe9876a2863692692f7274
4
+ data.tar.gz: 7c2b9379dcf066d3f827b10ecc8eb52106054bd1f5203e16015d8e21435fe9cd
5
5
  SHA512:
6
- metadata.gz: 65c26e4b278f537813ffcd4438ead6c44e08f735bd34e17e77f463aec1bbed3de85960788eab65c8635b41cc3466b95c033ef33e18970b888fa2dbdb85bd153f
7
- data.tar.gz: 1077d87cb4b0a5314a91268213f9a9fa6c0a7015e8bacc580e9cfb3ef0940409abf8f086cbdf73db973f888d1950ff3db8199c87eeb974aeab6682a3c3840e31
6
+ metadata.gz: d2e10ae21d5e6d4c1cf2a42e69ee2e8608772812136e8f068e13418b6ddb606de72ef3e8e22c8a774baedbf986f16ccf0e1499cc1bf6f563866636d9a3c3c48e
7
+ data.tar.gz: 8a0b323fa8002d1591f1b4ddb57e400862647d782faeb78da92e548fcdb5ef1acf064b499683db0c9609f50d9afcf06a4d41d99f1d4c36f0e3829ccdfc8f151a
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- globus_client (0.11.1)
4
+ globus_client (0.12.0)
5
5
  activesupport (>= 4.2, < 8)
6
6
  faraday
7
7
  faraday-retry
@@ -10,7 +10,7 @@ PATH
10
10
  GEM
11
11
  remote: https://rubygems.org/
12
12
  specs:
13
- activesupport (7.0.7)
13
+ activesupport (7.0.8)
14
14
  concurrent-ruby (~> 1.0, >= 1.0.2)
15
15
  i18n (>= 1.6, < 2)
16
16
  minitest (>= 5.1)
@@ -25,7 +25,8 @@ GEM
25
25
  rexml
26
26
  diff-lcs (1.5.0)
27
27
  docile (1.4.0)
28
- faraday (2.7.10)
28
+ faraday (2.7.11)
29
+ base64
29
30
  faraday-net_http (>= 2.0, < 3.1)
30
31
  ruby2_keywords (>= 0.0.4)
31
32
  faraday-net_http (3.0.2)
@@ -37,7 +38,7 @@ GEM
37
38
  json (2.6.3)
38
39
  language_server-protocol (3.17.0.3)
39
40
  lint_roller (1.1.0)
40
- minitest (5.19.0)
41
+ minitest (5.20.0)
41
42
  parallel (1.23.0)
42
43
  parser (3.2.2.3)
43
44
  ast (~> 2.4.1)
@@ -61,7 +62,7 @@ GEM
61
62
  diff-lcs (>= 1.2.0, < 2.0)
62
63
  rspec-support (~> 3.12.0)
63
64
  rspec-support (3.12.1)
64
- rubocop (1.56.1)
65
+ rubocop (1.56.3)
65
66
  base64 (~> 0.1.1)
66
67
  json (~> 2.3)
67
68
  language_server-protocol (>= 3.17.0)
@@ -77,12 +78,12 @@ GEM
77
78
  parser (>= 3.2.1.0)
78
79
  rubocop-capybara (2.18.0)
79
80
  rubocop (~> 1.41)
80
- rubocop-factory_bot (2.23.1)
81
+ rubocop-factory_bot (2.24.0)
81
82
  rubocop (~> 1.33)
82
- rubocop-performance (1.19.0)
83
+ rubocop-performance (1.19.1)
83
84
  rubocop (>= 1.7.0, < 2.0)
84
85
  rubocop-ast (>= 0.4.0)
85
- rubocop-rspec (2.23.2)
86
+ rubocop-rspec (2.24.0)
86
87
  rubocop (~> 1.33)
87
88
  rubocop-capybara (~> 2.17)
88
89
  rubocop-factory_bot (~> 2.22)
@@ -94,10 +95,10 @@ GEM
94
95
  simplecov_json_formatter (~> 0.1)
95
96
  simplecov-html (0.12.3)
96
97
  simplecov_json_formatter (0.1.4)
97
- standard (1.31.0)
98
+ standard (1.31.1)
98
99
  language_server-protocol (~> 3.17.0.2)
99
100
  lint_roller (~> 1.0)
100
- rubocop (~> 1.56.0)
101
+ rubocop (~> 1.56.2)
101
102
  standard-custom (~> 1.0.0)
102
103
  standard-performance (~> 1.2)
103
104
  standard-custom (1.0.2)
@@ -109,7 +110,7 @@ GEM
109
110
  tzinfo (2.0.6)
110
111
  concurrent-ruby (~> 1.0)
111
112
  unicode-display_width (2.4.2)
112
- webmock (3.18.1)
113
+ webmock (3.19.1)
113
114
  addressable (>= 2.8.0)
114
115
  crack (>= 0.3.2)
115
116
  hashdiff (>= 0.4.0, < 2.0.0)
data/api_test.rb CHANGED
@@ -21,8 +21,8 @@ Benchmark.bm(20) do |benchmark|
21
21
  GlobusClient.mkdir(user_id:, path:)
22
22
  end
23
23
 
24
- benchmark.report("user_exists?:") do
25
- @user_exists = GlobusClient.user_exists?(user_id)
24
+ benchmark.report("user_valid?:") do
25
+ @user_exists = GlobusClient.user_valid?(user_id)
26
26
  end
27
27
 
28
28
  benchmark.report("before_perms:") do
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  class GlobusClient
4
- VERSION = "0.11.1"
4
+ VERSION = "0.12.0"
5
5
  end
data/lib/globus_client.rb CHANGED
@@ -23,7 +23,17 @@ class GlobusClient
23
23
  # @param auth_url [String] the authentication API URL
24
24
  def configure(client_id:, client_secret:, uploads_directory:, transfer_endpoint_id:, transfer_url: default_transfer_url, auth_url: default_auth_url)
25
25
  instance.config = OpenStruct.new(
26
- token: Authenticator.token(client_id, client_secret, auth_url),
26
+ # For the initial token, use a dummy value to avoid hitting any APIs
27
+ # during configuration, allowing the `TokenWrapper` to handle auto-magic
28
+ # token refreshing. Why not immediately get a valid token? Our apps
29
+ # commonly invoke client `.configure` methods in the initializer in all
30
+ # application environments, even those that are never expected to
31
+ # connect to production APIs, such as local development machines.
32
+ #
33
+ # NOTE: `nil` and blank string cannot be used as dummy values here as
34
+ # they lead to a malformed request to be sent, which triggers an
35
+ # exception not rescued by `TokenWrapper`
36
+ token: "a temporary dummy token to avoid hitting the API before it is needed",
27
37
  client_id:,
28
38
  client_secret:,
29
39
  uploads_directory:,
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: globus_client
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.11.1
4
+ version: 0.12.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Aaron Collier
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: exe
12
12
  cert_chain: []
13
- date: 2023-08-24 00:00:00.000000000 Z
13
+ date: 2023-09-22 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: activesupport
@@ -208,7 +208,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
208
208
  - !ruby/object:Gem::Version
209
209
  version: '0'
210
210
  requirements: []
211
- rubygems_version: 3.4.10
211
+ rubygems_version: 3.4.19
212
212
  signing_key:
213
213
  specification_version: 4
214
214
  summary: Interface for interacting with the Globus API.