1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00
Commit graph

23 commits

Author SHA1 Message Date
Kir Shatrov
a725a453b3 Display exceptions in text format for xhr request 2013-08-22 22:20:34 +04:00
Gosha Arinich
d73cc03010 remove begin-rescue in favor of def-rescue 2013-01-07 04:02:20 +03:00
Rafael Mendonça França
cc24eba544 Fix operators precedence issue 2013-01-06 21:54:46 -03:00
Rafael Mendonça França
dc4b4c46ef Merge pull request #8787 from tank-bohr/master
masgn and response variable
2013-01-06 16:00:14 -08:00
Gosha Arinich
c445b07612 refactor DebugExceptions by combining two conditionals into one 2013-01-07 02:46:03 +03:00
tank-bohr
f3101fd0fc return multiple assingment and response variable 2013-01-07 03:37:06 +04:00
tank-bohr
8f18550b0a fix for rbx
Rubinius returns a boolean after such assingment
response = (_, headers, body = @app.call(env))

see https://github.com/rubinius/rubinius/issues/2117

get rid of a local variable
2013-01-07 02:00:40 +04:00
Carlos Antonio da Silva
3abb76824b Move table routes formatter class to the inspector and rename it
It feels more consistent to have this class called "HtmlTableFormatter",
and to have it here with the routes inspector and console formatter,
since it's used for both routing error exceptions and the rails info
page.
2013-01-06 11:19:30 -02:00
Yves Senn
80795e02ca display mountable engine routes on RoutingError. 2013-01-05 14:31:03 +01:00
Guillermo Iguaran
fe12e46508 Add source extract to detailed exception page 2012-12-31 13:48:00 -05:00
Rafael Mendonça França
84d38f6033 We need to check explictly that env['action_dispatch.show_exceptions']
is false.

If it is nil we can't raise the exception
2012-12-26 12:15:18 -03:00
Hrvoje Šimić
7731fd86b1 more descriptive return parameters 2012-12-26 14:17:11 +01:00
schneems
37d9c44b6d Format routes as html on debug page
When someone gets a routing exception, the routes are rendered (starting in Rails 4.0). This PR brings parity between the html routes in the `rails/info/routes` path and when rendered from an exception. This is the continuation of #8521 which brought html formatted routes. 

In addition to bringing parity to the two views, we're keeping our views DRY by rendering off of the same partials. In this case Railties depends on partials provided by ActionDispatch. I'm open to alternative implementations. Ideally both views will use the same code so any improvements or updates to it will be reproduced on both.

<hr />

![](http://f.cl.ly/items/3O1D0K1v0j0i343O3T3T/Screen%20Shot%202012-12-17%20at%203.07.20%20PM.png)
2012-12-17 15:59:15 -06:00
schneems
170a93d25c DebugExceptions File.join => File.expand_path 2012-12-16 12:34:34 -06:00
Carlos Antonio da Silva
9c4afcf4cd Rename RouteInspector to RoutesInspector
Follow the consistency defined in dbc43bc.
2012-07-08 13:49:15 -03:00
@schneems and @mattt
ef91cddb48 move route_inspector to actionpack
this is so we can show route output in the development when we get a routing error. Railties can use features of ActionDispatch, but ActionDispatch should not depend on Railties.
2012-07-07 15:39:49 -05:00
schneems
fa714ec7df show routes while debugging RoutingError
If someone receives a routing error, they likely need to view the routes. Rather than making them visit '/rails/info/routes' or run `rake routes` we can give them that information on the page.
2012-07-07 15:38:29 -05:00
Karunakar (Ruby)
0fdf029291 Action pack logger methodschanged to active supoort Logger methods 2011-12-22 00:19:25 +05:30
José Valim
5359262695 ShowExceptions should understand X-Cascade responses from exceptions app. 2011-12-16 10:45:59 +01:00
José Valim
e3a4eb4b40 Close the response body on cascade pass, closes #3975. 2011-12-14 17:03:35 +01:00
Sergey Nartimov
081431fdf1 log exception backtrace when all backtrace lines silenced 2011-12-13 22:32:39 +03:00
José Valim
2ab2077235 Fix failing cascade exception. 2011-12-03 11:38:25 +01:00
José Valim
750bb5c865 Split ShowExceptions responsibilities in two middlewares. 2011-12-01 20:46:18 +01:00