yeller_ruby 0.5.0 → 0.6.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/yeller.rb +0 -1
- data/lib/yeller/exception_formatter.rb +14 -7
- data/lib/yeller/version.rb +1 -1
- metadata +2 -16
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 036bd0f49c25b2ce2ec5c0ba0d7575b0909ed702
|
4
|
+
data.tar.gz: 7d13a62dd31ae978e9d6717c592e6f2edd27af01
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f1d15bdb3cbb743308db0f03fe894dd3a46ca9b318e948b0d14f5d8c56ae769b179ab7695000c891faa810995352667cef4b9d17c3a4bb6108fe81662498a1d5
|
7
|
+
data.tar.gz: 188d95154fe286931484da8982b0ce29d3c99b8328fbec6cebffbe9ed337fe519a391c18cc857ea1545deea4ba140322463310d0c62ce82f87df02fe831c9aa6
|
data/lib/yeller.rb
CHANGED
@@ -1,3 +1,4 @@
|
|
1
|
+
require 'set'
|
1
2
|
module Yeller
|
2
3
|
class ExceptionFormatter
|
3
4
|
BACKTRACE_FORMAT = %r{^((?:[a-zA-Z]:)?[^:]+):(\d+)(?::in `([^']+)')?$}.freeze
|
@@ -16,16 +17,22 @@ module Yeller
|
|
16
17
|
end
|
17
18
|
|
18
19
|
def self.process_causes(exception)
|
19
|
-
unwrap_causes(exception
|
20
|
+
unwrap_causes(exception)
|
20
21
|
end
|
21
22
|
|
22
|
-
def self.unwrap_causes(exception
|
23
|
-
causes
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
23
|
+
def self.unwrap_causes(exception)
|
24
|
+
causes = [exception]
|
25
|
+
previously_seen = Set.new([exception.object_id])
|
26
|
+
while exception.respond_to?(:cause) && exception.cause
|
27
|
+
cause = exception.cause
|
28
|
+
if previously_seen.include?(cause.object_id)
|
29
|
+
break
|
30
|
+
end
|
31
|
+
causes << cause
|
32
|
+
previously_seen << cause.object_id
|
33
|
+
exception = cause
|
28
34
|
end
|
35
|
+
causes.reverse!
|
29
36
|
end
|
30
37
|
|
31
38
|
attr_reader :type, :options, :backtrace_filter
|
data/lib/yeller/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: yeller_ruby
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.6.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tom Crayford
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2016-03-18 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -38,20 +38,6 @@ dependencies:
|
|
38
38
|
- - ">="
|
39
39
|
- !ruby/object:Gem::Version
|
40
40
|
version: '0'
|
41
|
-
- !ruby/object:Gem::Dependency
|
42
|
-
name: yajl-ruby
|
43
|
-
requirement: !ruby/object:Gem::Requirement
|
44
|
-
requirements:
|
45
|
-
- - "~>"
|
46
|
-
- !ruby/object:Gem::Version
|
47
|
-
version: 1.2.0
|
48
|
-
type: :runtime
|
49
|
-
prerelease: false
|
50
|
-
version_requirements: !ruby/object:Gem::Requirement
|
51
|
-
requirements:
|
52
|
-
- - "~>"
|
53
|
-
- !ruby/object:Gem::Version
|
54
|
-
version: 1.2.0
|
55
41
|
description: A Ruby/Rack/Rails client for yellerapp.com
|
56
42
|
email:
|
57
43
|
- tcrayford@googlemail.com
|