honeybadger 2.7.0 → 2.7.1

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: bfe22be20c43fd975d126fc91fb7cb898c670757
4
- data.tar.gz: 23b9996827b81249114e8c87b016d00f01f08762
3
+ metadata.gz: ddefba8d4173d277935d346dd7c56212e388ac54
4
+ data.tar.gz: 9044c43d190b25f177f730d7595d72e779080b35
5
5
  SHA512:
6
- metadata.gz: 6d5319144574a8f37e9256aa3786162a185da7abdaf2805844e9b100a4952659a53edce559b3e7c03b51a211e16cc2817338a512f35f159c19ec0a875192a3da
7
- data.tar.gz: b15017e7866fb9c3acc9d09543644d088b5914a1f671fa85bdbfaf7665b20a2755f1fee272614370536efe5e2bb98d6911584d934347a054a11f3120964fba27
6
+ metadata.gz: f29452cfd8b66be94f4eb120fa7f3a6e1a4a4257e420e1d209c3587002bb633d4f41cb5e040ab091821e4fa919a8d286e2ace9cb59d7dc0eecddaa0397e6eb57
7
+ data.tar.gz: 5a3039f0c4be455e814695a70266a24dcb024777ccc598f77931512af5e9dafbb4a88e63d1611a0f97b0f2b1a42161100fbee2da7080e019014534b2c2abc3e1
data/CHANGELOG.md CHANGED
@@ -3,11 +3,18 @@ All notable changes to this project will be documented in this file. See [Keep a
3
3
  CHANGELOG](http://keepachangelog.com/) for how to update this file. This project
4
4
  adheres to [Semantic Versioning](http://semver.org/).
5
5
 
6
- ## [Unreleased][unreleased]
6
+ ## [Unreleased]
7
+
8
+ ## [2.7.1] - 2016-11-16
9
+ ### Fixed
10
+ - Fix a Sinatra bug where `RACK_ENV` default was not used as default env.
11
+ - Fixed an error when accessing notice request data from `exception_fingerprint`
12
+ callback.
7
13
 
8
14
  ## [2.7.0] - 2016-10-20
9
15
  ### Added
10
16
  - Support Sinatra 2.0.
17
+ - Source snippets are now sent for every line of the backtrace.
11
18
 
12
19
  ### Changed
13
20
  - Sunset performance metrics. See
@@ -33,7 +33,7 @@ module Honeybadger
33
33
  },
34
34
  env: {
35
35
  description: 'The current application\'s environment name.',
36
- default: ENV['HONEYBADGER_ENV'] || ENV['RACK_ENV'],
36
+ default: ENV['HONEYBADGER_ENV'] || ENV['RACK_ENV'] || ENV['APP_ENV'],
37
37
  type: String
38
38
  },
39
39
  report_data: {
@@ -12,8 +12,7 @@ module Honeybadger
12
12
 
13
13
  def honeybadger_config(app)
14
14
  {
15
- api_key: defined?(honeybadger_api_key) ? honeybadger_api_key : nil,
16
- env: ENV['APP_ENV']
15
+ api_key: defined?(honeybadger_api_key) ? honeybadger_api_key : nil
17
16
  }
18
17
  end
19
18
 
@@ -139,7 +139,6 @@ module Honeybadger
139
139
  "#{exception.class.name}: #{exception.message}"
140
140
  end
141
141
  @backtrace = parse_backtrace(exception_attribute(:backtrace, caller))
142
- @fingerprint = construct_fingerprint(opts)
143
142
 
144
143
  @request = construct_request_hash(config, opts)
145
144
 
@@ -157,6 +156,9 @@ module Honeybadger
157
156
  @api_key = opts[:api_key] || config[:api_key]
158
157
 
159
158
  monkey_patch_action_dispatch_test_process!
159
+
160
+ # Fingerprint must be calculated last since callback operates on `self`.
161
+ @fingerprint = construct_fingerprint(opts)
160
162
  end
161
163
 
162
164
  # Internal: Template used to create JSON payload
@@ -366,8 +368,20 @@ module Honeybadger
366
368
  binding ||= exception.__honeybadger_bindings_stack[0]
367
369
 
368
370
  vars = binding.eval('local_variables')
369
- result = Hash[vars.map {|arg| [arg, binding.eval(arg.to_s)]}]
370
- request_sanitizer.sanitize(result)
371
+ results =
372
+ vars.inject([]) { |acc, arg|
373
+ begin
374
+ result = binding.eval(arg.to_s)
375
+ acc << [arg, result]
376
+ rescue NameError
377
+ # Do Nothing
378
+ end
379
+
380
+ acc
381
+ }
382
+
383
+ result_hash = Hash[results]
384
+ request_sanitizer.sanitize(result_hash)
371
385
  end
372
386
 
373
387
  # Internal: Should local variables be sent?
@@ -1,4 +1,4 @@
1
1
  module Honeybadger
2
2
  # Public: The current String Honeybadger version.
3
- VERSION = '2.7.0'.freeze
3
+ VERSION = '2.7.1'.freeze
4
4
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: honeybadger
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.7.0
4
+ version: 2.7.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Honeybadger Industries LLC
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-10-20 00:00:00.000000000 Z
11
+ date: 2016-11-17 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: Make managing application errors a more pleasant experience.
14
14
  email: