appsignal 0.11.16 → 0.11.17

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: 3e8df99b6b521fdda3a9e54873ea46bad0e1667f
4
- data.tar.gz: 32711b82d0e91a9cc08bde77ec0bc62bcc858129
3
+ metadata.gz: 9134a3a7b0864bbdbf6c23ee90d43537adc7faa9
4
+ data.tar.gz: 3c86992c153bcfceed5fae3db112d7e066b51c30
5
5
  SHA512:
6
- metadata.gz: a7b0a13d1709bc11fd09857b56a2090a28dfdf872484bdc8f6c107ebb94935dc6b12bf1928359cee8816bebda5cc25ed41d277c43faace2876dc94bb25600d34
7
- data.tar.gz: 052a53b0fe02ff563b6a54aa8e8066e169c5661568cb75d4c27e3ef894ae17f51c4bd35ab25c0dc08d5f20a4738fc522f4fb1ef94bc7f6d002ee8deabab72354
6
+ metadata.gz: 87aa26b8f6412505484af7adc3250f8339936cd71c09aeb3772c414f79813dcda1fbcafd9d02b7742fcc675d90abc81c5b39cd8b55d49735a6ec251b26185406
7
+ data.tar.gz: acf5e0a21d3a5a163bb40da40d5083f9a644050d21dbab767dd7b237df39b7adfdeca8e5af7b98f966bb4fb4827905bd602423de1cdb0a544181ba6d6482842a
@@ -1,3 +1,6 @@
1
+ # 0.11.17
2
+ * Fix for bug using rack request in `send_exception`
3
+
1
4
  # 0.11.16
2
5
  * Send tags passed to the frontend error catcher
3
6
  * Fix issue with ActiveAdmin sending incompatible instrumentation events
@@ -106,7 +106,7 @@ module Appsignal
106
106
  logger.error('Can\'t send exception, given value is not an exception')
107
107
  return
108
108
  end
109
- transaction = Appsignal::Transaction.create(SecureRandom.uuid, ENV)
109
+ transaction = Appsignal::Transaction.create(SecureRandom.uuid, nil)
110
110
  transaction.add_exception(exception)
111
111
  transaction.set_tags(tags) if tags
112
112
  transaction.complete!
@@ -60,7 +60,7 @@ module Appsignal
60
60
  end
61
61
 
62
62
  def request
63
- ::Rack::Request.new(@env)
63
+ ::Rack::Request.new(@env) if @env
64
64
  end
65
65
 
66
66
  def set_tags(given_tags={})
@@ -244,6 +244,7 @@ module Appsignal
244
244
  end
245
245
 
246
246
  def sanitize_session_data!
247
+ return unless request
247
248
  @sanitized_session_data = Appsignal::ParamsSanitizer.sanitize(
248
249
  request.session.to_hash
249
250
  ) if Appsignal.config[:skip_session_data] == false
@@ -1,3 +1,3 @@
1
1
  module Appsignal
2
- VERSION = '0.11.16'
2
+ VERSION = '0.11.17'
3
3
  end
@@ -77,6 +77,12 @@ describe Appsignal::Transaction do
77
77
  subject { transaction.request }
78
78
 
79
79
  it { should be_a ::Rack::Request }
80
+
81
+ context "without env" do
82
+ let(:env) { nil }
83
+
84
+ it { should be_nil }
85
+ end
80
86
  end
81
87
 
82
88
  describe '#set_process_action_event' do
@@ -738,6 +744,18 @@ describe Appsignal::Transaction do
738
744
  transaction.sanitized_session_data.should == {}
739
745
  end
740
746
  end
747
+
748
+ context "without a request" do
749
+ before do
750
+ transaction.stub(:request => nil)
751
+ end
752
+
753
+ it "does not pass the session data into the params sanitizer" do
754
+ Appsignal::ParamsSanitizer.should_not_receive(:sanitize)
755
+ subject
756
+ transaction.sanitized_session_data.should == {}
757
+ end
758
+ end
741
759
  end
742
760
 
743
761
  describe '#sanitize_params!' do
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: appsignal
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.11.16
4
+ version: 0.11.17
5
5
  platform: ruby
6
6
  authors:
7
7
  - Robert Beekman
@@ -12,7 +12,7 @@ authors:
12
12
  autorequire:
13
13
  bindir: bin
14
14
  cert_chain: []
15
- date: 2015-10-19 00:00:00.000000000 Z
15
+ date: 2015-10-20 00:00:00.000000000 Z
16
16
  dependencies:
17
17
  - !ruby/object:Gem::Dependency
18
18
  name: rack