Skip to content

Loading…

url_for(:controller => 'un_existing', :action => 'show) returns /assets url in 3.2 #6459

Closed
betelgeuse opened this Issue · 3 comments

3 participants

@betelgeuse

In an application without FooController:

url_for(:controller => 'foo', :action => 'show')

In rails 3.1 this raises ActionController::RoutingError

In rails 3.2 you get an url returned:

/assets?action=show&controller=foo

The rails 3.1 result seems the proper one.

@tenderlove Is this a regression in journey?

@drogus drogus was assigned
@drogus
Ruby on Rails member

This is rather not regression in journey, as the problem is that assets engine catches this route. If you disable assets you will see RoutingError as in the 3.1 application. I will check why exactly assets catch that route.

@drogus
Ruby on Rails member

Just a quick update. I haven't had time to work on this, but my previous comment is stupid :) It is regression in journey, as it's during generation. Sorry for confusion.

@tenderlove tenderlove added a commit that referenced this issue
@tenderlove tenderlove adding a test for #6459 28e744d
@tenderlove tenderlove added a commit that referenced this issue
@tenderlove tenderlove adding a test for #6459 e7d1849
@tenderlove tenderlove added a commit that referenced this issue
@tenderlove tenderlove adding a test for #6459 b92860f
@tenderlove
Ruby on Rails member

Should be fixed here.

Thanks for reporting this!

@tenderlove tenderlove closed this
@jperkin jperkin pushed a commit to joyent/pkgsrc that referenced this issue
taca Update ruby-journey to 1.0.4.
Thu Jun 14 14:03:22 2012  Aaron Patterson <aaron@tenderlovemaking.com>

	* lib/journey/formatter.rb: when generating routes, skip route
          literals (routes that do not have replacement values like
          "/:controller") when matching unnamed routes.

            rails/rails#6459

        * test/test_router.rb: corresponding test
5447cb1
@jsonn jsonn pushed a commit to jsonn/pkgsrc that referenced this issue
taca Update ruby-journey to 1.0.4.
Thu Jun 14 14:03:22 2012  Aaron Patterson <aaron@tenderlovemaking.com>

	* lib/journey/formatter.rb: when generating routes, skip route
          literals (routes that do not have replacement values like
          "/:controller") when matching unnamed routes.

            rails/rails#6459

        * test/test_router.rb: corresponding test
34a002b
@ttosch ttosch pushed a commit that referenced this issue
@tenderlove tenderlove adding a test for #6459 b21d851
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.