Hello, I wish to route a sinatra application in my Rails 3 app. As said by Yehuda, it should be possible. http://yehudakatz.com/2009/12/26/the-rails-3-router-rack-it-up/ However I see the route isn''t recognized and I get ActionController::RoutingError problems. It works well with simple rack apps however (the test in actionpack with a lambda passes well). I''ve written a test case which fails. But I couldn''t reproduce it without sinatra. http://gist.github.com/376653 If you have any more luck than me, I''m all hears. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. To post to this group, send email to rubyonrails-core@googlegroups.com. To unsubscribe from this group, send email to rubyonrails-core+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-core?hl=en.
I can confirm that this is true. The `recognize_path` lookup failed not because it couldn''t find ''/nested_application'', but because it found it and failed on `route.app.is_a?(Dispatcher)` lookup. `route.app` returns Sinatra::ShowExceptions, which is the first Sinatra middleware on the stack that''s unique to Sinatra. I would suspect that this bug is in Rack::Mount, not Rails, but I''m not sure. (I''ve only poked around for a couple of minutes.) On Fri, Apr 23, 2010 at 17:15, Damien MATHIEU <42@dmathieu.com> wrote:> Hello, > > I wish to route a sinatra application in my Rails 3 app. As said by > Yehuda, it should be possible. > http://yehudakatz.com/2009/12/26/the-rails-3-router-rack-it-up/ > > However I see the route isn''t recognized and I get > ActionController::RoutingError problems. > It works well with simple rack apps however (the test in actionpack > with a lambda passes well). > > I''ve written a test case which fails. But I couldn''t reproduce it > without sinatra. > http://gist.github.com/376653 > If you have any more luck than me, I''m all hears. > > -- > You received this message because you are subscribed to the Google Groups > "Ruby on Rails: Core" group. > To post to this group, send email to rubyonrails-core@googlegroups.com. > To unsubscribe from this group, send email to > rubyonrails-core+unsubscribe@googlegroups.com<rubyonrails-core%2Bunsubscribe@googlegroups.com> > . > For more options, visit this group at > http://groups.google.com/group/rubyonrails-core?hl=en. > >-- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. To post to this group, send email to rubyonrails-core@googlegroups.com. To unsubscribe from this group, send email to rubyonrails-core+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-core?hl=en.
FYI I''ve created a ticket about that on LightHouse. https://rails.lighthouseapp.com/projects/8994/tickets/4478-impossibility-to-mount-a-sinatra-app On 23 avr, 17:56, Mislav Marohnić <mislav.maroh...@gmail.com> wrote:> I can confirm that this is true. The `recognize_path` lookup failed not > because it couldn''t find ''/nested_application'', but because it found it and > failed on `route.app.is_a?(Dispatcher)` lookup. `route.app` > returns Sinatra::ShowExceptions, which is the first Sinatra middleware on > the stack that''s unique to Sinatra. > > I would suspect that this bug is in Rack::Mount, not Rails, but I''m not > sure. (I''ve only poked around for a couple of minutes.) > > > > On Fri, Apr 23, 2010 at 17:15, Damien MATHIEU <4...@dmathieu.com> wrote: > > Hello, > > > I wish to route a sinatra application in my Rails 3 app. As said by > > Yehuda, it should be possible. > >http://yehudakatz.com/2009/12/26/the-rails-3-router-rack-it-up/ > > > However I see the route isn''t recognized and I get > > ActionController::RoutingError problems. > > It works well with simple rack apps however (the test in actionpack > > with a lambda passes well). > > > I''ve written a test case which fails. But I couldn''t reproduce it > > without sinatra. > >http://gist.github.com/376653 > > If you have any more luck than me, I''m all hears. > > > -- > > You received this message because you are subscribed to the Google Groups > > "Ruby on Rails: Core" group. > > To post to this group, send email to rubyonrails-core@googlegroups.com. > > To unsubscribe from this group, send email to > > rubyonrails-core+unsubscribe@googlegroups.com<rubyonrails-core%2Bunsubscribe@googlegroups.com> > > . > > For more options, visit this group at > >http://groups.google.com/group/rubyonrails-core?hl=en. > > -- > You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. > To post to this group, send email to rubyonrails-core@googlegroups.com. > To unsubscribe from this group, send email to rubyonrails-core+unsubscribe@googlegroups.com. > For more options, visit this group athttp://groups.google.com/group/rubyonrails-core?hl=en.-- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Core" group. To post to this group, send email to rubyonrails-core@googlegroups.com. To unsubscribe from this group, send email to rubyonrails-core+unsubscribe@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-core?hl=en.