On Wed, May 14, 2008 at 4:55 AM, Daniel Hahn <[EMAIL PROTECTED]> wrote:
> Problem description:
>
> JRuby interferes with routing where there is the following arrangement of
> controllers
>
> * something_controller.rb
> * something/ +- sub_controller.rb
>
> this will not correctly match the 'something/sub' controller. The reason
> being:
>
> * The Route#recognize method will engage in creating meta-methods that
> match against regular expressions. (From Route#write_recognition)
> * For the default route, this will eventually land in
> ControllerSegment#regexp_chunk?
> * This will query Routing#possible_controllers
> * This method will collect the file paths from the controllers, using
> Dir.../**/*_controller.rb"
>
> The controllers are then put into the regular expression.
>
> For MRI, the Dir method reports files in subdirectories first. The JRuby
> implementation does not.
Interesting! So you can confirm that the Dir[...] ordering is what
breaks it? We should be able to fix that -- I'd want to add to the
rubyspecs to ensure that this case is covered.
/Nick
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email