Word up and thanks to those that continue to contribute positively to the group. I am about to lop off my left nut to get to the bottom of a strange behavior I''m witnessing. Rails somehow can''t find an action name called ''start'' in any of my controllers. Rename it to, say, ''startx'', load that url, and it works as expected. Before I go off shearing this yak any further, can anyone please suggest how I should go about debugging this? I''d like to be able to discover exactly where in the stack Rails is somehow not I realize continual test coverage across my controller actions might have prevented the hairiness of this yak that stands before me. I''ll light a TDD candle later. Right now, I''ve gotta shear this here yak. I have tried: - removing all plugins - removing all my custom routes - tried the action in different controllers - opened a breakpointer in the controller - making sure I haven''t used ''start'' in some funny way anywhere in the app - tried the action declaration in different controllers - created a new rails app and _could not_ replicate the problem - asked the Google - begun to shave the yak''s genitals All I want is an action called start, like I have had many times in the past (sans yak). I''m about to do some more playing with the debugger, and create a functional test against the controller. Thanks for reading. --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
tshim wrote:> Right now, I''ve gotta shear this here yak. I have tried: > - removing all plugins > - removing all my custom routes > - tried the action in different controllers > - opened a breakpointer in the controller > - making sure I haven''t used ''start'' in some funny way anywhere in the > app > - tried the action declaration in different controllers > - created a new rails app and _could not_ replicate the problem > - asked the Google > - begun to shave the yak''s genitalsYou went thru all that labor _before_ just writing one stinking functional test???? (Did you grep \\bstart\\b . -r all the code?) > I realize continual test coverage across my controller actions might > have prevented the hairiness of this yak that stands before me. I''ll > light a TDD candle later. That''s not TDD - you didn''t test FIRST. Have we learned our LESSON yet??? --~--~---------~--~----~------------~-------~--~----~ 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 did go through the results of grepping ''start'' -- truly, nothing suspicious there. There is hair everywhere now. I''ve created a new rails app, declared a simple controller and two actions, ''start'' and ''startx''. Each url responds as expected via the browser. Two simple functional tests, def test_start get :start assert_response :success end def test_startx get :startx assert_response :success end reveal that test_start fails while test_startx passes. However, as I just wrote while coughing on yak hair, _both_ actions in the fresh app respond appropriately in the browser. Anyway, I''m sure I can get to the bottom of this if I just knew how to get ''deeper'' in tracing the rails stack. Any tips? --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
> Anyway, I''m sure I can get to the bottom of this if I just knew how to > get ''deeper'' in tracing the rails stack. Any tips?Post your routes.rb, and your rails -v version? --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
Before I go off shearing this yak any further, can anyone please suggest how I should go about debugging this? I''d like to be able to discover exactly where in the stack Rails is somehow not loading the class properly. Thanks for taking the time to reply, Phlip. I''m running Rails 2.1.0. My routes: http://pastie.org/229541 The stacktrace: http://pastie.org/229542 On Jul 7, 9:25 pm, Phlip <phlip2...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Post your routes.rb, and your rails -v version?--~--~---------~--~----~------------~-------~--~----~ 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@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
On 8 Jul 2008, at 05:07, tshim wrote:> > Before I go off shearing this yak any further, can anyone please > suggest how I should go about debugging this? I''d like to be able to > discover exactly where in the stack Rails is somehow not loading the > class properly. > > Thanks for taking the time to reply, Phlip. > > I''m running Rails 2.1.0.It''s because you''ve got the debugger enabled (rails enables it in tests by default with 2.1). rdebug defines Kernel#start which means that ActionController considers the method not to be an action (Long version here: http://www.spacevatican.org/2008/5/1/it-s-always-the-butler) Fred> > > My routes: http://pastie.org/229541 > > The stacktrace: http://pastie.org/229542 > > > > On Jul 7, 9:25 pm, Phlip <phlip2...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote: >> Post your routes.rb, and your rails -v version? > >--~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
Thanks for the tip Frederick. That is exactly the issue. A ticket was opened for ruby-debug, and it looks like it was fixed in r848 at the very same time I started whining to the group about my yak. --- action named start action called start On Jul 8, 2:39 am, Frederick Cheung <frederick.che...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> It''s because you''ve got the debugger enabled (rails enables it in > tests by default with 2.1). > rdebug defines Kernel#start which means that ActionController > considers the method not to be an action (Long version here:http://www.spacevatican.org/2008/5/1/it-s-always-the-butler)--~--~---------~--~----~------------~-------~--~----~ 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@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---