actionpack 4.2.10 → 7.2.0.rc1
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of actionpack might be problematic. Click here for more details.
- checksums.yaml +5 -5
- data/CHANGELOG.md +86 -600
- data/MIT-LICENSE +1 -1
- data/README.rdoc +13 -14
- data/lib/abstract_controller/asset_paths.rb +5 -1
- data/lib/abstract_controller/base.rb +166 -136
- data/lib/abstract_controller/caching/fragments.rb +149 -0
- data/lib/abstract_controller/caching.rb +68 -0
- data/lib/abstract_controller/callbacks.rb +126 -57
- data/lib/abstract_controller/collector.rb +13 -15
- data/lib/abstract_controller/deprecator.rb +9 -0
- data/lib/abstract_controller/error.rb +8 -0
- data/lib/abstract_controller/helpers.rb +181 -132
- data/lib/abstract_controller/logger.rb +5 -1
- data/lib/abstract_controller/railties/routes_helpers.rb +10 -3
- data/lib/abstract_controller/rendering.rb +56 -56
- data/lib/abstract_controller/translation.rb +29 -15
- data/lib/abstract_controller/url_for.rb +15 -11
- data/lib/abstract_controller.rb +21 -5
- data/lib/action_controller/api/api_rendering.rb +18 -0
- data/lib/action_controller/api.rb +154 -0
- data/lib/action_controller/base.rb +219 -155
- data/lib/action_controller/caching.rb +28 -68
- data/lib/action_controller/deprecator.rb +9 -0
- data/lib/action_controller/form_builder.rb +55 -0
- data/lib/action_controller/log_subscriber.rb +35 -22
- data/lib/action_controller/metal/allow_browser.rb +119 -0
- data/lib/action_controller/metal/basic_implicit_render.rb +17 -0
- data/lib/action_controller/metal/conditional_get.rb +259 -122
- data/lib/action_controller/metal/content_security_policy.rb +86 -0
- data/lib/action_controller/metal/cookies.rb +9 -5
- data/lib/action_controller/metal/data_streaming.rb +87 -104
- data/lib/action_controller/metal/default_headers.rb +21 -0
- data/lib/action_controller/metal/etag_with_flash.rb +22 -0
- data/lib/action_controller/metal/etag_with_template_digest.rb +35 -26
- data/lib/action_controller/metal/exceptions.rb +71 -24
- data/lib/action_controller/metal/flash.rb +26 -19
- data/lib/action_controller/metal/head.rb +45 -36
- data/lib/action_controller/metal/helpers.rb +80 -64
- data/lib/action_controller/metal/http_authentication.rb +297 -244
- data/lib/action_controller/metal/implicit_render.rb +57 -9
- data/lib/action_controller/metal/instrumentation.rb +76 -64
- data/lib/action_controller/metal/live.rb +238 -176
- data/lib/action_controller/metal/logging.rb +22 -0
- data/lib/action_controller/metal/mime_responds.rb +177 -166
- data/lib/action_controller/metal/parameter_encoding.rb +84 -0
- data/lib/action_controller/metal/params_wrapper.rb +145 -118
- data/lib/action_controller/metal/permissions_policy.rb +38 -0
- data/lib/action_controller/metal/rate_limiting.rb +62 -0
- data/lib/action_controller/metal/redirecting.rb +203 -64
- data/lib/action_controller/metal/renderers.rb +108 -65
- data/lib/action_controller/metal/rendering.rb +216 -56
- data/lib/action_controller/metal/request_forgery_protection.rb +496 -163
- data/lib/action_controller/metal/rescue.rb +19 -21
- data/lib/action_controller/metal/streaming.rb +179 -138
- data/lib/action_controller/metal/strong_parameters.rb +1058 -382
- data/lib/action_controller/metal/testing.rb +11 -17
- data/lib/action_controller/metal/url_for.rb +37 -21
- data/lib/action_controller/metal.rb +236 -138
- data/lib/action_controller/railtie.rb +89 -11
- data/lib/action_controller/railties/helpers.rb +5 -1
- data/lib/action_controller/renderer.rb +161 -0
- data/lib/action_controller/template_assertions.rb +13 -0
- data/lib/action_controller/test_case.rb +425 -497
- data/lib/action_controller.rb +44 -22
- data/lib/action_dispatch/constants.rb +34 -0
- data/lib/action_dispatch/deprecator.rb +9 -0
- data/lib/action_dispatch/http/cache.rb +119 -63
- data/lib/action_dispatch/http/content_disposition.rb +47 -0
- data/lib/action_dispatch/http/content_security_policy.rb +364 -0
- data/lib/action_dispatch/http/filter_parameters.rb +36 -34
- data/lib/action_dispatch/http/filter_redirect.rb +24 -12
- data/lib/action_dispatch/http/headers.rb +66 -31
- data/lib/action_dispatch/http/mime_negotiation.rb +106 -75
- data/lib/action_dispatch/http/mime_type.rb +196 -136
- data/lib/action_dispatch/http/mime_types.rb +25 -7
- data/lib/action_dispatch/http/parameters.rb +97 -45
- data/lib/action_dispatch/http/permissions_policy.rb +187 -0
- data/lib/action_dispatch/http/rack_cache.rb +6 -0
- data/lib/action_dispatch/http/request.rb +299 -170
- data/lib/action_dispatch/http/response.rb +311 -160
- data/lib/action_dispatch/http/upload.rb +52 -23
- data/lib/action_dispatch/http/url.rb +201 -125
- data/lib/action_dispatch/journey/formatter.rb +110 -50
- data/lib/action_dispatch/journey/gtg/builder.rb +37 -50
- data/lib/action_dispatch/journey/gtg/simulator.rb +20 -17
- data/lib/action_dispatch/journey/gtg/transition_table.rb +96 -36
- data/lib/action_dispatch/journey/nfa/dot.rb +5 -14
- data/lib/action_dispatch/journey/nodes/node.rb +100 -20
- data/lib/action_dispatch/journey/parser.rb +19 -17
- data/lib/action_dispatch/journey/parser.y +4 -3
- data/lib/action_dispatch/journey/parser_extras.rb +14 -4
- data/lib/action_dispatch/journey/path/pattern.rb +79 -63
- data/lib/action_dispatch/journey/route.rb +108 -44
- data/lib/action_dispatch/journey/router/utils.rb +41 -29
- data/lib/action_dispatch/journey/router.rb +64 -57
- data/lib/action_dispatch/journey/routes.rb +23 -21
- data/lib/action_dispatch/journey/scanner.rb +28 -17
- data/lib/action_dispatch/journey/visitors.rb +100 -54
- data/lib/action_dispatch/journey/visualizer/fsm.js +49 -24
- data/lib/action_dispatch/journey/visualizer/index.html.erb +1 -1
- data/lib/action_dispatch/journey.rb +7 -5
- data/lib/action_dispatch/log_subscriber.rb +25 -0
- data/lib/action_dispatch/middleware/actionable_exceptions.rb +46 -0
- data/lib/action_dispatch/middleware/assume_ssl.rb +27 -0
- data/lib/action_dispatch/middleware/callbacks.rb +7 -6
- data/lib/action_dispatch/middleware/cookies.rb +471 -328
- data/lib/action_dispatch/middleware/debug_exceptions.rb +149 -66
- data/lib/action_dispatch/middleware/debug_locks.rb +129 -0
- data/lib/action_dispatch/middleware/debug_view.rb +73 -0
- data/lib/action_dispatch/middleware/exception_wrapper.rb +275 -73
- data/lib/action_dispatch/middleware/executor.rb +32 -0
- data/lib/action_dispatch/middleware/flash.rb +143 -101
- data/lib/action_dispatch/middleware/host_authorization.rb +171 -0
- data/lib/action_dispatch/middleware/public_exceptions.rb +36 -27
- data/lib/action_dispatch/middleware/reloader.rb +10 -92
- data/lib/action_dispatch/middleware/remote_ip.rb +133 -107
- data/lib/action_dispatch/middleware/request_id.rb +29 -15
- data/lib/action_dispatch/middleware/server_timing.rb +78 -0
- data/lib/action_dispatch/middleware/session/abstract_store.rb +49 -27
- data/lib/action_dispatch/middleware/session/cache_store.rb +33 -16
- data/lib/action_dispatch/middleware/session/cookie_store.rb +86 -80
- data/lib/action_dispatch/middleware/session/mem_cache_store.rb +15 -3
- data/lib/action_dispatch/middleware/show_exceptions.rb +66 -36
- data/lib/action_dispatch/middleware/ssl.rb +134 -36
- data/lib/action_dispatch/middleware/stack.rb +109 -44
- data/lib/action_dispatch/middleware/static.rb +159 -90
- data/lib/action_dispatch/middleware/templates/rescues/_actions.html.erb +13 -0
- data/lib/action_dispatch/middleware/templates/rescues/_actions.text.erb +0 -0
- data/lib/action_dispatch/middleware/templates/rescues/_message_and_suggestions.html.erb +22 -0
- data/lib/action_dispatch/middleware/templates/rescues/_request_and_response.html.erb +7 -24
- data/lib/action_dispatch/middleware/templates/rescues/_request_and_response.text.erb +1 -1
- data/lib/action_dispatch/middleware/templates/rescues/_source.html.erb +36 -0
- data/lib/action_dispatch/middleware/templates/rescues/_source.text.erb +8 -0
- data/lib/action_dispatch/middleware/templates/rescues/_trace.html.erb +46 -36
- data/lib/action_dispatch/middleware/templates/rescues/blocked_host.html.erb +12 -0
- data/lib/action_dispatch/middleware/templates/rescues/blocked_host.text.erb +9 -0
- data/lib/action_dispatch/middleware/templates/rescues/diagnostics.html.erb +26 -7
- data/lib/action_dispatch/middleware/templates/rescues/diagnostics.text.erb +3 -3
- data/lib/action_dispatch/middleware/templates/rescues/invalid_statement.html.erb +24 -0
- data/lib/action_dispatch/middleware/templates/rescues/invalid_statement.text.erb +16 -0
- data/lib/action_dispatch/middleware/templates/rescues/layout.erb +139 -15
- data/lib/action_dispatch/middleware/templates/rescues/missing_exact_template.html.erb +23 -0
- data/lib/action_dispatch/middleware/templates/rescues/missing_exact_template.text.erb +3 -0
- data/lib/action_dispatch/middleware/templates/rescues/missing_template.html.erb +6 -6
- data/lib/action_dispatch/middleware/templates/rescues/routing_error.html.erb +7 -7
- data/lib/action_dispatch/middleware/templates/rescues/template_error.html.erb +9 -9
- data/lib/action_dispatch/middleware/templates/rescues/template_error.text.erb +1 -1
- data/lib/action_dispatch/middleware/templates/rescues/unknown_action.html.erb +4 -4
- data/lib/action_dispatch/middleware/templates/rescues/unknown_action.text.erb +1 -1
- data/lib/action_dispatch/middleware/templates/routes/_route.html.erb +7 -4
- data/lib/action_dispatch/middleware/templates/routes/_table.html.erb +125 -93
- data/lib/action_dispatch/railtie.rb +44 -16
- data/lib/action_dispatch/request/session.rb +159 -69
- data/lib/action_dispatch/request/utils.rb +97 -23
- data/lib/action_dispatch/routing/endpoint.rb +11 -2
- data/lib/action_dispatch/routing/inspector.rb +195 -106
- data/lib/action_dispatch/routing/mapper.rb +1338 -955
- data/lib/action_dispatch/routing/polymorphic_routes.rb +234 -201
- data/lib/action_dispatch/routing/redirection.rb +78 -51
- data/lib/action_dispatch/routing/route_set.rb +460 -374
- data/lib/action_dispatch/routing/routes_proxy.rb +36 -12
- data/lib/action_dispatch/routing/url_for.rb +172 -124
- data/lib/action_dispatch/routing.rb +159 -158
- data/lib/action_dispatch/system_test_case.rb +206 -0
- data/lib/action_dispatch/system_testing/browser.rb +84 -0
- data/lib/action_dispatch/system_testing/driver.rb +85 -0
- data/lib/action_dispatch/system_testing/server.rb +33 -0
- data/lib/action_dispatch/system_testing/test_helpers/screenshot_helper.rb +164 -0
- data/lib/action_dispatch/system_testing/test_helpers/setup_and_teardown.rb +23 -0
- data/lib/action_dispatch/testing/assertion_response.rb +48 -0
- data/lib/action_dispatch/testing/assertions/response.rb +71 -39
- data/lib/action_dispatch/testing/assertions/routing.rb +228 -103
- data/lib/action_dispatch/testing/assertions.rb +9 -6
- data/lib/action_dispatch/testing/integration.rb +486 -306
- data/lib/action_dispatch/testing/request_encoder.rb +60 -0
- data/lib/action_dispatch/testing/test_helpers/page_dump_helper.rb +35 -0
- data/lib/action_dispatch/testing/test_process.rb +35 -22
- data/lib/action_dispatch/testing/test_request.rb +29 -34
- data/lib/action_dispatch/testing/test_response.rb +48 -15
- data/lib/action_dispatch.rb +82 -40
- data/lib/action_pack/gem_version.rb +8 -4
- data/lib/action_pack/version.rb +6 -2
- data/lib/action_pack.rb +21 -18
- metadata +146 -56
- data/lib/action_controller/caching/fragments.rb +0 -103
- data/lib/action_controller/metal/force_ssl.rb +0 -97
- data/lib/action_controller/metal/hide_actions.rb +0 -40
- data/lib/action_controller/metal/rack_delegation.rb +0 -32
- data/lib/action_controller/middleware.rb +0 -39
- data/lib/action_controller/model_naming.rb +0 -12
- data/lib/action_dispatch/http/parameter_filter.rb +0 -72
- data/lib/action_dispatch/journey/backwards.rb +0 -5
- data/lib/action_dispatch/journey/nfa/builder.rb +0 -76
- data/lib/action_dispatch/journey/nfa/simulator.rb +0 -47
- data/lib/action_dispatch/journey/nfa/transition_table.rb +0 -163
- data/lib/action_dispatch/journey/router/strexp.rb +0 -27
- data/lib/action_dispatch/middleware/params_parser.rb +0 -60
- data/lib/action_dispatch/middleware/templates/rescues/_source.erb +0 -27
- data/lib/action_dispatch/testing/assertions/dom.rb +0 -3
- data/lib/action_dispatch/testing/assertions/selector.rb +0 -3
- data/lib/action_dispatch/testing/assertions/tag.rb +0 -3
@@ -2,11 +2,15 @@
|
|
2
2
|
<html lang="en">
|
3
3
|
<head>
|
4
4
|
<meta charset="utf-8" />
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1">
|
6
|
+
<meta name="turbo-visit-control" content="reload">
|
5
7
|
<title>Action Controller: Exception caught</title>
|
6
8
|
<style>
|
7
9
|
body {
|
8
10
|
background-color: #FAFAFA;
|
9
11
|
color: #333;
|
12
|
+
color-scheme: light dark;
|
13
|
+
supported-color-schemes: light dark;
|
10
14
|
margin: 0px;
|
11
15
|
}
|
12
16
|
|
@@ -30,19 +34,40 @@
|
|
30
34
|
|
31
35
|
header {
|
32
36
|
color: #F0F0F0;
|
33
|
-
background: #
|
37
|
+
background: #C00;
|
34
38
|
padding: 0.5em 1.5em;
|
35
39
|
}
|
36
40
|
|
37
41
|
h1 {
|
42
|
+
overflow-wrap: break-word;
|
38
43
|
margin: 0.2em 0;
|
39
44
|
line-height: 1.1em;
|
40
45
|
font-size: 2em;
|
41
46
|
}
|
42
47
|
|
43
48
|
h2 {
|
44
|
-
color: #
|
49
|
+
color: #C00;
|
50
|
+
line-height: 25px;
|
51
|
+
}
|
52
|
+
|
53
|
+
code.traces {
|
54
|
+
font-size: 11px;
|
55
|
+
}
|
56
|
+
|
57
|
+
.response-heading, .request-heading {
|
58
|
+
margin-top: 30px;
|
59
|
+
}
|
60
|
+
|
61
|
+
.exception-message {
|
62
|
+
padding: 8px 0;
|
63
|
+
}
|
64
|
+
|
65
|
+
.exception-message .message {
|
66
|
+
margin-bottom: 8px;
|
45
67
|
line-height: 25px;
|
68
|
+
font-size: 1.5em;
|
69
|
+
font-weight: bold;
|
70
|
+
color: #C00;
|
46
71
|
}
|
47
72
|
|
48
73
|
.details {
|
@@ -50,7 +75,7 @@
|
|
50
75
|
border-radius: 4px;
|
51
76
|
margin: 1em 0px;
|
52
77
|
display: block;
|
53
|
-
width: 978px;
|
78
|
+
max-width: 978px;
|
54
79
|
}
|
55
80
|
|
56
81
|
.summary {
|
@@ -59,6 +84,13 @@
|
|
59
84
|
display: block;
|
60
85
|
}
|
61
86
|
|
87
|
+
a.summary {
|
88
|
+
color: #F0F0F0;
|
89
|
+
text-decoration: none;
|
90
|
+
background: #C52F24;
|
91
|
+
border-bottom: none;
|
92
|
+
}
|
93
|
+
|
62
94
|
.details pre {
|
63
95
|
margin: 5px;
|
64
96
|
border: none;
|
@@ -78,7 +110,7 @@
|
|
78
110
|
.source {
|
79
111
|
border: 1px solid #D9D9D9;
|
80
112
|
background: #ECECEC;
|
81
|
-
width: 978px;
|
113
|
+
max-width: 978px;
|
82
114
|
}
|
83
115
|
|
84
116
|
.source pre {
|
@@ -98,7 +130,7 @@
|
|
98
130
|
|
99
131
|
.source .data .line_numbers {
|
100
132
|
background-color: #ECECEC;
|
101
|
-
color: #
|
133
|
+
color: #555;
|
102
134
|
padding: 1em .5em;
|
103
135
|
border-right: 1px solid #DDD;
|
104
136
|
text-align: right;
|
@@ -106,6 +138,7 @@
|
|
106
138
|
|
107
139
|
.line {
|
108
140
|
padding-left: 10px;
|
141
|
+
white-space: pre;
|
109
142
|
}
|
110
143
|
|
111
144
|
.line:hover {
|
@@ -113,26 +146,120 @@
|
|
113
146
|
}
|
114
147
|
|
115
148
|
.line.active {
|
116
|
-
background-color: #
|
149
|
+
background-color: #FCC;
|
150
|
+
}
|
151
|
+
|
152
|
+
.error_highlight {
|
153
|
+
display: inline-block;
|
154
|
+
background-color: #FF9;
|
155
|
+
text-decoration: #F00 wavy underline;
|
156
|
+
}
|
157
|
+
|
158
|
+
.error_highlight_tip {
|
159
|
+
color: #666;
|
160
|
+
padding: 2px 2px;
|
161
|
+
font-size: 10px;
|
162
|
+
}
|
163
|
+
|
164
|
+
.button_to {
|
165
|
+
display: inline-block;
|
166
|
+
margin-top: 0.75em;
|
167
|
+
margin-bottom: 0.75em;
|
117
168
|
}
|
118
169
|
|
119
170
|
.hidden {
|
120
171
|
display: none;
|
121
172
|
}
|
122
173
|
|
174
|
+
.correction {
|
175
|
+
list-style-type: none;
|
176
|
+
}
|
177
|
+
|
178
|
+
input[type="submit"] {
|
179
|
+
color: white;
|
180
|
+
background-color: #C00;
|
181
|
+
border: none;
|
182
|
+
border-radius: 12px;
|
183
|
+
box-shadow: 0 3px #F99;
|
184
|
+
font-size: 13px;
|
185
|
+
font-weight: bold;
|
186
|
+
margin: 0;
|
187
|
+
padding: 10px 18px;
|
188
|
+
cursor: pointer;
|
189
|
+
-webkit-appearance: none;
|
190
|
+
}
|
191
|
+
input[type="submit"]:focus,
|
192
|
+
input[type="submit"]:hover {
|
193
|
+
opacity: 0.8;
|
194
|
+
}
|
195
|
+
input[type="submit"]:active {
|
196
|
+
box-shadow: 0 2px #F99;
|
197
|
+
transform: translateY(1px)
|
198
|
+
}
|
199
|
+
|
123
200
|
a { color: #980905; }
|
124
201
|
a:visited { color: #666; }
|
125
|
-
a.trace-frames {
|
126
|
-
|
127
|
-
|
202
|
+
a.trace-frames {
|
203
|
+
color: #666;
|
204
|
+
overflow-wrap: break-word;
|
205
|
+
}
|
206
|
+
a:hover, a.trace-frames.selected { color: #C00; }
|
207
|
+
a.summary:hover { color: #FFF; }
|
208
|
+
|
209
|
+
@media (prefers-color-scheme: dark) {
|
210
|
+
body {
|
211
|
+
background-color: #222;
|
212
|
+
color: #ECECEC;
|
213
|
+
}
|
214
|
+
|
215
|
+
.details, .summary {
|
216
|
+
border-color: #666;
|
217
|
+
}
|
218
|
+
|
219
|
+
.source {
|
220
|
+
border-color: #555;
|
221
|
+
background-color: #333;
|
222
|
+
}
|
223
|
+
|
224
|
+
.source .data {
|
225
|
+
background: #444;
|
226
|
+
}
|
227
|
+
|
228
|
+
.source .data .line_numbers {
|
229
|
+
background: #333;
|
230
|
+
border-color: #222;
|
231
|
+
}
|
232
|
+
|
233
|
+
.line:hover {
|
234
|
+
background: #666;
|
235
|
+
}
|
236
|
+
|
237
|
+
.line.active {
|
238
|
+
background-color: #900;
|
239
|
+
}
|
240
|
+
|
241
|
+
.error_highlight {
|
242
|
+
color: #333;
|
243
|
+
}
|
244
|
+
|
245
|
+
input[type="submit"] {
|
246
|
+
box-shadow: 0 3px #800;
|
247
|
+
}
|
248
|
+
input[type="submit"]:active {
|
249
|
+
box-shadow: 0 2px #800;
|
250
|
+
}
|
251
|
+
|
252
|
+
a { color: #C00; }
|
253
|
+
a.trace-frames { color: #999; }
|
254
|
+
a:hover, a.trace-frames.selected { color: #E9382B; }
|
255
|
+
}
|
128
256
|
|
129
257
|
<%= yield :style %>
|
130
258
|
</style>
|
131
259
|
|
132
260
|
<script>
|
133
261
|
var toggle = function(id) {
|
134
|
-
|
135
|
-
s.display = s.display == 'none' ? 'block' : 'none';
|
262
|
+
document.getElementById(id).classList.toggle('hidden');
|
136
263
|
return false;
|
137
264
|
}
|
138
265
|
var show = function(id) {
|
@@ -141,9 +268,6 @@
|
|
141
268
|
var hide = function(id) {
|
142
269
|
document.getElementById(id).style.display = 'none';
|
143
270
|
}
|
144
|
-
var toggleTrace = function() {
|
145
|
-
return toggle('blame_trace');
|
146
|
-
}
|
147
271
|
var toggleSessionDump = function() {
|
148
272
|
return toggle('session_dump');
|
149
273
|
}
|
@@ -154,7 +278,7 @@
|
|
154
278
|
</head>
|
155
279
|
<body>
|
156
280
|
|
157
|
-
<%= yield %>
|
281
|
+
<%= yield %>
|
158
282
|
|
159
283
|
</body>
|
160
284
|
</html>
|
@@ -0,0 +1,23 @@
|
|
1
|
+
<header role="banner">
|
2
|
+
<h1>No view template for interactive request</h1>
|
3
|
+
</header>
|
4
|
+
|
5
|
+
<main id="container">
|
6
|
+
<h2><%= h @exception.message %></h2>
|
7
|
+
|
8
|
+
<div class="summary">
|
9
|
+
<p>
|
10
|
+
<strong>NOTE:</strong> Rails usually expects a controller action to render a view template with the same name.
|
11
|
+
</p>
|
12
|
+
<p>
|
13
|
+
For example, a <code><%= @exception.controller %>#<%= @exception.action_name %></code> action defined in <code>app/controllers/<%= @exception.controller.controller_path %>_controller.rb</code> should have a corresponding view template
|
14
|
+
in a file named <code>app/views/<%= @exception.controller.controller_path %>/<%= @exception.action_name %>.html.erb</code>.
|
15
|
+
</p>
|
16
|
+
<p>
|
17
|
+
However, if this controller is an API endpoint responding with 204 (No Content), which does not require a view template because it doesn't serve an HTML response, then this error will occur when trying to access it with a browser. In this particular scenario, you can ignore this error.
|
18
|
+
</p>
|
19
|
+
<p>
|
20
|
+
You can find more about view template rendering conventions in the <a href="https://guides.rubyonrails.org/layouts_and_rendering.html#rendering-by-default-convention-over-configuration-in-action">Rails Guides on Layouts and Rendering in Rails</a>.
|
21
|
+
</p>
|
22
|
+
</div>
|
23
|
+
</main>
|
@@ -1,11 +1,11 @@
|
|
1
|
-
<header>
|
1
|
+
<header role="banner">
|
2
2
|
<h1>Template is missing</h1>
|
3
3
|
</header>
|
4
4
|
|
5
|
-
<
|
6
|
-
<h2><%= h @
|
5
|
+
<main role="main" id="container">
|
6
|
+
<h2><%= h @exception_wrapper.message %></h2>
|
7
7
|
|
8
|
-
<%= render
|
9
|
-
<%= render
|
8
|
+
<%= render "rescues/source", source_extracts: @source_extracts, show_source_idx: @show_source_idx %>
|
9
|
+
<%= render "rescues/trace", traces: @traces, trace_to_show: @trace_to_show %>
|
10
10
|
<%= render template: "rescues/_request_and_response" %>
|
11
|
-
</
|
11
|
+
</main>
|
@@ -1,20 +1,20 @@
|
|
1
|
-
<header>
|
1
|
+
<header role="banner">
|
2
2
|
<h1>Routing Error</h1>
|
3
3
|
</header>
|
4
|
-
<
|
5
|
-
<h2><%= h @
|
6
|
-
<% unless @
|
4
|
+
<main role="main" id="container">
|
5
|
+
<h2><%= h @exception_wrapper.message %></h2>
|
6
|
+
<% unless @exception_wrapper.failures.empty? %>
|
7
7
|
<p>
|
8
8
|
<h2>Failure reasons:</h2>
|
9
9
|
<ol>
|
10
|
-
<% @
|
10
|
+
<% @exception_wrapper.failures.each do |route, reason| %>
|
11
11
|
<li><code><%= route.inspect.delete('\\') %></code> failed because <%= reason.downcase %></li>
|
12
12
|
<% end %>
|
13
13
|
</ol>
|
14
14
|
</p>
|
15
15
|
<% end %>
|
16
16
|
|
17
|
-
<%= render
|
17
|
+
<%= render "rescues/trace", traces: @traces, trace_to_show: @trace_to_show %>
|
18
18
|
|
19
19
|
<% if @routes_inspector %>
|
20
20
|
<h2>
|
@@ -29,4 +29,4 @@
|
|
29
29
|
<% end %>
|
30
30
|
|
31
31
|
<%= render template: "rescues/_request_and_response" %>
|
32
|
-
</
|
32
|
+
</main>
|
@@ -1,20 +1,20 @@
|
|
1
|
-
<header>
|
1
|
+
<header role="banner">
|
2
2
|
<h1>
|
3
|
-
<%= @
|
3
|
+
<%= @exception_wrapper.exception_name %> in
|
4
4
|
<%= @request.parameters["controller"].camelize if @request.parameters["controller"] %>#<%= @request.parameters["action"] %>
|
5
5
|
</h1>
|
6
6
|
</header>
|
7
7
|
|
8
|
-
<
|
8
|
+
<main role="main" id="container">
|
9
9
|
<p>
|
10
|
-
Showing <i><%= @
|
10
|
+
Showing <i><%= @exception_wrapper.file_name %></i> where line <b>#<%= @exception_wrapper.line_number %></b> raised:
|
11
11
|
</p>
|
12
|
-
<pre><code><%= h @
|
12
|
+
<pre><code><%= h @exception_wrapper.message %></code></pre>
|
13
13
|
|
14
|
-
<%= render
|
14
|
+
<%= render "rescues/source", source_extracts: @source_extracts, show_source_idx: @show_source_idx %>
|
15
15
|
|
16
|
-
<p><%= @
|
16
|
+
<p><%= @exception_wrapper.sub_template_message %></p>
|
17
17
|
|
18
|
-
<%= render
|
18
|
+
<%= render "rescues/trace", traces: @traces, trace_to_show: @trace_to_show %>
|
19
19
|
<%= render template: "rescues/_request_and_response" %>
|
20
|
-
</
|
20
|
+
</main>
|
@@ -1,4 +1,4 @@
|
|
1
|
-
<%= @exception.
|
1
|
+
<%= @exception.cause.class.to_s %> in <%= @request.parameters["controller"].camelize if @request.parameters["controller"] %>#<%= @request.parameters["action"] %>
|
2
2
|
|
3
3
|
Showing <%= @exception.file_name %> where line #<%= @exception.line_number %> raised:
|
4
4
|
<%= @exception.message %>
|
@@ -1,6 +1,6 @@
|
|
1
|
-
<header>
|
1
|
+
<header role="banner">
|
2
2
|
<h1>Unknown action</h1>
|
3
3
|
</header>
|
4
|
-
<
|
5
|
-
|
6
|
-
</
|
4
|
+
<main role="main" id="container">
|
5
|
+
<%= render "rescues/message_and_suggestions", exception: @exception, exception_wrapper: @exception_wrapper %>
|
6
|
+
</main>
|
@@ -4,13 +4,16 @@
|
|
4
4
|
<%= route[:name] %><span class='helper'>_path</span>
|
5
5
|
<% end %>
|
6
6
|
</td>
|
7
|
-
<td
|
7
|
+
<td>
|
8
8
|
<%= route[:verb] %>
|
9
9
|
</td>
|
10
|
-
<td data-route-path='<%= route[:path] %>'
|
10
|
+
<td data-route-path='<%= route[:path] %>'>
|
11
11
|
<%= route[:path] %>
|
12
12
|
</td>
|
13
|
-
<td
|
14
|
-
<%= route[:reqs] %>
|
13
|
+
<td>
|
14
|
+
<%=simple_format route[:reqs] %>
|
15
|
+
</td>
|
16
|
+
<td>
|
17
|
+
<%=simple_format route[:source_location] %>
|
15
18
|
</td>
|
16
19
|
</tr>
|