taxjar-ruby 3.0.3 → 3.0.4

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: 18688d5bc45966595ed15e6d20eef07bd736db1344a901f8314cc290ac120dcf
4
- data.tar.gz: 2a3f17b97d09c5e4a5bc2f405884374e29bd0e8a326c29892d461bfe2b8db48e
3
+ metadata.gz: 0fd7067e606c95428f248d02ff6b4a69fc9c21a6bd0ddda37eb2d6ceffaa3744
4
+ data.tar.gz: f83a3a44b30d5bccbcb82e9fc7aee45c6b4751c69055f13a4e12671c70803133
5
5
  SHA512:
6
- metadata.gz: 5346c3672896ea11c88c741513003d4567ccc13cc33e7055abcae9529999a227bfc058c0d98a841881cc550c99b87ec0cacfe438f6e2f795c75c0a309e371992
7
- data.tar.gz: afd508979ce8b8cce3a0700170b6fb13acfea108faae1caf5fdcdbce173f0f62c18bfb17646e54f68d2bdc86c4713ce5115a3a0f197fdcf82aa20981941b2f0a
6
+ metadata.gz: ed65462a17a6505b43f9812ee5a66b9067d8308478330f85fbdc8cd76644e982bbe26a0dae7281b3c21d0f88d8fb7e4e0fff5a162377782774d6dff75d69e8a6
7
+ data.tar.gz: a7acb06bf4dfee72a549fa0c579ba5c27e87f299c647e51f13fbbab03b63e2386cc56c735277458fca52fba5a76d662c8e04a8c5131c6ab90111d5aa483fd6ce
data/.travis.yml CHANGED
@@ -7,5 +7,6 @@ rvm:
7
7
  - "2.6"
8
8
  - "2.7"
9
9
  - "3.0"
10
+ - "3.1"
10
11
 
11
12
  script: bundle exec rspec
data/CHANGELOG.md CHANGED
@@ -7,6 +7,10 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
7
7
 
8
8
  ## [Unreleased]
9
9
 
10
+ ## [3.0.4] - 2022-08-22
11
+ - Relaxes `http` version to allow >= 5
12
+ - Encodes client user agent using ISO-8859-1 character set
13
+
10
14
  ## [3.0.3] - 2022-02-07
11
15
  - Throw a `Taxjar::Error::GatewayTimeout` exception when receiving a 504 HTTP status code
12
16
 
data/lib/taxjar/client.rb CHANGED
@@ -45,7 +45,7 @@ module Taxjar
45
45
  end
46
46
  ruby_version = "ruby #{RUBY_VERSION}-p#{RUBY_PATCHLEVEL}"
47
47
  openSSL_version = OpenSSL::OPENSSL_LIBRARY_VERSION
48
- "TaxJar/Ruby (#{platform}; #{ruby_version}; #{openSSL_version}) taxjar-ruby/#{Taxjar::Version}"
48
+ "TaxJar/Ruby (#{platform}; #{ruby_version}; #{openSSL_version}) taxjar-ruby/#{Taxjar::Version}".encode("ISO-8859-1", invalid: :replace, undef: :replace)
49
49
  end
50
50
  end
51
51
  end
@@ -1,6 +1,7 @@
1
1
  module Taxjar
2
2
  module Version
3
- module_function
3
+ module_function
4
+
4
5
  def major
5
6
  3
6
7
  end
@@ -10,7 +11,7 @@ module Taxjar
10
11
  end
11
12
 
12
13
  def patch
13
- 3
14
+ 4
14
15
  end
15
16
 
16
17
  def pre
@@ -22,7 +23,7 @@ module Taxjar
22
23
  major: major,
23
24
  minor: minor,
24
25
  patch: patch,
25
- pre: pre,
26
+ pre: pre
26
27
  }
27
28
  end
28
29
 
@@ -46,5 +46,11 @@ describe Taxjar::Client do
46
46
  client = Taxjar::Client.new(api_key: 'AK')
47
47
  expect(client.user_agent).to match(/^TaxJar\/Ruby \(.+\) taxjar-ruby\/\d+\.\d+\.\d+$/)
48
48
  end
49
+
50
+ it 'encodes using the ISO-8859-1 character set' do
51
+ client = Taxjar::Client.new(api_key: 'AK')
52
+ allow(client).to receive(:platform).and_return("Curly’s MacBook Pro")
53
+ expect(client.user_agent).to match(/Curly\?s MacBook Pro/)
54
+ end
49
55
  end
50
56
  end
data/taxjar-ruby.gemspec CHANGED
@@ -21,11 +21,11 @@ Gem::Specification.new do |spec|
21
21
  spec.required_ruby_version = '>= 2.3'
22
22
 
23
23
  spec.add_dependency 'addressable', '~> 2.3'
24
- spec.add_dependency 'http', '>= 4.3', '< 5.0'
24
+ spec.add_dependency 'http', '>= 4.3'
25
25
  spec.add_dependency 'memoizable', '~> 0.4.0'
26
26
  spec.add_dependency 'model_attribute', '~> 3.2'
27
27
  spec.add_development_dependency "bundler", ">= 1.7", "< 3.0"
28
- spec.add_development_dependency "rake", "~> 12.0"
28
+ spec.add_development_dependency "rake", "~> 13.0"
29
29
 
30
30
  if spec.respond_to?(:metadata)
31
31
  spec.metadata['changelog_uri'] = 'https://github.com/taxjar/taxjar-ruby/blob/master/CHANGELOG.md'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: taxjar-ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.3
4
+ version: 3.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - TaxJar
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2022-06-07 00:00:00.000000000 Z
11
+ date: 2022-08-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: addressable
@@ -31,9 +31,6 @@ dependencies:
31
31
  - - ">="
32
32
  - !ruby/object:Gem::Version
33
33
  version: '4.3'
34
- - - "<"
35
- - !ruby/object:Gem::Version
36
- version: '5.0'
37
34
  type: :runtime
38
35
  prerelease: false
39
36
  version_requirements: !ruby/object:Gem::Requirement
@@ -41,9 +38,6 @@ dependencies:
41
38
  - - ">="
42
39
  - !ruby/object:Gem::Version
43
40
  version: '4.3'
44
- - - "<"
45
- - !ruby/object:Gem::Version
46
- version: '5.0'
47
41
  - !ruby/object:Gem::Dependency
48
42
  name: memoizable
49
43
  requirement: !ruby/object:Gem::Requirement
@@ -98,14 +92,14 @@ dependencies:
98
92
  requirements:
99
93
  - - "~>"
100
94
  - !ruby/object:Gem::Version
101
- version: '12.0'
95
+ version: '13.0'
102
96
  type: :development
103
97
  prerelease: false
104
98
  version_requirements: !ruby/object:Gem::Requirement
105
99
  requirements:
106
100
  - - "~>"
107
101
  - !ruby/object:Gem::Version
108
- version: '12.0'
102
+ version: '13.0'
109
103
  description: Ruby wrapper for Taxjar API, more info at developers.taxjar.com
110
104
  email:
111
105
  - support@taxjar.com
@@ -201,7 +195,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
201
195
  - !ruby/object:Gem::Version
202
196
  version: '0'
203
197
  requirements: []
204
- rubygems_version: 3.3.3
198
+ rubygems_version: 3.1.2
205
199
  signing_key:
206
200
  specification_version: 4
207
201
  summary: Ruby wrapper for Taxjar API