kybus-core 0.2.0 → 0.2.1

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: cd55b83dbc2c6e862925f961aa4fec0cb29203e259e272594bd88d1ec3d7c129
4
- data.tar.gz: f534b7e922576f5aa7441cf8e9936a47aa0c5b8b0de660e9735dbca1d846449f
3
+ metadata.gz: 7a5d763d51ea9b988a62354a9b3473a84b1d0caec777c65c5b0bdcf63c8ec870
4
+ data.tar.gz: c40d99eee6c8268bc958382f343cd2d8db7b5c7fb4d07f3f9ca069b850240d72
5
5
  SHA512:
6
- metadata.gz: 4647c134aae920e83eba384e3404a9820ee2a604875591e157f69a8ba4328039ef4894a23b869df6d01da876935ca896962ade60e9cdc5f5ceeb5b5e770a0cf3
7
- data.tar.gz: 43a844b37b6479368c0ebbc67a9b027c4e33d595bb0bdcc7007e7182a6dfbeb227cc34e60367a851147222b386f7f053271d691b9dc0dcad3a6dd499716081d2
6
+ metadata.gz: c7d9aae7f0c6ff7f9014aa8fe849f26bb5448671b208210c78bd44dcdf12c167efeb94cdab3faffdcf60f54cdc5846b395d0281ed04bf644f19f5f9789a27752
7
+ data.tar.gz: 4c670ac9f1361c800717e22ec6d7a87f37f91d51f5ddfe702d9b246bbec5cd55716ffb24ce48aa6daaf8d1d8ece150c57e8950ce6295d16b8c1a8bff31260932
@@ -15,7 +15,7 @@ module Kybus
15
15
  # The default is the exception class, so it won't change
16
16
  # almost never.
17
17
  # @param data. Contains additional data to detail the error.
18
- class AntBaseException < StandardError
18
+ class KybussBaseException < StandardError
19
19
  attr_reader :message, :code, :data
20
20
 
21
21
  def initialize(message, code, data)
@@ -41,20 +41,20 @@ module Kybus
41
41
 
42
42
  ##
43
43
  # Is used to express a success with the client's request.
44
- class AntSuccess < AntBaseException
44
+ class KybussSuccess < KybusBaseException
45
45
  def initialize(message, code = nil, data = {})
46
46
  code ||= self.class.name.split('::').last
47
- super(message, code, data)
47
+ super
48
48
  end
49
49
  end
50
50
 
51
51
  ##
52
52
  # Is used to express a problem with the client's request.
53
- class AntFail < AntBaseException
53
+ class KybussFail < KybusBaseException
54
54
  def initialize(message, code = nil, data = {})
55
55
  code ||= self.class.name.split('::').last
56
- code = 'BadRequest' if code == 'AntFail'
57
- super(message, code, data)
56
+ code = 'BadRequest' if code == 'KybusFail'
57
+ super
58
58
  end
59
59
  end
60
60
 
@@ -62,11 +62,11 @@ module Kybus
62
62
  # Is used to express an error that was found during the execution of the
63
63
  # program but it also means that the invoked endpoint has not the power to
64
64
  # fix it, so it will only complain.
65
- class AntError < AntBaseException
65
+ class KybussError < KybusBaseException
66
66
  def initialize(message, code = nil, data = {})
67
67
  code ||= self.class.name.split('::').last
68
- code = 'ServerError' if code == 'AntError'
69
- super(message, code, data)
68
+ code = 'ServerError' if code == 'kybusError'
69
+ super
70
70
  end
71
71
  end
72
72
  end
@@ -8,9 +8,9 @@ module Kybus
8
8
  module HTTP
9
9
  class << self
10
10
  EXCEPTION_TYPES = {
11
- success: Kybus::Exceptions::AntSuccess,
12
- fail: Kybus::Exceptions::AntFail,
13
- error: Kybus::Exceptions::AntError
11
+ success: Kybus::Exceptions::KybusSuccess,
12
+ fail: Kybus::Exceptions::KybusFail,
13
+ error: Kybus::Exceptions::KybusError
14
14
  }.freeze
15
15
 
16
16
  def new_http_exception(class_name, http_code, type)
data/lib/kybus/version.rb CHANGED
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Kybus
4
4
  module Core
5
- VERSION = '0.2.0'
5
+ VERSION = '0.2.1'
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,141 +1,15 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: kybus-core
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0
4
+ version: 0.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Gilberto Vargas
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-11-17 00:00:00.000000000 Z
12
- dependencies:
13
- - !ruby/object:Gem::Dependency
14
- name: kybus-logger
15
- requirement: !ruby/object:Gem::Requirement
16
- requirements:
17
- - - "~>"
18
- - !ruby/object:Gem::Version
19
- version: '0.1'
20
- type: :development
21
- prerelease: false
22
- version_requirements: !ruby/object:Gem::Requirement
23
- requirements:
24
- - - "~>"
25
- - !ruby/object:Gem::Version
26
- version: '0.1'
27
- - !ruby/object:Gem::Dependency
28
- name: minitest
29
- requirement: !ruby/object:Gem::Requirement
30
- requirements:
31
- - - "~>"
32
- - !ruby/object:Gem::Version
33
- version: '5.11'
34
- type: :development
35
- prerelease: false
36
- version_requirements: !ruby/object:Gem::Requirement
37
- requirements:
38
- - - "~>"
39
- - !ruby/object:Gem::Version
40
- version: '5.11'
41
- - !ruby/object:Gem::Dependency
42
- name: mocha
43
- requirement: !ruby/object:Gem::Requirement
44
- requirements:
45
- - - "~>"
46
- - !ruby/object:Gem::Version
47
- version: '1.8'
48
- type: :development
49
- prerelease: false
50
- version_requirements: !ruby/object:Gem::Requirement
51
- requirements:
52
- - - "~>"
53
- - !ruby/object:Gem::Version
54
- version: '1.8'
55
- - !ruby/object:Gem::Dependency
56
- name: pry
57
- requirement: !ruby/object:Gem::Requirement
58
- requirements:
59
- - - "~>"
60
- - !ruby/object:Gem::Version
61
- version: '0.12'
62
- type: :development
63
- prerelease: false
64
- version_requirements: !ruby/object:Gem::Requirement
65
- requirements:
66
- - - "~>"
67
- - !ruby/object:Gem::Version
68
- version: '0.12'
69
- - !ruby/object:Gem::Dependency
70
- name: rack-minitest
71
- requirement: !ruby/object:Gem::Requirement
72
- requirements:
73
- - - "~>"
74
- - !ruby/object:Gem::Version
75
- version: '0.0'
76
- type: :development
77
- prerelease: false
78
- version_requirements: !ruby/object:Gem::Requirement
79
- requirements:
80
- - - "~>"
81
- - !ruby/object:Gem::Version
82
- version: '0.0'
83
- - !ruby/object:Gem::Dependency
84
- name: rake
85
- requirement: !ruby/object:Gem::Requirement
86
- requirements:
87
- - - "~>"
88
- - !ruby/object:Gem::Version
89
- version: '12.3'
90
- type: :development
91
- prerelease: false
92
- version_requirements: !ruby/object:Gem::Requirement
93
- requirements:
94
- - - "~>"
95
- - !ruby/object:Gem::Version
96
- version: '12.3'
97
- - !ruby/object:Gem::Dependency
98
- name: rdoc
99
- requirement: !ruby/object:Gem::Requirement
100
- requirements:
101
- - - "~>"
102
- - !ruby/object:Gem::Version
103
- version: '6.1'
104
- type: :development
105
- prerelease: false
106
- version_requirements: !ruby/object:Gem::Requirement
107
- requirements:
108
- - - "~>"
109
- - !ruby/object:Gem::Version
110
- version: '6.1'
111
- - !ruby/object:Gem::Dependency
112
- name: simplecov
113
- requirement: !ruby/object:Gem::Requirement
114
- requirements:
115
- - - "~>"
116
- - !ruby/object:Gem::Version
117
- version: '0.16'
118
- type: :development
119
- prerelease: false
120
- version_requirements: !ruby/object:Gem::Requirement
121
- requirements:
122
- - - "~>"
123
- - !ruby/object:Gem::Version
124
- version: '0.16'
125
- - !ruby/object:Gem::Dependency
126
- name: webmock
127
- requirement: !ruby/object:Gem::Requirement
128
- requirements:
129
- - - "~>"
130
- - !ruby/object:Gem::Version
131
- version: '3.5'
132
- type: :development
133
- prerelease: false
134
- version_requirements: !ruby/object:Gem::Requirement
135
- requirements:
136
- - - "~>"
137
- - !ruby/object:Gem::Version
138
- version: '3.5'
11
+ date: 2024-07-03 00:00:00.000000000 Z
12
+ dependencies: []
139
13
  description: |2
140
14
  Kybus::Core will be used across all the kybus gems. Provides the most basic
141
15
  functionality or what might be used along with more than one gem.
@@ -172,7 +46,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
172
46
  - !ruby/object:Gem::Version
173
47
  version: '0'
174
48
  requirements: []
175
- rubygems_version: 3.3.7
49
+ rubygems_version: 3.5.14
176
50
  signing_key:
177
51
  specification_version: 4
178
52
  summary: Kybus framework core functionality