killbill-client 4.0.4 → 4.0.6

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
  SHA1:
3
- metadata.gz: c32f144967f254d3f1bd42faedde590117f0e289
4
- data.tar.gz: 34769df0f76d0e7823df1cdc50b9da9af438a899
3
+ metadata.gz: 31adb602c314f8de1252ffe021141878f4fcac84
4
+ data.tar.gz: 21c6b2aa1caed17c653f9b68bab2f4486f64fcc6
5
5
  SHA512:
6
- metadata.gz: 97064571ead35a13a05abe82f91d08ef29545a13c5072570a4b2e14811b22116d81b2b152cb40f37d5f4755209a428fbbc8e67065a245554cb20210752d60f5f
7
- data.tar.gz: 33d0e17814a64709a085cf0dc6cf51015c40cc2298da87c735c2dc51ca14bd76aeae0d1c228f943f19fe3ad19a98b09c6299738ae45d7028f6cbbb02995ac821
6
+ metadata.gz: 955feb2439672126f43a76b3163560e3cf15ff150ae832c5e80b3c7fc9369dbcdca0e4480a2f7bc3f82b2e5740a6c48254a00110a9e7343685a846a6d8b73cfc
7
+ data.tar.gz: b45da24a25e77779133b17338f50ac2ff5d41de5c7276701c72cbe7ebe51865b4583abbb5532add4f1005f61f4bd2d5835be506225f8870eb3ee2878d057098a
@@ -25,6 +25,12 @@ jobs:
25
25
  database-password: 'root'
26
26
  database-port: '3306'
27
27
  docker-compose-file: 'docker-compose.ci.mysql.yml'
28
+ - ruby-version: '3.3.5'
29
+ database-adapter: 'postgresql'
30
+ database-user: 'postgres'
31
+ database-password: 'postgres'
32
+ database-port: '5432'
33
+ docker-compose-file: 'docker-compose.ci.postgresql.yml'
28
34
  - ruby-version: 'jruby-9.1.17.0'
29
35
  database-adapter: 'mysql2'
30
36
  database-user: 'root'
@@ -37,6 +43,12 @@ jobs:
37
43
  database-password: 'postgres'
38
44
  database-port: '5432'
39
45
  docker-compose-file: 'docker-compose.ci.postgresql.yml'
46
+ - ruby-version: '3.3.5'
47
+ database-adapter: 'postgresql'
48
+ database-user: 'postgres'
49
+ database-password: 'postgres'
50
+ database-port: '5432'
51
+ docker-compose-file: 'docker-compose.ci.postgresql.yml'
40
52
  - ruby-version: 'jruby-9.1.17.0'
41
53
  database-adapter: 'postgresql'
42
54
  database-user: 'postgres'
@@ -37,14 +37,14 @@ module KillBillClient
37
37
 
38
38
  def build_uri(relative_uri, options)
39
39
  # Need to encode in case of spaces (e.g. /1.0/kb/security/users/Mad Max/roles)
40
- encoded_relative_uri = URI::DEFAULT_PARSER.escape(relative_uri)
40
+ encoded_relative_uri = URI::DEFAULT_PARSER.regexp[:UNSAFE].match?(relative_uri) ? relative_uri : URI::DEFAULT_PARSER.escape(relative_uri)
41
41
  if URI(encoded_relative_uri).scheme.nil?
42
42
  uri = (options[:base_uri] || KillBillClient::API.base_uri)
43
43
  uri = URI.parse(uri) unless uri.is_a?(URI)
44
44
  # Note: make sure to keep the full path (if any) from URI::HTTP, for non-ROOT deployments
45
45
  # See https://github.com/killbill/killbill/issues/221#issuecomment-151980263
46
46
  base_path = uri.request_uri == '/' ? '' : uri.request_uri
47
- uri += (base_path + URI::DEFAULT_PARSER.escape(relative_uri))
47
+ uri += (base_path + encoded_relative_uri)
48
48
  else
49
49
  uri = encoded_relative_uri
50
50
  uri = URI.parse(uri) unless uri.is_a?(URI)
@@ -174,15 +174,16 @@ module KillBillClient
174
174
 
175
175
  def attribute(name)
176
176
  send('attr_accessor', name.to_sym)
177
- attributes = @json_attributes ||= []
178
- begin
179
- json_attributes.push(name.to_s)
180
- rescue NameError
181
- (class << self; self; end).
182
- send(:define_method, :json_attributes) { attributes }
183
- retry
184
- end
185
- end
177
+ attributes = @json_attributes ||= []
178
+
179
+ if respond_to?(:json_attributes, true)
180
+ json_attributes.push(name.to_s)
181
+ else
182
+ (class << self; self; end).
183
+ send(:define_method, :json_attributes) { attributes }
184
+ json_attributes.push(name.to_s)
185
+ end
186
+ end
186
187
 
187
188
  def has_many(attr_name, type = nil)
188
189
  send("attr_accessor", attr_name.to_sym)
@@ -1,3 +1,3 @@
1
1
  module KillBillClient
2
- VERSION = '4.0.4'
2
+ VERSION = '4.0.6'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: killbill-client
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.0.4
4
+ version: 4.0.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Killbill core team
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-10-21 00:00:00.000000000 Z
11
+ date: 2025-04-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: gem-release
@@ -214,7 +214,7 @@ homepage: http://www.killbilling.org
214
214
  licenses:
215
215
  - Apache-2.0
216
216
  metadata: {}
217
- post_install_message:
217
+ post_install_message:
218
218
  rdoc_options:
219
219
  - "--exclude"
220
220
  - "."
@@ -231,9 +231,9 @@ required_rubygems_version: !ruby/object:Gem::Requirement
231
231
  - !ruby/object:Gem::Version
232
232
  version: '0'
233
233
  requirements: []
234
- rubyforge_project:
234
+ rubyforge_project:
235
235
  rubygems_version: 2.6.13
236
- signing_key:
236
+ signing_key:
237
237
  specification_version: 4
238
238
  summary: Kill Bill client library.
239
239
  test_files: []