radiator 0.3.13 → 0.3.14

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
  SHA1:
3
- metadata.gz: 8b2942acc286e86b0495674fdf08ef83cb8b9ba1
4
- data.tar.gz: 9b4f8c9eee079e0c1d7b31aa977a7a322c908c15
3
+ metadata.gz: 0db00c90a07862e3bb92b0ce2e6add02ab0e0b0c
4
+ data.tar.gz: de07643e3376f9f5e05c80d74f9a0b6bdc433689
5
5
  SHA512:
6
- metadata.gz: 35d4b8aed21429194c6f1df3c4985daeef0163236011636b35cd17ffce48b4bc1cfec0c625bb62990bcb9a3b33c3ef7dfc4831de6921b6d17855c10f378e7b52
7
- data.tar.gz: 1b2fed7d16822b22ac943c5f21454b9c6e843dc1519688bcc90b964b658824e27bab790e865d19775467fb39d6a9e6429dc5a03194cf7643c7f9ed452e73e3a1
6
+ metadata.gz: 1592bc3aedc5eff5276f347907f6d741e82ae8b37539ac6d668fe8d68c165501505612cc4ccc375b1d9ded797f318cb7ca6b9fbb8fbb148ae3eff5016be567ea
7
+ data.tar.gz: 3f4596f76c97708d78bc4520313fd73dd65466350cb14241b6549ea3b05e1342bca62d740c4e8b2c60d47fbbb78dc9cd148de8084f506e4424f5ccb9884bbfcc
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- radiator (0.3.13)
4
+ radiator (0.3.14)
5
5
  awesome_print (~> 1.7, >= 1.7.0)
6
6
  bitcoin-ruby (~> 0.0, >= 0.0.11)
7
7
  ffi (~> 1.9, >= 1.9.18)
@@ -1,5 +1,3 @@
1
- require 'awesome_print'
2
-
3
1
  module Radiator
4
2
  class ErrorParser
5
3
  include Utils
@@ -118,7 +116,11 @@ module Radiator
118
116
  @can_reprepare = false
119
117
  end
120
118
  rescue => e
121
- ap error_perser_exception: e, original_response: response
119
+ if defined? ap
120
+ ap error_perser_exception: e, original_response: response
121
+ else
122
+ puts({error_perser_exception: e, original_response: response}.inspect)
123
+ end
122
124
 
123
125
  @expiry = false
124
126
  @can_retry = false
@@ -37,10 +37,18 @@ module Radiator
37
37
  puts "#{level}: #{log_message}"
38
38
  end
39
39
  else
40
- if !!prefix
41
- @logger.ap log_level: level, prefix => obj
40
+ if defined? @logger.ap
41
+ if !!prefix
42
+ @logger.ap log_level: level, prefix => obj
43
+ else
44
+ @logger.ap obj, level
45
+ end
42
46
  else
43
- @logger.ap obj, level
47
+ if !!prefix
48
+ @logger.send level, ({prefix => obj}).inspect
49
+ else
50
+ @logger.send level, obj.inspect
51
+ end
44
52
  end
45
53
  end
46
54
 
@@ -1,4 +1,4 @@
1
1
  module Radiator
2
- VERSION = '0.3.13'
2
+ VERSION = '0.3.14'
3
3
  AGENT_ID = "radiator/#{VERSION}"
4
4
  end
data/lib/radiator.rb CHANGED
@@ -1,5 +1,6 @@
1
1
  require 'radiator/version'
2
2
  require 'json'
3
+ require 'awesome_print' if ENV['USE_AWESOME_PRINT'] == 'true'
3
4
 
4
5
  module Radiator
5
6
  require 'radiator/utils'
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: radiator
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.13
4
+ version: 0.3.14
5
5
  platform: ruby
6
6
  authors:
7
7
  - Anthony Martin