bugsnag 6.26.0 → 6.26.2

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: b81b73938dd3c97a31351658997cdfb8aea702e1f6aefb7393c6da413889e39a
4
- data.tar.gz: 8aa07e57b32cb7244d76f7070e67aa87e9155b8ed5ca368134873f4ac1a62505
3
+ metadata.gz: 87508e2fde2b235e826dea54f9f05ee75cca5d046cd76e95a5f4d6136c1a401c
4
+ data.tar.gz: c832d4f17a80904cc9b786043d8f56bd01c495aeb00fc98a5129bd4297c96eea
5
5
  SHA512:
6
- metadata.gz: 7cd2ebb04673c7c7d53263fc13d25704ed4ace69648089cee43e320e00b895549857f2a585326f2150f2454e5144d8c9596284289038a69ff0a7767d175c1608
7
- data.tar.gz: f5f8bcd366b34a1d375fe2dbe091e2e80202fb60af9ce06acb0eb0221c33700b0e09ac0dea84244b2b830542eb768320ceb188c1a68b0db4f35de93be63b48a0
6
+ metadata.gz: cbe54bdc037eccae528486bd8608ea265c16718b6644c522415245fed6b003e47cff209f21a2bdd152e2270c17ba978a2d9d5f0e8f11c6ac902b503e56cec1b6
7
+ data.tar.gz: 7c5ed7ae765769c16dfa9c59892520618bfbfc31e4142ad198d0988d21f834255d7c31f8f3b3d12ae5e80fe3d9707ca93981c24981ad01dc14231161b17089fa
data/CHANGELOG.md CHANGED
@@ -1,6 +1,26 @@
1
1
  Changelog
2
2
  =========
3
3
 
4
+ ## v6.26.2 (17 January 2024)
5
+
6
+ ### Fixes
7
+
8
+ * Fix unhandled `URI::InvalidURIError` in `Cleaner#clean_url`
9
+ | [#811](https://github.com/bugsnag/bugsnag-ruby/pull/811)
10
+
11
+ ## v6.26.1 (9 January 2024)
12
+
13
+ ### Fixes
14
+
15
+ * Fix deprecation warning from Sidekiq error handler
16
+ | [#796](https://github.com/bugsnag/bugsnag-ruby/pull/796)
17
+ | [fukayatsu](https://github.com/fukayatsu)
18
+ * Fix Resque integration when failure backend is already `Resque::Failure::Multiple`
19
+ | [#803](https://github.com/bugsnag/bugsnag-ruby/pull/803)
20
+ | [sj26](https://github.com/sj26)
21
+ * Redact URLs in automatic Rails breadcrumbs
22
+ | [#806](https://github.com/bugsnag/bugsnag-ruby/pull/806)
23
+
4
24
  ## v6.26.0 (19 July 2023)
5
25
 
6
26
  ### Enhancements
data/VERSION CHANGED
@@ -1 +1 @@
1
- 6.26.0
1
+ 6.26.2
data/bugsnag.gemspec CHANGED
@@ -30,7 +30,7 @@ Gem::Specification.new do |s|
30
30
 
31
31
  if s.respond_to?(:metadata=)
32
32
  s.metadata = {
33
- "changelog_uri" => "https://github.com/bugsnag/bugsnag-ruby/blob/HEAD/CHANGELOG.md",
33
+ "changelog_uri" => "https://github.com/bugsnag/bugsnag-ruby/blob/v#{File.read("VERSION").strip}/CHANGELOG.md",
34
34
  "documentation_uri" => "https://docs.bugsnag.com/platforms/ruby/",
35
35
  "source_code_uri" => "https://github.com/bugsnag/bugsnag-ruby/",
36
36
  "rubygems_mfa_required" => "true"
@@ -26,8 +26,16 @@ module Bugsnag
26
26
  # @return [String]
27
27
  def clean_url(url)
28
28
  return url if @configuration.meta_data_filters.empty? && @configuration.redacted_keys.empty?
29
+ return url unless url.include?('?')
30
+
31
+ begin
32
+ uri = URI(url)
33
+ rescue URI::InvalidURIError
34
+ pre_query_string, _query_string = url.split('?', 2)
35
+
36
+ return "#{pre_query_string}?#{FILTERED}"
37
+ end
29
38
 
30
- uri = URI(url)
31
39
  return url unless uri.query
32
40
 
33
41
  query_params = uri.query.split('&').map { |pair| pair.split('=') }
@@ -24,7 +24,8 @@ module Bugsnag
24
24
  filtered_data[:event_name] = event[:id]
25
25
  filtered_data[:event_id] = event_id
26
26
 
27
- if event[:id] == "sql.active_record"
27
+ case event[:id]
28
+ when "sql.active_record"
28
29
  if data.key?(:binds)
29
30
  binds = data[:binds].each_with_object({}) { |bind, output| output[bind.name] = '?' if defined?(bind.name) }
30
31
  filtered_data[:binds] = JSON.dump(binds) unless binds.empty?
@@ -36,6 +37,12 @@ module Bugsnag
36
37
  # the connection ID is the object_id of the connection object
37
38
  filtered_data[:connection_id] = data[:connection].object_id
38
39
  end
40
+
41
+ when "start_processing.action_controller"
42
+ filtered_data[:path] = Bugsnag.cleaner.clean_url(data[:path]) if data.key?(:path)
43
+
44
+ when "redirect_to.action_controller"
45
+ filtered_data[:location] = Bugsnag.cleaner.clean_url(data[:location]) if data.key?(:location)
39
46
  end
40
47
 
41
48
  Bugsnag.leave_breadcrumb(
@@ -21,7 +21,7 @@ module Bugsnag
21
21
  return if ::Resque::Failure.backend == self
22
22
 
23
23
  # Ensure resque is using a "Multiple" failure backend
24
- unless ::Resque::Failure.backend < ::Resque::Failure::Multiple
24
+ unless ::Resque::Failure.backend <= ::Resque::Failure::Multiple
25
25
  original_backend = ::Resque::Failure.backend
26
26
  ::Resque::Failure.backend = ::Resque::Failure::Multiple
27
27
  ::Resque::Failure.backend.classes ||= []
@@ -50,7 +50,7 @@ module Bugsnag
50
50
 
51
51
  def self.configure_server(server)
52
52
  if Bugsnag::Sidekiq.sidekiq_supports_error_handlers
53
- server.error_handlers << proc do |ex, _context|
53
+ server.error_handlers << proc do |ex, _context, _config = nil|
54
54
  Bugsnag::Sidekiq.notify(ex)
55
55
  Bugsnag.configuration.clear_request_data
56
56
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bugsnag
3
3
  version: !ruby/object:Gem::Version
4
- version: 6.26.0
4
+ version: 6.26.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - James Smith
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-07-19 00:00:00.000000000 Z
11
+ date: 2024-01-17 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: concurrent-ruby
@@ -107,7 +107,7 @@ homepage: https://github.com/bugsnag/bugsnag-ruby
107
107
  licenses:
108
108
  - MIT
109
109
  metadata:
110
- changelog_uri: https://github.com/bugsnag/bugsnag-ruby/blob/HEAD/CHANGELOG.md
110
+ changelog_uri: https://github.com/bugsnag/bugsnag-ruby/blob/v6.26.2/CHANGELOG.md
111
111
  documentation_uri: https://docs.bugsnag.com/platforms/ruby/
112
112
  source_code_uri: https://github.com/bugsnag/bugsnag-ruby/
113
113
  rubygems_mfa_required: 'true'