debug_logging 3.1.7 → 3.1.8

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
  SHA256:
3
- metadata.gz: 434bf02e4e2e51b0ae6ffb99e4d5174d212a2337744e1fd7697d66d804ccc062
4
- data.tar.gz: efb30cc90b8d325da9511f6899378b790916ad671af4b69df1b6171aa9cda80e
3
+ metadata.gz: 12a45427d0ca5aea996bd2ddce9da4ae3f763afe2e5b0abefea2173f6765ff61
4
+ data.tar.gz: 1a9d1a08b5f49daaa6f01c10c48b3a5345794a46f9b62f25243f13e6ebacd694
5
5
  SHA512:
6
- metadata.gz: 99ec10ad80d3caca7a1092365774530b017a15276515f06b610dfd39e0e3e7f9883f59489d53ac2162b36e6c39371eb115b588524c8c9ed2cd4355b30a61bd89
7
- data.tar.gz: 9af78b97aed63a43e63c27e998d9c713ece75825bcc91b6be704cf757a289c43b96a106d5ef5bff2783828dfac3bd4d48ae110fcfd3841fb556c88cb64bb9108
6
+ metadata.gz: f55f81ffe673ec404dd49fc26db2778abf3311a3f7f148a85c5030369cb469b8570c8728db5526b838caf2e09b22e04ad314ab27c462b8b246905e00945b2d9a
7
+ data.tar.gz: c5bc397f5b50d19551d7db9b6d7fe9cafa034ff36cbac2551d9c2a52d0e9a9f70992d0efb49a46fabf6830f76818b15eaf6653be9fee38aad415af9d2f92510a
data/README.md CHANGED
@@ -110,7 +110,7 @@ DebugLogging.configuration.ellipsis = ' ✂️ …'.freeze
110
110
  DebugLogging.configuration.mark_scope_exit = true # Only has an effect if benchmarking is off, since benchmarking always marks the scope exit
111
111
  DebugLogging.configuration.add_payload = false # or a proc which will be called to print the payload
112
112
  DebugLogging.configuration.payload_max_length = 1000
113
- DebugLogging.configuration.error_handler_proc = nil # e.g. ->(error, config, obj) { config.log { "#{error.class}: #{error.message}\n#{obj.errors.inspect}" } }
113
+ DebugLogging.configuration.error_handler_proc = nil # e.g. ->(error, config, obj, method_name, args) { config.log { "#{error.class}: #{error.message} in #{method_name}\nargs: #{args.inspect}" } }
114
114
  ```
115
115
 
116
116
  If you prefer to use the block style:
@@ -134,7 +134,7 @@ DebugLogging.configure do |config|
134
134
  config.mark_scope_exit = true # Only has an effect if benchmarking is off, since benchmarking always marks the scope exit
135
135
  config.add_payload = false # or a proc which will be called to print the payload
136
136
  config.payload_max_length = 1000
137
- config.error_handler_proc = nil # e.g. ->(error, config, obj) { config.log { "#{error.class}: #{error.message}\n#{obj.errors.inspect}" } }
137
+ config.error_handler_proc = nil # e.g. ->(error, config, obj, method_name, args) { config.log { "#{error.class}: #{error.message} in #{method_name}\nargs: #{args.inspect}" } }
138
138
  end
139
139
  ```
140
140
 
@@ -62,7 +62,7 @@ module DebugLogging
62
62
  method_return_value
63
63
  rescue => error
64
64
  if config_proxy.error_handler_proc
65
- config_proxy.error_handler_proc.call(config_proxy, error, self)
65
+ config_proxy.error_handler_proc.call(config_proxy, error, self, method_to_log, args)
66
66
  else
67
67
  raise error
68
68
  end
@@ -48,7 +48,7 @@ module DebugLogging
48
48
  end
49
49
  rescue => error
50
50
  if config_proxy.error_handler_proc
51
- config_proxy.error_handler_proc.call(config_proxy, error, self)
51
+ config_proxy.error_handler_proc.call(config_proxy, error, self, method_to_notify, args)
52
52
  else
53
53
  raise error
54
54
  end
@@ -44,7 +44,7 @@ module DebugLogging
44
44
  method_return_value = super(*args, &block)
45
45
  rescue => error
46
46
  if config_proxy.error_handler_proc
47
- config_proxy.error_handler_proc.call(config_proxy, error, self)
47
+ config_proxy.error_handler_proc.call(config_proxy, error, self, method_to_log, args)
48
48
  else
49
49
  raise error
50
50
  end
@@ -41,7 +41,7 @@ module DebugLogging
41
41
  super(*args, &block)
42
42
  rescue => error
43
43
  if config_proxy.error_handler_proc
44
- config_proxy.error_handler_proc.call(config_proxy, error, self)
44
+ config_proxy.error_handler_proc.call(config_proxy, error, self, method_to_notify, args)
45
45
  else
46
46
  raise error
47
47
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module DebugLogging
4
- VERSION = '3.1.7'
4
+ VERSION = '3.1.8'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: debug_logging
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.1.7
4
+ version: 3.1.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Peter Boling