How do I debug a routing error? I''ve been running examples from the Agile Rails book just fine to the end of Chapter 8, cart creation. Then the next morning my installation stopped working. "no route found to match "/store" with {:method=>:get}" attempting to debug:>> rs = ActionController::Routing::Routes >> rs.recognize_path "/store"=> {:controller=>"store", :action=>"index"} the problem persists despite making the suggestion of changing root_path = Pathname.new(root_path).cleanpath(true).to_s in config/boot.rb for my rails 1.2.3 installation. TIA --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Ming - On 14-Jul-07, at 2:46 PM, Ming wrote:> > How do I debug a routing error? > > I''ve been running examples from the Agile Rails book just fine to the > end of Chapter 8, cart creation. Then the next morning my installation > stopped working. > > "no route found to match "/store" with {:method=>:get}" > > attempting to debug: > >>> rs = ActionController::Routing::Routes >>> rs.recognize_path "/store" > => {:controller=>"store", :action=>"index"} > > the problem persists despite making the suggestion of changing > > root_path = Pathname.new(root_path).cleanpath(true).to_s > > in config/boot.rb for my rails 1.2.3 installation. > > TIAI''ve found Rick''s routing_navigator[1] plugin to be helpful. Plus topfunky''s "REST Cheetsheet"[2] is a darling. Jodi [1] http://svn.techno-weenie.net/projects/plugins/routing_navigator/ [2] http://topfunky.com/clients/peepcode/REST-cheatsheet.pdf --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
what does your routes.rb look like?> "no route found to match "/store" with {:method=>:get}" > > attempting to debug: > >>> rs = ActionController::Routing::Routes >>> rs.recognize_path "/store" > => {:controller=>"store", :action=>"index"}-- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
routes.rb: ActionController::Routing::Routes.draw do |map| map.connect '':controller/:action/:id.:format'' map.connect '':controller/:action/:id'' end On Jul 14, 3:16 pm, Matthew Rudy <rails-mailing-l...-ARtvInVfO7ksV2N9l4h3zg@public.gmane.org> wrote:> what does your routes.rb look like? > > > "no route found to match "/store" with {:method=>:get}" > > > attempting to debug: > > >>> rs = ActionController::Routing::Routes > >>> rs.recognize_path "/store" > > => {:controller=>"store", :action=>"index"} > > -- > Posted viahttp://www.ruby-forum.com/.--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
Jodi - The pdf looks really cool... though at this stage of my railship, i''m not sure what to make of it... I might to install Edge Rails and Rick''s routing_navigator plugin to get to the root of my problem thanks. On Jul 14, 2:56 pm, Jodi Showers <j...-BOB1p6JRLoAV+D8aMU/kSg@public.gmane.org> wrote:> Ming - > > On 14-Jul-07, at 2:46 PM, Ming wrote: > > > > > > > How do I debug a routing error? > > > I''ve been running examples from the Agile Rails book just fine to the > > end of Chapter 8, cart creation. Then the next morning my installation > > stopped working. > > > "no route found to match "/store" with {:method=>:get}" > > > attempting to debug: > > >>> rs = ActionController::Routing::Routes > >>> rs.recognize_path "/store" > > => {:controller=>"store", :action=>"index"} > > > the problem persists despite making the suggestion of changing > > > root_path = Pathname.new(root_path).cleanpath(true).to_s > > > in config/boot.rb for my rails 1.2.3 installation. > > > TIA > > I''ve found Rick''s routing_navigator[1] plugin to be helpful. > > Plus topfunky''s "REST Cheetsheet"[2] is a darling. > > Jodi > > [1]http://svn.techno-weenie.net/projects/plugins/routing_navigator/ > [2]http://topfunky.com/clients/peepcode/REST-cheatsheet.pdf--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
i meant to say that in boot.rb i changed root_path = Pathname.new(root_path).cleanpath(true).to_s to root_path = Pathname.new(root_path).cleanpath(true).realpath().to_s per http://thenoobonrails.blogspot.com/2007/06/rails-12x-routing-issues.html this has not helped... On Jul 14, 2:46 pm, Ming <min...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> How do I debug a routing error? > > I''ve been running examples from the Agile Rails book just fine to the > end of Chapter 8, cart creation. Then the next morning my installation > stopped working. > > "no route found to match "/store" with {:method=>:get}" > > attempting to debug: > > >> rs = ActionController::Routing::Routes > >> rs.recognize_path "/store" > > => {:controller=>"store", :action=>"index"} > > the problem persists despite making the suggestion of changing > > root_path = Pathname.new(root_path).cleanpath(true).to_s > > in config/boot.rb for my rails 1.2.3 installation. > > TIA--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
i fixed the problem by uninstalling and reinstalling the rails gem. apparently i have a version of the elsewhere reported spurious routes for rails 1.2.3 that doesn''t get fixed by adding realpath to root_path: root_path = Pathname.new(root_path).cleanpath(true).realpath().to_s thanks to all who responded. On Jul 14, 2:46 pm, Ming <min...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> How do I debug a routing error? > > I''ve been running examples from the Agile Rails book just fine to the > end of Chapter 8, cart creation. Then the next morning my installation > stopped working. > > "no route found to match "/store" with {:method=>:get}" > > attempting to debug: > > >> rs = ActionController::Routing::Routes > >> rs.recognize_path "/store" > > => {:controller=>"store", :action=>"index"} > > the problem persists despite making the suggestion of changing > > root_path = Pathname.new(root_path).cleanpath(true).to_s > > in config/boot.rb for my rails 1.2.3 installation. > > TIA--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---