shopify_graphql 2.5.1 → 2.5.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: 827b03ca608d7ae514f1758fb96ebc253783b778cbe376d8e2a5d3ab772b42da
4
- data.tar.gz: b473cac1e4ac0dcf34ea3895dcaa6cadf0bb5dd4d2ea434b1ed4350dcd137839
3
+ metadata.gz: 835956a5fd0a03ab1bdee46e0eebfe922f5ae1fb752e370f24eae2ddeba94c89
4
+ data.tar.gz: a42109e905b9310e95553432b504e5f081c4db92b2b4d1aee4c7fc1cc15d25f6
5
5
  SHA512:
6
- metadata.gz: 169c9249f8ac75c8f7c07d087b91cc6ff7a09ea9b8d361e4a2e746106f71fb6dca3f81dce546b6e3dfd0df1fe73bd8657d7adf515656232e38ec6053621fb9fd
7
- data.tar.gz: b4633cdc0d303d4e9f4f7fee089c5ff7e67793a4c28ae3779a7f093cfed030405f3a77fd1760490ce6b022a2e179ad689fa7400db1294bf2c291f40999242dd4
6
+ metadata.gz: fa74302c607542f2c28ac9103c5d19ac30be2a5625976b817da5c702c4281f62024a5c51f7b1604fbe5db21770978047a8e1315738a0cdd98c267b66440b71d7
7
+ data.tar.gz: c572fd99e4f231f9b4edb7caace28daacfa92edb91ca0da993863dd2dbed7574ed9e797e86ff88c3a223a406291ea3122c2c2ae83dd3c16639264cc93b9c7894
@@ -25,6 +25,20 @@ module ShopifyGraphql
25
25
  DISPLAY_NAME_TO_PLAN = PLAN_TO_DISPLAY_NAME.invert
26
26
 
27
27
  class Client
28
+ NETWORK_ERRORS = [
29
+ Errno::ECONNRESET,
30
+ Errno::ECONNABORTED,
31
+ Errno::ECONNREFUSED,
32
+ Errno::EPIPE,
33
+ Errno::ENETUNREACH,
34
+ Errno::EHOSTUNREACH,
35
+ Errno::ETIMEDOUT,
36
+ Net::ReadTimeout,
37
+ Net::OpenTimeout,
38
+ OpenSSL::SSL::SSLError,
39
+ EOFError
40
+ ].freeze
41
+
28
42
  def client
29
43
  session = ShopifyAPI::Context.active_session
30
44
  if @client.nil? || @access_token != session&.access_token || @shop != session&.shop
@@ -42,7 +56,7 @@ module ShopifyGraphql
42
56
  Response.new(handle_response(e.response, e))
43
57
  rescue JSON::ParserError => e
44
58
  raise ServerError.new(response: response), "Invalid JSON response: #{e.message}"
45
- rescue Errno::ECONNRESET, Errno::EPIPE, Errno::ECONNREFUSED, Errno::ENETUNREACH, Net::ReadTimeout, Net::OpenTimeout, OpenSSL::SSL::SSLError, EOFError => e
59
+ rescue *NETWORK_ERRORS => e
46
60
  raise ServerError.new(response: response), "Network error: #{e.message}"
47
61
  rescue => e
48
62
  if (defined?(Socket::ResolutionError) and e.is_a?(Socket::ResolutionError))
@@ -1,3 +1,3 @@
1
1
  module ShopifyGraphql
2
- VERSION = "2.5.1"
2
+ VERSION = "2.5.2"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: shopify_graphql
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.5.1
4
+ version: 2.5.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kirill Platonov
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2026-09-07 00:00:00.000000000 Z
11
+ date: 2026-09-17 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails