Lighthouse has a new layout. Prefer the old one? Return to the old layout, and switch back any time from the link at the top of each page.

This project is archived and is in readonly mode.

Incomplete paths on exceptions in views

#1082

When an exception is thrown, the view shows incomplete paths:

NoMethodError in Administration/groups#show
Showing app/views//_list.erb where line ...

When it should be

NoMethodError in Administration/groups#show
Showing app/views/administration/reports/_list.erb where line ...

In Rails 2.1.0 @base_path was

@base_path = template.base_path_for_exception
which indicates a specific method to handle this, now seems gone:
@base_path = template.base_path.to_s

The problem here is that in method strip_base_path there's also a gsub that will strip this path.

Attached patch tries to fix this behaviour.

Reported by Claudio Poli · September 20th, 2008 @ 10:14 PM

State: resolved
Milestone: none
Assigned to: josh josh
Importance: none

Activity

  1. josh
    josh
    • State changed from new to open
    • Milestone cleared.

    Gah, I thought I fixed it but its back again. I'll work on writing some tests this time so it doesn't come back :)

    September 20th, 2008 @ 11:53 PM

  2. Repository
    Repository
    • State changed from open to resolved

    (from [5f83e1844c83c19cf97c6415b943c6ec3cb4bb06]) Fixed missing template paths on exception [#1082 Incomplete paths on exceptions in views state:resolved]

    Signed-off-by: Joshua Peek josh@joshpeek.com http://github.com/rails/rails/co...

    September 21st, 2008 @ 04:58 AM