better_errors 2.0.0 → 2.8.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/.coveralls.yml +1 -0
- data/.gitignore +3 -0
- data/.travis.yml +96 -2
- data/CHANGELOG.md +1 -1
- data/Gemfile +2 -7
- data/LICENSE.txt +1 -1
- data/README.md +99 -39
- data/better_errors.gemspec +23 -4
- data/gemfiles/pry010.gemfile +9 -0
- data/gemfiles/pry011.gemfile +8 -0
- data/gemfiles/pry09.gemfile +8 -0
- data/gemfiles/rack.gemfile +7 -0
- data/gemfiles/rack_boc.gemfile +8 -0
- data/gemfiles/rails42.gemfile +9 -0
- data/gemfiles/rails42_boc.gemfile +10 -0
- data/gemfiles/rails42_haml.gemfile +10 -0
- data/gemfiles/rails50.gemfile +8 -0
- data/gemfiles/rails50_boc.gemfile +9 -0
- data/gemfiles/rails50_haml.gemfile +9 -0
- data/gemfiles/rails51.gemfile +8 -0
- data/gemfiles/rails51_boc.gemfile +9 -0
- data/gemfiles/rails51_haml.gemfile +9 -0
- data/gemfiles/rails52.gemfile +8 -0
- data/gemfiles/rails52_boc.gemfile +9 -0
- data/gemfiles/rails52_haml.gemfile +9 -0
- data/gemfiles/rails60.gemfile +7 -0
- data/gemfiles/rails60_boc.gemfile +8 -0
- data/gemfiles/rails60_haml.gemfile +8 -0
- data/lib/better_errors/code_formatter/html.rb +1 -1
- data/lib/better_errors/code_formatter.rb +7 -7
- data/lib/better_errors/error_page.rb +56 -15
- data/lib/better_errors/inspectable_value.rb +45 -0
- data/lib/better_errors/middleware.rb +96 -16
- data/lib/better_errors/raised_exception.rb +13 -3
- data/lib/better_errors/repl/basic.rb +3 -3
- data/lib/better_errors/repl/pry.rb +18 -8
- data/lib/better_errors/repl.rb +6 -4
- data/lib/better_errors/stack_frame.rb +33 -8
- data/lib/better_errors/templates/main.erb +71 -34
- data/lib/better_errors/templates/text.erb +2 -2
- data/lib/better_errors/templates/variable_info.erb +32 -23
- data/lib/better_errors/version.rb +1 -1
- data/lib/better_errors.rb +21 -3
- metadata +118 -35
- data/Rakefile +0 -13
- data/spec/better_errors/code_formatter_spec.rb +0 -92
- data/spec/better_errors/error_page_spec.rb +0 -76
- data/spec/better_errors/middleware_spec.rb +0 -154
- data/spec/better_errors/raised_exception_spec.rb +0 -52
- data/spec/better_errors/repl/basic_spec.rb +0 -18
- data/spec/better_errors/repl/pry_spec.rb +0 -40
- data/spec/better_errors/repl/shared_examples.rb +0 -18
- data/spec/better_errors/stack_frame_spec.rb +0 -157
- data/spec/better_errors/support/my_source.rb +0 -20
- data/spec/better_errors_spec.rb +0 -73
- data/spec/spec_helper.rb +0 -5
- data/spec/without_binding_of_caller.rb +0 -9
@@ -1,7 +1,7 @@
|
|
1
1
|
<!DOCTYPE html>
|
2
2
|
<html>
|
3
3
|
<head>
|
4
|
-
<title><%=
|
4
|
+
<title><%= exception_type %> at <%= request_path %></title>
|
5
5
|
</head>
|
6
6
|
<body>
|
7
7
|
<%# Stylesheets are placed in the <body> for Turbolinks compatibility. %>
|
@@ -146,6 +146,14 @@
|
|
146
146
|
}
|
147
147
|
|
148
148
|
/* Heading */
|
149
|
+
header.exception .fix-actions {
|
150
|
+
margin-top: .5em;
|
151
|
+
}
|
152
|
+
|
153
|
+
header.exception .fix-actions input[type=submit] {
|
154
|
+
font-weight: bold;
|
155
|
+
}
|
156
|
+
|
149
157
|
header.exception h2 {
|
150
158
|
font-weight: 200;
|
151
159
|
font-size: 11pt;
|
@@ -153,7 +161,7 @@
|
|
153
161
|
|
154
162
|
header.exception h2,
|
155
163
|
header.exception p {
|
156
|
-
line-height: 1.
|
164
|
+
line-height: 1.5em;
|
157
165
|
overflow: hidden;
|
158
166
|
white-space: pre;
|
159
167
|
text-overflow: ellipsis;
|
@@ -166,7 +174,7 @@
|
|
166
174
|
|
167
175
|
header.exception p {
|
168
176
|
font-weight: 200;
|
169
|
-
font-size:
|
177
|
+
font-size: 17pt;
|
170
178
|
color: white;
|
171
179
|
}
|
172
180
|
|
@@ -182,7 +190,7 @@
|
|
182
190
|
word-wrap: break-word;
|
183
191
|
white-space: pre-wrap;
|
184
192
|
height: auto;
|
185
|
-
max-height:
|
193
|
+
max-height: 7.5em;
|
186
194
|
}
|
187
195
|
|
188
196
|
@media screen and (max-width: 1100px) {
|
@@ -394,7 +402,7 @@
|
|
394
402
|
* Monospace
|
395
403
|
* --------------------------------------------------------------------- */
|
396
404
|
|
397
|
-
pre, code, .repl input, .repl .
|
405
|
+
pre, code, .be-repl input, .be-repl .command-line span, textarea, .code_linenums {
|
398
406
|
font-family: menlo, lucida console, monospace;
|
399
407
|
font-size: 8pt;
|
400
408
|
}
|
@@ -460,7 +468,7 @@
|
|
460
468
|
font-weight: 200;
|
461
469
|
}
|
462
470
|
|
463
|
-
.code, .console, .unavailable {
|
471
|
+
.code, .be-console, .unavailable {
|
464
472
|
background: #fff;
|
465
473
|
padding: 5px;
|
466
474
|
|
@@ -532,13 +540,13 @@
|
|
532
540
|
}
|
533
541
|
|
534
542
|
/* REPL shell */
|
535
|
-
.console {
|
543
|
+
.be-console {
|
536
544
|
padding: 0 1px 10px 1px;
|
537
545
|
border-bottom-left-radius: 2px;
|
538
546
|
border-bottom-right-radius: 2px;
|
539
547
|
}
|
540
548
|
|
541
|
-
.console pre {
|
549
|
+
.be-console pre {
|
542
550
|
padding: 10px 10px 0 10px;
|
543
551
|
max-height: 400px;
|
544
552
|
overflow-x: none;
|
@@ -548,30 +556,31 @@
|
|
548
556
|
white-space: pre-wrap;
|
549
557
|
}
|
550
558
|
|
551
|
-
/* .
|
552
|
-
.console .
|
559
|
+
/* .command-line > span + input */
|
560
|
+
.be-console .command-line {
|
553
561
|
display: table;
|
554
562
|
width: 100%;
|
555
563
|
}
|
556
564
|
|
557
|
-
.console .
|
558
|
-
.console .
|
565
|
+
.be-console .command-line span,
|
566
|
+
.be-console .command-line input {
|
559
567
|
display: table-cell;
|
560
568
|
}
|
561
569
|
|
562
|
-
.console .
|
570
|
+
.be-console .command-line span {
|
563
571
|
width: 1%;
|
564
572
|
padding-right: 5px;
|
565
573
|
padding-left: 10px;
|
574
|
+
white-space: pre;
|
566
575
|
}
|
567
576
|
|
568
|
-
.console .
|
577
|
+
.be-console .command-line input {
|
569
578
|
width: 99%;
|
570
579
|
}
|
571
580
|
|
572
581
|
/* Input box */
|
573
|
-
.console input,
|
574
|
-
.console input:focus {
|
582
|
+
.be-console input,
|
583
|
+
.be-console input:focus {
|
575
584
|
outline: 0;
|
576
585
|
border: 0;
|
577
586
|
padding: 0;
|
@@ -669,14 +678,14 @@
|
|
669
678
|
|
670
679
|
nav.sidebar::-webkit-scrollbar,
|
671
680
|
.inset pre::-webkit-scrollbar,
|
672
|
-
.console pre::-webkit-scrollbar,
|
681
|
+
.be-console pre::-webkit-scrollbar,
|
673
682
|
.code::-webkit-scrollbar {
|
674
683
|
width: 10px;
|
675
684
|
height: 10px;
|
676
685
|
}
|
677
686
|
|
678
687
|
.inset pre::-webkit-scrollbar-thumb,
|
679
|
-
.console pre::-webkit-scrollbar-thumb,
|
688
|
+
.be-console pre::-webkit-scrollbar-thumb,
|
680
689
|
.code::-webkit-scrollbar-thumb {
|
681
690
|
background: #ccc;
|
682
691
|
border-radius: 5px;
|
@@ -692,7 +701,7 @@
|
|
692
701
|
background: -webkit-linear-gradient(left, #aaa, #999);
|
693
702
|
}
|
694
703
|
|
695
|
-
.console pre:hover::-webkit-scrollbar-thumb,
|
704
|
+
.be-console pre:hover::-webkit-scrollbar-thumb,
|
696
705
|
.inset pre:hover::-webkit-scrollbar-thumb,
|
697
706
|
.code:hover::-webkit-scrollbar-thumb {
|
698
707
|
background: #888;
|
@@ -720,19 +729,41 @@
|
|
720
729
|
if(document.styleSheets[i].href)
|
721
730
|
document.styleSheets[i].disabled = true;
|
722
731
|
}
|
723
|
-
|
724
|
-
|
725
|
-
|
726
|
-
|
727
|
-
|
728
|
-
|
732
|
+
if (window.Turbolinks.controller) {
|
733
|
+
// Turbolinks > 5 (see https://github.com/turbolinks/turbolinks/issues/6)
|
734
|
+
document.addEventListener("turbolinks:load", function restoreCSS(e) {
|
735
|
+
for(var i=0; i < document.styleSheets.length; i++) {
|
736
|
+
document.styleSheets[i].disabled = false;
|
737
|
+
}
|
738
|
+
document.removeEventListener("turbolinks:load", restoreCSS, false);
|
739
|
+
});
|
740
|
+
} else {
|
741
|
+
document.addEventListener("page:restore", function restoreCSS(e) {
|
742
|
+
for(var i=0; i < document.styleSheets.length; i++) {
|
743
|
+
document.styleSheets[i].disabled = false;
|
744
|
+
}
|
745
|
+
document.removeEventListener("page:restore", restoreCSS, false);
|
746
|
+
});
|
747
|
+
}
|
729
748
|
}
|
730
749
|
</script>
|
731
750
|
|
732
751
|
<div class='top'>
|
733
752
|
<header class="exception">
|
734
|
-
<h2><strong><%=
|
735
|
-
<p><%=
|
753
|
+
<h2><strong><%= exception_type %></strong> <span>at <%= request_path %></span></h2>
|
754
|
+
<p><%= exception_message %></p>
|
755
|
+
<% unless active_support_actions.empty? %>
|
756
|
+
<div class='fix-actions'>
|
757
|
+
<% active_support_actions.each do |action, _| %>
|
758
|
+
<form class="button_to" method="post" action="<%= action_dispatch_action_endpoint %>">
|
759
|
+
<input type="submit" value="<%= action %>">
|
760
|
+
<input type="hidden" name="action" value="<%= action %>">
|
761
|
+
<input type="hidden" name="error" value="<%= exception_type %>">
|
762
|
+
<input type="hidden" name="location" value="<%= request_path %>">
|
763
|
+
</form>
|
764
|
+
<% end %>
|
765
|
+
</div>
|
766
|
+
<% end %>
|
736
767
|
</header>
|
737
768
|
</div>
|
738
769
|
|
@@ -769,6 +800,7 @@
|
|
769
800
|
(function() {
|
770
801
|
|
771
802
|
var OID = "<%= id %>";
|
803
|
+
var csrfToken = "<%= csrf_token %>";
|
772
804
|
|
773
805
|
var previousFrame = null;
|
774
806
|
var previousFrameInfo = null;
|
@@ -777,8 +809,9 @@
|
|
777
809
|
|
778
810
|
function apiCall(method, opts, cb) {
|
779
811
|
var req = new XMLHttpRequest();
|
780
|
-
req.open("POST", <%== uri_prefix.gsub("<", "<").inspect %> + "/__better_errors/" + OID + "/" + method, true);
|
812
|
+
req.open("POST", "//" + window.location.host + <%== uri_prefix.gsub("<", "<").inspect %> + "/__better_errors/" + OID + "/" + method, true);
|
781
813
|
req.setRequestHeader("Content-Type", "application/json");
|
814
|
+
opts.csrfToken = csrfToken;
|
782
815
|
req.send(JSON.stringify(opts));
|
783
816
|
req.onreadystatechange = function() {
|
784
817
|
if(req.readyState == 4) {
|
@@ -809,7 +842,7 @@
|
|
809
842
|
REPL.prototype.install = function(containerElement) {
|
810
843
|
this.container = containerElement;
|
811
844
|
|
812
|
-
this.promptElement = this.container.querySelector(".prompt
|
845
|
+
this.promptElement = this.container.querySelector(".command-line .prompt");
|
813
846
|
this.inputElement = this.container.querySelector("input");
|
814
847
|
this.outputElement = this.container.querySelector("pre");
|
815
848
|
|
@@ -875,6 +908,7 @@
|
|
875
908
|
this.previousCommandOffset = previousCommands.push(text);
|
876
909
|
if(previousCommands.length > 100) {
|
877
910
|
previousCommands.splice(0, 1);
|
911
|
+
this.previousCommandOffset -= 1;
|
878
912
|
}
|
879
913
|
localStorage.setItem("better_errors_previous_commands", JSON.stringify(previousCommands));
|
880
914
|
}
|
@@ -923,7 +957,7 @@
|
|
923
957
|
|
924
958
|
el.style.display = "block";
|
925
959
|
|
926
|
-
var replInput = el.querySelector('.console input');
|
960
|
+
var replInput = el.querySelector('.be-console input');
|
927
961
|
if (replInput) replInput.focus();
|
928
962
|
}
|
929
963
|
|
@@ -937,17 +971,20 @@
|
|
937
971
|
apiCall("variables", { "index": index }, function(response) {
|
938
972
|
el.loaded = true;
|
939
973
|
if(response.error) {
|
940
|
-
el.innerHTML = "<
|
974
|
+
el.innerHTML = "<h2 class='error'>" + escapeHTML(response.error) + "</h2>";
|
975
|
+
if(response.explanation) {
|
976
|
+
el.innerHTML += "<p class='explanation'>" + escapeHTML(response.explanation) + "</p>";
|
977
|
+
}
|
978
|
+
el.innerHTML += "<p><a target='_new' href='https://github.com/BetterErrors/better_errors'>More about Better Errors</a></p>";
|
941
979
|
} else {
|
942
980
|
el.innerHTML = response.html;
|
943
981
|
|
944
|
-
var repl = el.querySelector(".repl .console");
|
982
|
+
var repl = el.querySelector(".be-repl .be-console");
|
945
983
|
if(repl) {
|
946
984
|
new REPL(index).install(repl);
|
947
985
|
}
|
948
|
-
|
949
|
-
switchTo(el);
|
950
986
|
}
|
987
|
+
switchTo(el);
|
951
988
|
});
|
952
989
|
}
|
953
990
|
}
|
@@ -1,6 +1,6 @@
|
|
1
|
-
<%== text_heading("=", "%s at %s" % [
|
1
|
+
<%== text_heading("=", "%s at %s" % [exception_type, request_path]) %>
|
2
2
|
|
3
|
-
> <%==
|
3
|
+
> <%== exception_message %>
|
4
4
|
<% if backtrace_frames.any? %>
|
5
5
|
|
6
6
|
<%== text_heading("-", "%s, line %i" % [first_frame.pretty_path, first_frame.line]) %>
|
@@ -1,17 +1,24 @@
|
|
1
1
|
<header class="trace_info clearfix">
|
2
2
|
<div class="title">
|
3
3
|
<h2 class="name"><%= @frame.name %></h2>
|
4
|
-
<div class="location"
|
4
|
+
<div class="location">
|
5
|
+
<span class="filename">
|
6
|
+
<a
|
7
|
+
href="<%= editor_url(@frame) %>"
|
8
|
+
<%= ENV.key?('BETTER_ERRORS_INSIDE_FRAME') ? "target=_blank" : '' %>
|
9
|
+
><%= @frame.pretty_path %></a>
|
10
|
+
</span>
|
11
|
+
</div>
|
5
12
|
</div>
|
6
13
|
<div class="code_block clearfix">
|
7
14
|
<%== html_formatted_code_block @frame %>
|
8
15
|
</div>
|
9
16
|
|
10
17
|
<% if BetterErrors.binding_of_caller_available? && @frame.frame_binding %>
|
11
|
-
<div class="repl">
|
12
|
-
<div class="console">
|
18
|
+
<div class="be-repl">
|
19
|
+
<div class="be-console">
|
13
20
|
<pre></pre>
|
14
|
-
<div class="
|
21
|
+
<div class="command-line"><span class='prompt'>>></span> <input tabindex="1"/></div>
|
15
22
|
</div>
|
16
23
|
</div>
|
17
24
|
<% end %>
|
@@ -45,26 +52,28 @@
|
|
45
52
|
</div>
|
46
53
|
</div>
|
47
54
|
|
48
|
-
|
49
|
-
<
|
50
|
-
|
51
|
-
<
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
55
|
+
<% if BetterErrors.binding_of_caller_available? && @frame.frame_binding %>
|
56
|
+
<div class="sub">
|
57
|
+
<h3>Local Variables</h3>
|
58
|
+
<div class='inset variables'>
|
59
|
+
<table class="var_table">
|
60
|
+
<% @frame.local_variables.each do |name, value| %>
|
61
|
+
<tr><td class="name"><%= name %></td><td><pre><%== inspect_value value %></pre></td></tr>
|
62
|
+
<% end %>
|
63
|
+
</table>
|
64
|
+
</div>
|
56
65
|
</div>
|
57
|
-
</div>
|
58
66
|
|
59
|
-
<div class="sub">
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
+
<div class="sub">
|
68
|
+
<h3>Instance Variables</h3>
|
69
|
+
<div class="inset variables">
|
70
|
+
<table class="var_table">
|
71
|
+
<% @frame.instance_variables.each do |name, value| %>
|
72
|
+
<tr><td class="name"><%= name %></td><td><pre><%== inspect_value value %></pre></td></tr>
|
73
|
+
<% end %>
|
74
|
+
</table>
|
75
|
+
</div>
|
67
76
|
</div>
|
68
|
-
</div>
|
69
77
|
|
70
|
-
<!-- <%= Time.now.to_f - @var_start_time %> seconds -->
|
78
|
+
<!-- <%= Time.now.to_f - @var_start_time %> seconds -->
|
79
|
+
<% end %>
|
data/lib/better_errors.rb
CHANGED
@@ -1,9 +1,10 @@
|
|
1
1
|
require "pp"
|
2
|
-
require "
|
2
|
+
require "erubi"
|
3
3
|
require "coderay"
|
4
4
|
require "uri"
|
5
5
|
|
6
6
|
require "better_errors/code_formatter"
|
7
|
+
require "better_errors/inspectable_value"
|
7
8
|
require "better_errors/error_page"
|
8
9
|
require "better_errors/middleware"
|
9
10
|
require "better_errors/raised_exception"
|
@@ -17,6 +18,11 @@ module BetterErrors
|
|
17
18
|
{ symbols: [:macvim, :mvim], sniff: /vim/i, url: proc { |file, line| "mvim://open?url=file://#{file}&line=#{line}" } },
|
18
19
|
{ symbols: [:sublime, :subl, :st], sniff: /subl/i, url: "subl://open?url=file://%{file}&line=%{line}" },
|
19
20
|
{ symbols: [:textmate, :txmt, :tm], sniff: /mate/i, url: "txmt://open?url=file://%{file}&line=%{line}" },
|
21
|
+
{ symbols: [:idea], sniff: /idea/i, url: "idea://open?file=%{file}&line=%{line}" },
|
22
|
+
{ symbols: [:rubymine], sniff: /mine/i, url: "x-mine://open?file=%{file}&line=%{line}" },
|
23
|
+
{ symbols: [:vscode, :code], sniff: /code/i, url: "vscode://file/%{file}:%{line}" },
|
24
|
+
{ symbols: [:vscodium, :codium], sniff: /codium/i, url: "vscodium://file/%{file}:%{line}" },
|
25
|
+
{ symbols: [:atom], sniff: /atom/i, url: "atom://core/open/file?filename=%{file}&line=%{line}" },
|
20
26
|
]
|
21
27
|
|
22
28
|
class << self
|
@@ -44,8 +50,19 @@ module BetterErrors
|
|
44
50
|
# The ignored instance variables.
|
45
51
|
# @return [Array]
|
46
52
|
attr_accessor :ignored_instance_variables
|
53
|
+
|
54
|
+
# The maximum variable payload size. If variable.inspect exceeds this,
|
55
|
+
# the variable won't be returned.
|
56
|
+
# @return int
|
57
|
+
attr_accessor :maximum_variable_inspect_size
|
58
|
+
|
59
|
+
# List of classes that are excluded from inspection.
|
60
|
+
# @return [Array]
|
61
|
+
attr_accessor :ignored_classes
|
47
62
|
end
|
48
63
|
@ignored_instance_variables = []
|
64
|
+
@maximum_variable_inspect_size = 100_000
|
65
|
+
@ignored_classes = ['ActionDispatch::Request', 'ActionDispatch::Response']
|
49
66
|
|
50
67
|
# Returns a proc, which when called with a filename and line number argument,
|
51
68
|
# returns a URL to open the filename and line in the selected editor.
|
@@ -68,6 +85,7 @@ module BetterErrors
|
|
68
85
|
# * `:textmate`, `:txmt`, `:tm`
|
69
86
|
# * `:sublime`, `:subl`, `:st`
|
70
87
|
# * `:macvim`
|
88
|
+
# * `:atom`
|
71
89
|
#
|
72
90
|
# @param [Symbol] sym
|
73
91
|
#
|
@@ -117,7 +135,7 @@ module BetterErrors
|
|
117
135
|
# Enables experimental Pry support in the inline REPL
|
118
136
|
#
|
119
137
|
# If you encounter problems while using Pry, *please* file a bug report at
|
120
|
-
# https://github.com/
|
138
|
+
# https://github.com/BetterErrors/better_errors/issues
|
121
139
|
def self.use_pry!
|
122
140
|
REPL::PROVIDERS.unshift const: :Pry, impl: "better_errors/repl/pry"
|
123
141
|
end
|
@@ -139,7 +157,7 @@ begin
|
|
139
157
|
require "binding_of_caller"
|
140
158
|
require "better_errors/exception_extension"
|
141
159
|
BetterErrors.binding_of_caller_available = true
|
142
|
-
rescue LoadError
|
160
|
+
rescue LoadError
|
143
161
|
BetterErrors.binding_of_caller_available = false
|
144
162
|
end
|
145
163
|
|
metadata
CHANGED
@@ -1,29 +1,113 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: better_errors
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.
|
4
|
+
version: 2.8.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Charlie Somerville
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2020-09-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
|
-
name:
|
14
|
+
name: rake
|
15
|
+
requirement: !ruby/object:Gem::Requirement
|
16
|
+
requirements:
|
17
|
+
- - "~>"
|
18
|
+
- !ruby/object:Gem::Version
|
19
|
+
version: '10.0'
|
20
|
+
type: :development
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - "~>"
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '10.0'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: rspec
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '3.5'
|
34
|
+
type: :development
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '3.5'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: rspec-html-matchers
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - ">="
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: '0'
|
48
|
+
type: :development
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - ">="
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: '0'
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: rspec-its
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - ">="
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0'
|
62
|
+
type: :development
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - ">="
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '0'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: yard
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - ">="
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: '0'
|
76
|
+
type: :development
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - ">="
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: '0'
|
83
|
+
- !ruby/object:Gem::Dependency
|
84
|
+
name: kramdown
|
85
|
+
requirement: !ruby/object:Gem::Requirement
|
86
|
+
requirements:
|
87
|
+
- - ">"
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
version: 2.0.0
|
90
|
+
type: :development
|
91
|
+
prerelease: false
|
92
|
+
version_requirements: !ruby/object:Gem::Requirement
|
93
|
+
requirements:
|
94
|
+
- - ">"
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: 2.0.0
|
97
|
+
- !ruby/object:Gem::Dependency
|
98
|
+
name: erubi
|
15
99
|
requirement: !ruby/object:Gem::Requirement
|
16
100
|
requirements:
|
17
101
|
- - ">="
|
18
102
|
- !ruby/object:Gem::Version
|
19
|
-
version:
|
103
|
+
version: 1.0.0
|
20
104
|
type: :runtime
|
21
105
|
prerelease: false
|
22
106
|
version_requirements: !ruby/object:Gem::Requirement
|
23
107
|
requirements:
|
24
108
|
- - ">="
|
25
109
|
- !ruby/object:Gem::Version
|
26
|
-
version:
|
110
|
+
version: 1.0.0
|
27
111
|
- !ruby/object:Gem::Dependency
|
28
112
|
name: coderay
|
29
113
|
requirement: !ruby/object:Gem::Requirement
|
@@ -61,6 +145,7 @@ executables: []
|
|
61
145
|
extensions: []
|
62
146
|
extra_rdoc_files: []
|
63
147
|
files:
|
148
|
+
- ".coveralls.yml"
|
64
149
|
- ".gitignore"
|
65
150
|
- ".travis.yml"
|
66
151
|
- ".yardopts"
|
@@ -68,14 +153,34 @@ files:
|
|
68
153
|
- Gemfile
|
69
154
|
- LICENSE.txt
|
70
155
|
- README.md
|
71
|
-
- Rakefile
|
72
156
|
- better_errors.gemspec
|
157
|
+
- gemfiles/pry010.gemfile
|
158
|
+
- gemfiles/pry011.gemfile
|
159
|
+
- gemfiles/pry09.gemfile
|
160
|
+
- gemfiles/rack.gemfile
|
161
|
+
- gemfiles/rack_boc.gemfile
|
162
|
+
- gemfiles/rails42.gemfile
|
163
|
+
- gemfiles/rails42_boc.gemfile
|
164
|
+
- gemfiles/rails42_haml.gemfile
|
165
|
+
- gemfiles/rails50.gemfile
|
166
|
+
- gemfiles/rails50_boc.gemfile
|
167
|
+
- gemfiles/rails50_haml.gemfile
|
168
|
+
- gemfiles/rails51.gemfile
|
169
|
+
- gemfiles/rails51_boc.gemfile
|
170
|
+
- gemfiles/rails51_haml.gemfile
|
171
|
+
- gemfiles/rails52.gemfile
|
172
|
+
- gemfiles/rails52_boc.gemfile
|
173
|
+
- gemfiles/rails52_haml.gemfile
|
174
|
+
- gemfiles/rails60.gemfile
|
175
|
+
- gemfiles/rails60_boc.gemfile
|
176
|
+
- gemfiles/rails60_haml.gemfile
|
73
177
|
- lib/better_errors.rb
|
74
178
|
- lib/better_errors/code_formatter.rb
|
75
179
|
- lib/better_errors/code_formatter/html.rb
|
76
180
|
- lib/better_errors/code_formatter/text.rb
|
77
181
|
- lib/better_errors/error_page.rb
|
78
182
|
- lib/better_errors/exception_extension.rb
|
183
|
+
- lib/better_errors/inspectable_value.rb
|
79
184
|
- lib/better_errors/middleware.rb
|
80
185
|
- lib/better_errors/rails.rb
|
81
186
|
- lib/better_errors/raised_exception.rb
|
@@ -87,22 +192,13 @@ files:
|
|
87
192
|
- lib/better_errors/templates/text.erb
|
88
193
|
- lib/better_errors/templates/variable_info.erb
|
89
194
|
- lib/better_errors/version.rb
|
90
|
-
|
91
|
-
- spec/better_errors/error_page_spec.rb
|
92
|
-
- spec/better_errors/middleware_spec.rb
|
93
|
-
- spec/better_errors/raised_exception_spec.rb
|
94
|
-
- spec/better_errors/repl/basic_spec.rb
|
95
|
-
- spec/better_errors/repl/pry_spec.rb
|
96
|
-
- spec/better_errors/repl/shared_examples.rb
|
97
|
-
- spec/better_errors/stack_frame_spec.rb
|
98
|
-
- spec/better_errors/support/my_source.rb
|
99
|
-
- spec/better_errors_spec.rb
|
100
|
-
- spec/spec_helper.rb
|
101
|
-
- spec/without_binding_of_caller.rb
|
102
|
-
homepage: https://github.com/charliesome/better_errors
|
195
|
+
homepage: https://github.com/BetterErrors/better_errors
|
103
196
|
licenses:
|
104
197
|
- MIT
|
105
|
-
metadata:
|
198
|
+
metadata:
|
199
|
+
changelog_uri: https://github.com/BetterErrors/better_errors/releases
|
200
|
+
source_code_uri: https://github.com/BetterErrors/better_errors
|
201
|
+
bug_tracker_uri: https://github.com/BetterErrors/better_errors/issues
|
106
202
|
post_install_message:
|
107
203
|
rdoc_options: []
|
108
204
|
require_paths:
|
@@ -118,21 +214,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
118
214
|
- !ruby/object:Gem::Version
|
119
215
|
version: '0'
|
120
216
|
requirements: []
|
121
|
-
|
122
|
-
rubygems_version: 2.2.2
|
217
|
+
rubygems_version: 3.1.2
|
123
218
|
signing_key:
|
124
219
|
specification_version: 4
|
125
220
|
summary: Better error page for Rails and other Rack apps
|
126
|
-
test_files:
|
127
|
-
- spec/better_errors/code_formatter_spec.rb
|
128
|
-
- spec/better_errors/error_page_spec.rb
|
129
|
-
- spec/better_errors/middleware_spec.rb
|
130
|
-
- spec/better_errors/raised_exception_spec.rb
|
131
|
-
- spec/better_errors/repl/basic_spec.rb
|
132
|
-
- spec/better_errors/repl/pry_spec.rb
|
133
|
-
- spec/better_errors/repl/shared_examples.rb
|
134
|
-
- spec/better_errors/stack_frame_spec.rb
|
135
|
-
- spec/better_errors/support/my_source.rb
|
136
|
-
- spec/better_errors_spec.rb
|
137
|
-
- spec/spec_helper.rb
|
138
|
-
- spec/without_binding_of_caller.rb
|
221
|
+
test_files: []
|
data/Rakefile
DELETED
@@ -1,13 +0,0 @@
|
|
1
|
-
require "bundler/gem_tasks"
|
2
|
-
require "rspec/core/rake_task"
|
3
|
-
|
4
|
-
namespace :test do
|
5
|
-
RSpec::Core::RakeTask.new(:with_binding_of_caller)
|
6
|
-
|
7
|
-
without_task = RSpec::Core::RakeTask.new(:without_binding_of_caller)
|
8
|
-
without_task.ruby_opts = "-I spec -r without_binding_of_caller"
|
9
|
-
|
10
|
-
task :all => [:with_binding_of_caller, :without_binding_of_caller]
|
11
|
-
end
|
12
|
-
|
13
|
-
task :default => "test:all"
|