koine-rest_client 1.1.0 → 1.1.1
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/lib/koine/rest_client/errors.rb +12 -0
- data/lib/koine/rest_client/response_parser.rb +10 -0
- data/lib/koine/rest_client/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2d572492742b6f56fb9c22b8c2074aed8a5383d90875938dfbaf35ccb22d2fe8
|
4
|
+
data.tar.gz: ce09b90ea4866d789f37a777bb935b2d8ea66a9f6914de6fd28e286d80857ae5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f34b6d2a7605afcad75f8f51e301c66470d965d9e0d8fc86f44e0c25c37c1f8e4e6c365ecca9209ac7e27e3a6f679019f42702615e0eefcdcd23c0bef9e8d8cc
|
7
|
+
data.tar.gz: c4cdb8cac74fceca8815e94e3939b2d0f95d9a3ea244a80658358271e73cad5da4c112d30417567a965f8e4ea2d12f93f2a1f45c3d646feff31d4d301c1d2787
|
@@ -1,5 +1,7 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
+
# @see https://developer.mozilla.org/en-US/docs/Web/HTTP/Status#client_error_responses
|
4
|
+
#
|
3
5
|
module Koine
|
4
6
|
module RestClient
|
5
7
|
# base class for http errors
|
@@ -35,6 +37,16 @@ module Koine
|
|
35
37
|
RangeNotSatisfiableError = Class.new(Error)
|
36
38
|
ExpectationFailedError = Class.new(Error)
|
37
39
|
ImATeapotError = Class.new(Error)
|
40
|
+
MisdirectedRequestError = Class.new(Error)
|
41
|
+
UnprocessableEntityError = Class.new(Error)
|
42
|
+
LockedError = Class.new(Error)
|
43
|
+
FailedDependencyError = Class.new(Error)
|
44
|
+
TooEarlyExperimentalError = Class.new(Error)
|
45
|
+
UpgradeRequiredError = Class.new(Error)
|
46
|
+
PreconditionRequiredError = Class.new(Error)
|
47
|
+
TooManyRequestsError = Class.new(Error)
|
48
|
+
RequestHeaderFieldsTooLargeError = Class.new(Error)
|
49
|
+
UnavailableForLegalReasonsError = Class.new(Error)
|
38
50
|
|
39
51
|
# 500
|
40
52
|
InternalServerError = Class.new(Error)
|
@@ -41,6 +41,16 @@ module Koine
|
|
41
41
|
416 => RangeNotSatisfiableError,
|
42
42
|
417 => ExpectationFailedError,
|
43
43
|
418 => ImATeapotError,
|
44
|
+
421 => MisdirectedRequestError,
|
45
|
+
422 => UnprocessableEntityError,
|
46
|
+
423 => LockedError,
|
47
|
+
424 => FailedDependencyError,
|
48
|
+
425 => TooEarlyExperimentalError,
|
49
|
+
426 => UpgradeRequiredError,
|
50
|
+
428 => PreconditionRequiredError,
|
51
|
+
429 => TooManyRequestsError,
|
52
|
+
431 => RequestHeaderFieldsTooLargeError,
|
53
|
+
451 => UnavailableForLegalReasonsError,
|
44
54
|
500 => InternalServerError,
|
45
55
|
501 => NotImplementedError,
|
46
56
|
502 => BadGatewayError,
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: koine-rest_client
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.1.
|
4
|
+
version: 1.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Marcelo Jacobus
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-08-
|
11
|
+
date: 2022-08-17 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: addressable
|