api_six_client 1.2.8 → 1.2.10

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: 691f1adc2774176162f7adb49856b433a1e260797cfd7dd7605ea07b71b594e3
4
- data.tar.gz: 53377797bc34c14e432617f98388033ddc53ffd191817f3c330f8cdfd63de690
3
+ metadata.gz: 5489546353449d9ea972532a4bb92af2f4b9639460a2c3e6f05e6975f102f1ce
4
+ data.tar.gz: 4a045f79f0b1a76f2cf67a094c7379ed5d859933258f8034abc3fa4e51c41bac
5
5
  SHA512:
6
- metadata.gz: 76d992d9f2c5cca5f26c8f94e73d6fc647bb7b2e091591d371f1c40d4eff24f981556ff7f929510cbe636a7180df51cff930fbf6f63cfdf1da2012d9a12ad193
7
- data.tar.gz: 5dede23443a5098cdb533aa261c23ae5b43fa9d7af4688c50263608eaa7bb10d8b56f1422bf46c51c87110998067cb0abc85e60446f33feeb92063b3c1e4aa5b
6
+ metadata.gz: b82907548a84b2473218b78e5d5514ade59905d2294e9472bf112cdb7f0c8b61c35183f444c4c27c41736a1469ab85ee9102dee12251e6a5f3fb24a408a29b07
7
+ data.tar.gz: aa109526cca86f938bc2592a814c33fd6538f22a64a5976209428bea43ea421f83616c396961ccde2213eda54c34b3440935920ba293c780c9dd93384c446638
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- api_six_client (1.2.8)
4
+ api_six_client (1.2.10)
5
5
  faraday (~> 1)
6
6
 
7
7
  GEM
@@ -38,6 +38,10 @@ module ApiSixClient
38
38
 
39
39
  protected
40
40
 
41
+ def deprecation_msg
42
+ Rails.logger.warn("#{self.class} is deprecated") if defined?(Rails)
43
+ end
44
+
41
45
  def override_defaults
42
46
  @endpoint ||= ApiSixClient.config.endpoint
43
47
  @auth_token ||= ApiSixClient.config.auth_token
@@ -55,7 +59,15 @@ module ApiSixClient
55
59
  end
56
60
 
57
61
  def request(method, path, params = {}, headers = {})
58
- response = connection.run_request(method, "#{endpoint}/#{service_path}/#{path}", params.to_json, headers)
62
+ deprecation_msg
63
+
64
+ response = nil
65
+ begin
66
+ response = connection.run_request(method, "#{endpoint}/#{service_path}/#{path}", params.to_json, headers)
67
+ rescue Faraday::Error => e
68
+ raise Errors::FaradayError.new("#{e.to_s} by #{self.class.name}##{path}")
69
+ end
70
+
59
71
  res = JSON.parse(response.body)
60
72
 
61
73
  return res.with_indifferent_access if res.is_a?(Hash)
@@ -4,6 +4,9 @@ module ApiSixClient
4
4
  class BaseInt < Base
5
5
  protected
6
6
 
7
+ def deprecation_msg
8
+ end
9
+
7
10
  def override_defaults
8
11
  @endpoint = ApiSixClient.config.endpoint_int
9
12
  @auth_token = ApiSixClient.config.auth_token_int
@@ -4,5 +4,6 @@ module ApiSixClient
4
4
  module Errors
5
5
  class EndpointIsEmpty < StandardError; end
6
6
  class AuthTokenIsEmpty < StandardError; end
7
+ class FaradayError < StandardError; end
7
8
  end
8
9
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module ApiSixClient
4
- VERSION = "1.2.8"
4
+ VERSION = "1.2.10"
5
5
  end
@@ -31,15 +31,16 @@ module ApiSixClient
31
31
 
32
32
  class OlcInt < BaseInt; end
33
33
  class PrjInt < BaseInt; end
34
-
35
- class AuthInt < BaseV2Int; end
36
- class UasInt < BaseV2Int; end
37
- class NtfInt < BaseV2Int; end
38
- class MatInt < BaseV2Int; end
39
- class FinnInt < BaseV2Int; end
40
- class LyrInt < BaseV2Int; end
41
- class BrgInt < BaseV2Int; end
42
- class Val < BaseV2Int; end
34
+ class UasInt < BaseInt; end
35
+ class BrgInt < BaseInt; end
36
+ class CadInt < BaseInt; end
37
+ class AuthInt < BaseInt; end
38
+ class NtfInt < BaseInt; end
39
+ class MatInt < BaseInt; end
40
+ class FinnInt < BaseInt; end
41
+ class LyrInt < BaseInt; end
42
+ class GbkInt < BaseInt; end
43
+ class Val < BaseInt; end
43
44
  end
44
45
 
45
46
  A6C = ApiSixClient
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: api_six_client
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.8
4
+ version: 1.2.10
5
5
  platform: ruby
6
6
  authors:
7
7
  - Eugene Dobrorodnov
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2023-11-03 00:00:00.000000000 Z
11
+ date: 2023-11-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday