shopify-client 0.0.5 → 0.0.6

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: 970f20e5e3da6050c6b5d6dd494ca7426079b34c679390e6e0eeee0113eace8a
4
- data.tar.gz: '080d4c2dd0f31c41ab6da721a10808d984899318ed591f9c5cf32238bd1d42ee'
3
+ metadata.gz: 818841a24a7d51fd3a425b4a0c55f42ee67c00ce4c63266bb9ca3c1b1d5ba9e7
4
+ data.tar.gz: 18b286b836e472ea6842082012f57e3b6c762d32999cb9e4e3f3c03ea01225d0
5
5
  SHA512:
6
- metadata.gz: 29c0d2d0a38ab6f7d335230b6354ac750f318c6094499908e2332b2713c19b1ebd3b6e6566519f3924f549d6b9b3fd7934334731cf72ff9da30b0bf68d379a4d
7
- data.tar.gz: 8229de3254fd8bb22401a86278cba84c16718b620cea1f89cb1c4d5c0d57eccfbe6c33d033d5db432647d5cd287d6daee76f032f6ef968df46a715862bb248ed
6
+ metadata.gz: b71e062da5ded3d0689375261147a516eeb6b6135f9ca9cb94cc1a47fb4440aabc050e81b4cc64838f35f825d98af9cafec896354d4c80a6221a7f68cab75e21
7
+ data.tar.gz: 55adbc9bed92f981a939fb64a3bff3e743d4967164545bc9fe7d7820f7498c51a376594abd96f07274a124020f36ffb1c859df7cb44f5cdf46074f38af242ba6
@@ -72,6 +72,15 @@ module ShopifyClient
72
72
  end
73
73
  when 423
74
74
  raise ShopError.new(request, self), 'Shop is locked'
75
+ when 430
76
+ # NOTE: This is an unofficial code used by Shopify. See:
77
+ #
78
+ # https://en.wikipedia.org/wiki/List_of_HTTP_status_codes#Unofficial_codes
79
+ #
80
+ # It's undocumented unfortunately, but seems to be like a 429 response,
81
+ # except where the app is making too many API calls (rather than hitting
82
+ # the per store rate limit).
83
+ raise TooManyRequestsError.new(request, self), 'Too many requests'
75
84
  when 400..499
76
85
  raise ClientError.new(request, self)
77
86
  when 500..599
@@ -183,6 +192,8 @@ module ShopifyClient
183
192
  InvalidAccessTokenError = Class.new(ClientError)
184
193
  # The shop is frozen/locked/unavailable.
185
194
  ShopError = Class.new(ClientError)
195
+ # The app is making too many requests to the API.
196
+ TooManyRequestsError = Class.new(ClientError)
186
197
 
187
198
  # The GraphQL API always responds with a status code of 200.
188
199
  GraphQLClientError = Class.new(ClientError) do
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module ShopifyClient
4
- VERSION = '0.0.5'
4
+ VERSION = '0.0.6'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: shopify-client
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.5
4
+ version: 0.0.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kelsey Judson
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2021-07-22 00:00:00.000000000 Z
11
+ date: 2021-09-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: dotenv