zerobounce 0.2.2 → 0.3.0

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: 9317c9c0d5ce41ca5c3d27d9d71706383b9687d65b58eed217a786e1c4d1ab9a
4
- data.tar.gz: 9924d6348aec8c24c470384569f183bc107746ac16d67c699b455c68e70b4b3c
3
+ metadata.gz: e19fc9a3e9db7160fa79d71664a45d3c731cd3aabfe9a92249be8e65db1d004e
4
+ data.tar.gz: e327cfb318f27615a2f54f036b6a4aebdfabf60071b72748a11c8edd945cd4dc
5
5
  SHA512:
6
- metadata.gz: 6fa9a4f46f860bb9352e71ed50017cf6df96426a52d44b1f2c3ebdfa9f467a74b353bcbcd6ced03e19264034d141272f438763f2e8c0f098c901cf7cafed5532
7
- data.tar.gz: eb17307f8b3bd194abfac75e20fa18c56856d3c421f4a98e294ba98114dcf80edf652d849b6cb56a39238f0a08ba02ac6866d4619286ab16ee157ac3bc41d4d2
6
+ metadata.gz: 6dcb6966babc9d36a427de4382d32edca78e8c8ae241d440737f53e3b57371f495bc2147e0692df008ed8916d8edff5606ace2ce97dbcef4446ab1291233d296
7
+ data.tar.gz: f8b2c440313cb58d0a003b0cce0e2820f2387d0d5be53e787df891d4ab11eb78a0ea8065c860466c25fe1d718b6d67a0cc4c26f0bfac253db8b2bcbeb07a05a4
@@ -21,7 +21,7 @@ jobs:
21
21
  runs-on: ubuntu-latest
22
22
  strategy:
23
23
  matrix:
24
- ruby-version: [ '2.5', '2.6', '2.7', '3.0' ]
24
+ ruby-version: ['2.6', '2.7', '3.0' ]
25
25
 
26
26
  steps:
27
27
  - uses: actions/checkout@v2
data/.rubocop.yml CHANGED
@@ -1,7 +1,7 @@
1
1
  require: rubocop-rspec
2
2
 
3
3
  AllCops:
4
- TargetRubyVersion: 2.5
4
+ TargetRubyVersion: 2.6
5
5
  NewCops: enable
6
6
 
7
7
  Exclude:
data/.ruby-version CHANGED
@@ -1 +1 @@
1
- ruby-2.7.3
1
+ ruby-2.7.8
data/CHANGELOG.md CHANGED
@@ -1,18 +1,24 @@
1
+ # 0.3.0
2
+
3
+ - Updated faraday to version 2.0.1
4
+ - Removed depricated faraday_middleware gem
5
+ - Updated minimum ruby version to 2.6
6
+
1
7
  # 0.2.0
2
8
 
3
- * Update faraday and faraday_middleware dependency requirements.
4
- * Update rubocop dev dependencies and fixed failures.
5
- * Updated minimum ruby version to 2.5.
9
+ - Update faraday and faraday_middleware dependency requirements.
10
+ - Update rubocop dev dependencies and fixed failures.
11
+ - Updated minimum ruby version to 2.5.
6
12
 
7
13
  # 0.1.2
8
14
 
9
- * Removed the double quote from the body check since it appears a space is added after the colon.
10
- * Added changelog file.
15
+ - Removed the double quote from the body check since it appears a space is added after the colon.
16
+ - Added changelog file.
11
17
 
12
18
  # 0.1.1
13
19
 
14
- * Removed safe accessor usage to work with older versions of Ruby.
20
+ - Removed safe accessor usage to work with older versions of Ruby.
15
21
 
16
22
  # 0.1.0
17
23
 
18
- * Added support for V2 of Zerobounce API.
24
+ - Added support for V2 of Zerobounce API.
@@ -1,8 +1,7 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  require 'faraday'
4
- require 'faraday_middleware'
5
- require 'zerobounce/middleware/raise_error'
4
+ require 'zerobounce/middleware/raise_http_exception'
6
5
 
7
6
  module Zerobounce
8
7
  # Configuration object for Zerobounce.
@@ -39,7 +38,7 @@ module Zerobounce
39
38
 
40
39
  def initialize
41
40
  self.host = 'https://api.zerobounce.net'
42
- self.apikey = ENV['ZEROBOUNCE_API_KEY']
41
+ self.apikey = ENV.fetch('ZEROBOUNCE_API_KEY', nil)
43
42
  self.api_version = 'v2'
44
43
  self.valid_statuses = %i[valid catch_all]
45
44
  self.headers = { user_agent: "ZerobounceRubyGem/#{Zerobounce::VERSION}" }
@@ -47,7 +46,7 @@ module Zerobounce
47
46
  self.middleware = proc do |builder|
48
47
  builder.response(:json, content_type: /\bjson$/, parser_options: { symbolize_names: true })
49
48
  builder.response(:logger) { |l| l.filter(/(api_?key=)(\w+)/, '\1[REMOVED]') } if ENV['ZEROBOUNCE_API_DEBUG']
50
- builder.use(Zerobounce::Middleware::RaiseError)
49
+ builder.use(Zerobounce::Middleware::RaiseHttpException)
51
50
  builder.adapter(Faraday.default_adapter)
52
51
  end
53
52
  end
@@ -8,7 +8,7 @@ module Zerobounce
8
8
  # Raises an error if the response wasn't successful.
9
9
  #
10
10
  # @author Aaron Frase
11
- class RaiseError < Faraday::Response::Middleware
11
+ class RaiseHttpException < Faraday::Middleware
12
12
  # Check for errors after the response has finished.
13
13
  #
14
14
  # @param [Hash] env
@@ -2,5 +2,5 @@
2
2
 
3
3
  module Zerobounce
4
4
  # The version of the gem.
5
- VERSION = '0.2.2'
5
+ VERSION = '0.3.0'
6
6
  end
data/zerobounce.gemspec CHANGED
@@ -4,7 +4,7 @@ lib = File.expand_path('lib', __dir__)
4
4
  $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
5
5
  require 'zerobounce/version'
6
6
 
7
- Gem::Specification.new do |spec| # rubocop:disable Metrics/BlockLength
7
+ Gem::Specification.new do |spec|
8
8
  spec.name = 'zerobounce'
9
9
  spec.version = Zerobounce::VERSION
10
10
  spec.authors = ['Aaron Frase']
@@ -24,12 +24,11 @@ Gem::Specification.new do |spec| # rubocop:disable Metrics/BlockLength
24
24
 
25
25
  spec.metadata['yard.run'] = 'yri' # use "yard" to build full HTML docs.
26
26
 
27
- spec.required_ruby_version = '>= 2.5'
27
+ spec.required_ruby_version = '>= 2.6'
28
28
 
29
- spec.add_dependency 'faraday', '>= 0.14', '< 2.0'
30
- spec.add_dependency 'faraday_middleware', '~> 1.0'
29
+ spec.add_dependency 'faraday', '>= 2.0.1'
31
30
 
32
- spec.add_development_dependency 'bundler', '~> 2.2.17'
31
+ spec.add_development_dependency 'bundler', '>= 2.2.17'
33
32
  spec.add_development_dependency 'pry', '~> 0.14.1'
34
33
  spec.add_development_dependency 'rake', '~> 13.0'
35
34
  spec.add_development_dependency 'rspec', '~> 3.0'
@@ -40,4 +39,5 @@ Gem::Specification.new do |spec| # rubocop:disable Metrics/BlockLength
40
39
  spec.add_development_dependency 'rubocop-rspec', '~> 2.3'
41
40
  spec.add_development_dependency 'simplecov', '~> 0.21.2'
42
41
  spec.add_development_dependency 'yard', '~> 0.9.26'
42
+ spec.metadata['rubygems_mfa_required'] = 'true'
43
43
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: zerobounce
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.2
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Aaron Frase
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-05-24 00:00:00.000000000 Z
11
+ date: 2023-04-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday
@@ -16,46 +16,26 @@ dependencies:
16
16
  requirements:
17
17
  - - ">="
18
18
  - !ruby/object:Gem::Version
19
- version: '0.14'
20
- - - "<"
21
- - !ruby/object:Gem::Version
22
- version: '2.0'
19
+ version: 2.0.1
23
20
  type: :runtime
24
21
  prerelease: false
25
22
  version_requirements: !ruby/object:Gem::Requirement
26
23
  requirements:
27
24
  - - ">="
28
25
  - !ruby/object:Gem::Version
29
- version: '0.14'
30
- - - "<"
31
- - !ruby/object:Gem::Version
32
- version: '2.0'
33
- - !ruby/object:Gem::Dependency
34
- name: faraday_middleware
35
- requirement: !ruby/object:Gem::Requirement
36
- requirements:
37
- - - "~>"
38
- - !ruby/object:Gem::Version
39
- version: '1.0'
40
- type: :runtime
41
- prerelease: false
42
- version_requirements: !ruby/object:Gem::Requirement
43
- requirements:
44
- - - "~>"
45
- - !ruby/object:Gem::Version
46
- version: '1.0'
26
+ version: 2.0.1
47
27
  - !ruby/object:Gem::Dependency
48
28
  name: bundler
49
29
  requirement: !ruby/object:Gem::Requirement
50
30
  requirements:
51
- - - "~>"
31
+ - - ">="
52
32
  - !ruby/object:Gem::Version
53
33
  version: 2.2.17
54
34
  type: :development
55
35
  prerelease: false
56
36
  version_requirements: !ruby/object:Gem::Requirement
57
37
  requirements:
58
- - - "~>"
38
+ - - ">="
59
39
  - !ruby/object:Gem::Version
60
40
  version: 2.2.17
61
41
  - !ruby/object:Gem::Dependency
@@ -236,7 +216,7 @@ files:
236
216
  - lib/zerobounce.rb
237
217
  - lib/zerobounce/configuration.rb
238
218
  - lib/zerobounce/error.rb
239
- - lib/zerobounce/middleware/raise_error.rb
219
+ - lib/zerobounce/middleware/raise_http_exception.rb
240
220
  - lib/zerobounce/request.rb
241
221
  - lib/zerobounce/request/v1_request.rb
242
222
  - lib/zerobounce/request/v2_request.rb
@@ -250,6 +230,7 @@ licenses:
250
230
  - MIT
251
231
  metadata:
252
232
  yard.run: yri
233
+ rubygems_mfa_required: 'true'
253
234
  post_install_message:
254
235
  rdoc_options: []
255
236
  require_paths:
@@ -258,14 +239,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
258
239
  requirements:
259
240
  - - ">="
260
241
  - !ruby/object:Gem::Version
261
- version: '2.5'
242
+ version: '2.6'
262
243
  required_rubygems_version: !ruby/object:Gem::Requirement
263
244
  requirements:
264
245
  - - ">="
265
246
  - !ruby/object:Gem::Version
266
247
  version: '0'
267
248
  requirements: []
268
- rubygems_version: 3.0.3.1
249
+ rubygems_version: 3.1.6
269
250
  signing_key:
270
251
  specification_version: 4
271
252
  summary: A Ruby client for Zerobounce.net.