airbrake-ruby 2.8.0 → 2.8.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:  | 
| 4 | 
            -
              data.tar.gz:  | 
| 3 | 
            +
              metadata.gz: 50b058e4ca12d19c4301facc227f092f02f90e1c
         | 
| 4 | 
            +
              data.tar.gz: 390831b5b443b33bd620b7d3f3ac454062e56169
         | 
| 5 5 | 
             
            SHA512:
         | 
| 6 | 
            -
              metadata.gz:  | 
| 7 | 
            -
              data.tar.gz:  | 
| 6 | 
            +
              metadata.gz: 3d186ccb82d88d4f1bdb2b086ebf939467069c559a6123544cd5d288111bad9f5eddfb86c3eba2d2e347b066514399d462021234c227451803700a5db8213375
         | 
| 7 | 
            +
              data.tar.gz: f42b96961f9e0a05ceaea1d628b9cadf7fd544adaf73983e6c3337e861346439b7fe712a216f068bb700ed7afbb105779689c5970681f0680b5fa54938c4d344
         | 
| @@ -197,7 +197,7 @@ module Airbrake | |
| 197 197 | 
             
                      next(frame) if !config.code_hunks || frame[:file].nil?
         | 
| 198 198 |  | 
| 199 199 | 
             
                      if !root_directory.empty?
         | 
| 200 | 
            -
                        populate_code(config, frame) if  | 
| 200 | 
            +
                        populate_code(config, frame) if frame_in_root?(frame, root_directory)
         | 
| 201 201 | 
             
                      elsif i < CODE_FRAME_LIMIT
         | 
| 202 202 | 
             
                        populate_code(config, frame)
         | 
| 203 203 | 
             
                      end
         | 
| @@ -210,6 +210,10 @@ module Airbrake | |
| 210 210 | 
             
                    code = Airbrake::CodeHunk.new(config).get(frame[:file], frame[:line])
         | 
| 211 211 | 
             
                    frame[:code] = code if code
         | 
| 212 212 | 
             
                  end
         | 
| 213 | 
            +
             | 
| 214 | 
            +
                  def frame_in_root?(frame, root_directory)
         | 
| 215 | 
            +
                    frame[:file].start_with?(root_directory) && frame[:file] !~ %r{vendor/bundle}
         | 
| 216 | 
            +
                  end
         | 
| 213 217 | 
             
                end
         | 
| 214 218 | 
             
              end
         | 
| 215 219 | 
             
            end
         | 
    
        data/spec/backtrace_spec.rb
    CHANGED
    
    | @@ -320,6 +320,11 @@ RSpec.describe Airbrake::Backtrace do | |
| 320 320 | 
             
                          file: fixture_path('notroot.txt'),
         | 
| 321 321 | 
             
                          line: 3,
         | 
| 322 322 | 
             
                          function: 'pineapple'
         | 
| 323 | 
            +
                        },
         | 
| 324 | 
            +
                        {
         | 
| 325 | 
            +
                          file: project_root_path('vendor/bundle/ignored_file.rb'),
         | 
| 326 | 
            +
                          line: 2,
         | 
| 327 | 
            +
                          function: 'ignore_me'
         | 
| 323 328 | 
             
                        }
         | 
| 324 329 | 
             
                      ]
         | 
| 325 330 | 
             
                    end
         | 
| @@ -328,7 +333,8 @@ RSpec.describe Airbrake::Backtrace do | |
| 328 333 | 
             
                      ex = RuntimeError.new
         | 
| 329 334 | 
             
                      backtrace = [
         | 
| 330 335 | 
             
                        project_root_path('code.rb') + ":94:in `to_json'",
         | 
| 331 | 
            -
                        fixture_path('notroot.txt' + ":3:in `pineapple'")
         | 
| 336 | 
            +
                        fixture_path('notroot.txt' + ":3:in `pineapple'"),
         | 
| 337 | 
            +
                        project_root_path('vendor/bundle/ignored_file.rb') + ":2:in `ignore_me'"
         | 
| 332 338 | 
             
                      ]
         | 
| 333 339 | 
             
                      ex.set_backtrace(backtrace)
         | 
| 334 340 | 
             
                      expect(described_class.parse(config, ex)).to eq(parsed_backtrace)
         | 
    
        metadata
    CHANGED
    
    | @@ -1,14 +1,14 @@ | |
| 1 1 | 
             
            --- !ruby/object:Gem::Specification
         | 
| 2 2 | 
             
            name: airbrake-ruby
         | 
| 3 3 | 
             
            version: !ruby/object:Gem::Version
         | 
| 4 | 
            -
              version: 2.8. | 
| 4 | 
            +
              version: 2.8.1
         | 
| 5 5 | 
             
            platform: ruby
         | 
| 6 6 | 
             
            authors:
         | 
| 7 7 | 
             
            - Airbrake Technologies, Inc.
         | 
| 8 8 | 
             
            autorequire: 
         | 
| 9 9 | 
             
            bindir: bin
         | 
| 10 10 | 
             
            cert_chain: []
         | 
| 11 | 
            -
            date: 2018-01- | 
| 11 | 
            +
            date: 2018-01-31 00:00:00.000000000 Z
         | 
| 12 12 | 
             
            dependencies:
         | 
| 13 13 | 
             
            - !ruby/object:Gem::Dependency
         | 
| 14 14 | 
             
              name: rspec
         | 
| @@ -157,6 +157,7 @@ files: | |
| 157 157 | 
             
            - spec/fixtures/project_root/empty_file.rb
         | 
| 158 158 | 
             
            - spec/fixtures/project_root/long_line.txt
         | 
| 159 159 | 
             
            - spec/fixtures/project_root/short_file.rb
         | 
| 160 | 
            +
            - spec/fixtures/project_root/vendor/bundle/ignored_file.rb
         | 
| 160 161 | 
             
            - spec/helpers.rb
         | 
| 161 162 | 
             
            - spec/nested_exception_spec.rb
         | 
| 162 163 | 
             
            - spec/notice_spec.rb
         | 
| @@ -191,31 +192,32 @@ signing_key: | |
| 191 192 | 
             
            specification_version: 4
         | 
| 192 193 | 
             
            summary: Ruby notifier for https://airbrake.io
         | 
| 193 194 | 
             
            test_files:
         | 
| 194 | 
            -
            - spec/ | 
| 195 | 
            +
            - spec/truncator_spec.rb
         | 
| 196 | 
            +
            - spec/helpers.rb
         | 
| 197 | 
            +
            - spec/filters/root_directory_filter_spec.rb
         | 
| 198 | 
            +
            - spec/filters/keys_whitelist_spec.rb
         | 
| 199 | 
            +
            - spec/filters/system_exit_filter_spec.rb
         | 
| 200 | 
            +
            - spec/filters/thread_filter_spec.rb
         | 
| 201 | 
            +
            - spec/filters/keys_blacklist_spec.rb
         | 
| 202 | 
            +
            - spec/filters/gem_root_filter_spec.rb
         | 
| 203 | 
            +
            - spec/spec_helper.rb
         | 
| 204 | 
            +
            - spec/notice_spec.rb
         | 
| 205 | 
            +
            - spec/config_spec.rb
         | 
| 195 206 | 
             
            - spec/async_sender_spec.rb
         | 
| 196 207 | 
             
            - spec/backtrace_spec.rb
         | 
| 197 | 
            -
            - spec/ | 
| 208 | 
            +
            - spec/promise_spec.rb
         | 
| 198 209 | 
             
            - spec/config/validator_spec.rb
         | 
| 199 | 
            -
            - spec/ | 
| 200 | 
            -
            - spec/ | 
| 210 | 
            +
            - spec/sync_sender_spec.rb
         | 
| 211 | 
            +
            - spec/airbrake_spec.rb
         | 
| 212 | 
            +
            - spec/notifier_spec.rb
         | 
| 213 | 
            +
            - spec/nested_exception_spec.rb
         | 
| 201 214 | 
             
            - spec/filter_chain_spec.rb
         | 
| 202 | 
            -
            - spec/ | 
| 203 | 
            -
            - spec/ | 
| 204 | 
            -
            - spec/filters/keys_whitelist_spec.rb
         | 
| 205 | 
            -
            - spec/filters/root_directory_filter_spec.rb
         | 
| 206 | 
            -
            - spec/filters/system_exit_filter_spec.rb
         | 
| 207 | 
            -
            - spec/filters/thread_filter_spec.rb
         | 
| 215 | 
            +
            - spec/file_cache.rb
         | 
| 216 | 
            +
            - spec/code_hunk_spec.rb
         | 
| 208 217 | 
             
            - spec/fixtures/notroot.txt
         | 
| 209 | 
            -
            - spec/fixtures/project_root/code.rb
         | 
| 210 | 
            -
            - spec/fixtures/project_root/empty_file.rb
         | 
| 211 218 | 
             
            - spec/fixtures/project_root/long_line.txt
         | 
| 219 | 
            +
            - spec/fixtures/project_root/empty_file.rb
         | 
| 220 | 
            +
            - spec/fixtures/project_root/code.rb
         | 
| 212 221 | 
             
            - spec/fixtures/project_root/short_file.rb
         | 
| 213 | 
            -
            - spec/ | 
| 214 | 
            -
            - spec/nested_exception_spec.rb
         | 
| 215 | 
            -
            - spec/notice_spec.rb
         | 
| 222 | 
            +
            - spec/fixtures/project_root/vendor/bundle/ignored_file.rb
         | 
| 216 223 | 
             
            - spec/notifier_spec/options_spec.rb
         | 
| 217 | 
            -
            - spec/notifier_spec.rb
         | 
| 218 | 
            -
            - spec/promise_spec.rb
         | 
| 219 | 
            -
            - spec/spec_helper.rb
         | 
| 220 | 
            -
            - spec/sync_sender_spec.rb
         | 
| 221 | 
            -
            - spec/truncator_spec.rb
         |