Skip to content

REALLY hard to debug errors in web-console #178

@schneems

Description

@schneems

Hit a bug in web_console when trying to upgrade to Rails 5. It took me hours to figure out where it was coming from. This was the only thing in my logs:

Started GET "/" for ::1 at 2016-01-11 16:39:26 -0600

This was what I was rendering in development mode:

Why was this happening? Web-console inserts itself right before debug_exceptions middleware which makes sense, normally this is the middleware that would render the error to the logs, however web-console relies on getting the request before this point. Unfortunately this means it comes right after show_exceptions middleware which contrary to the name, does not show what exception is occurring, instead it swallows it and returns a default 500 response.

Bug: Web-console doesn't have any kind of fail safe response or debugging when internals fail. Either let's find a way to play nice with debug-exceptions middleware and put it afterwards, or essentially duplicate logic in debug-exceptions so we at least log errors to the logger.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions