Forum: Ruby on Rails Failsafe errors since upgrading to 2.3

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
AtsoK (Guest)
on 2009-03-22 23:45
(Received via mailing list)
Since upgrading to 2.3, this error shows up dozens of times a day, and
I have no idea what's causing it. Anyone have any ideas?

Processing ApplicationController#index (for 62.75.252.249 at
2009-03-22 13:23:08) [GET]
Rendering /home/andrew/public_html/mysite/public/404.html (404 Not
Found)
/!\ FAILSAFE /!\  Sun Mar 22 13:24:09 -0700 2009
  Status: 500 Internal Server Error
  undefined method `[]' for nil:NilClass
    /usr/lib/ruby/gems/1.8/gems/actionpack-2.3.2/lib/action_controller/
session/cookie_store.rb:106:in `call'
    /usr/lib/ruby/gems/1.8/gems/actionpack-2.3.2/lib/action_controller/
failsafe.rb:11:in `call'
    /usr/lib/ruby/gems/1.8/gems/actionpack-2.3.2/lib/action_controller/
vendor/rack-1.0/rack/lock.rb:11:in `call'
    /usr/lib/ruby/gems/1.8/gems/actionpack-2.3.2/lib/action_controller/
vendor/rack-1.0/rack/lock.rb:11:in `synchronize'
    /usr/lib/ruby/gems/1.8/gems/actionpack-2.3.2/lib/action_controller/
vendor/rack-1.0/rack/lock.rb:11:in `call'
    /usr/lib/ruby/gems/1.8/gems/actionpack-2.3.2/lib/action_controller/
dispatcher.rb:106:in `call'
    /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/
rack/request_handler.rb:65:in `process_request'
    /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/
abstract_request_handler.rb:197:in `main_loop'
    /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/
railz/application_spawner.rb:340:in `start_request_handler'
    /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/
railz/application_spawner.rb:298:in `handle_spawn_application'
    /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/
utils.rb:176:in `safe_fork'
    /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/
railz/application_spawner.rb:296:in `handle_spawn_application'
    /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/
abstract_server.rb:332:in `__send__'
    /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/
abstract_server.rb:332:in `main_loop'
    /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/
abstract_server.rb:182:in `start_synchronously'
    /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/
abstract_server.rb:149:in `start'
    /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/
railz/application_spawner.rb:192:in `start'
    /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/
spawn_manager.rb:260:in `spawn_rails_application'
    /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/
abstract_server_collection.rb:121:in `lookup_or_add'
    /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/
spawn_manager.rb:254:in `spawn_rails_application'
    /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/
abstract_server_collection.rb:75:in `synchronize'
    /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/
abstract_server_collection.rb:74:in `synchronize'
    /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/
spawn_manager.rb:253:in `spawn_rails_application'
    /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/
spawn_manager.rb:148:in `spawn_application'
    /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/
spawn_manager.rb:285:in `handle_spawn_application'
    /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/
abstract_server.rb:332:in `__send__'
    /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/
abstract_server.rb:332:in `main_loop'
    /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/lib/phusion_passenger/
abstract_server.rb:182:in `start_synchronously'
    /usr/lib/ruby/gems/1.8/gems/passenger-2.1.2/bin/passenger-spawn-
server:50
Conrad T. (Guest)
on 2009-03-23 00:42
(Received via mailing list)
On Sun, Mar 22, 2009 at 2:45 PM, AtsoK <removed_email_address@domain.invalid> 
wrote:

>
> Since upgrading to 2.3, this error shows up dozens of times a day, and
> I have no idea what's causing it. Anyone have any ideas?
>
>
[ snip error listing ]

So, please tell us about your configuration?  When do these error occur
exactly?
If this is a production application, have you done any load testing
locally
to reproduce
these error messages?  Did you update your rails configurations when
moving
from 2.1.2
to 2.3.2 (i.e. rake rails:update)?

-Conrad
Andrew (Guest)
on 2009-03-23 01:15
(Received via mailing list)
Certainly, it's on Ubuntu 8.04, using Passenger 2.1.2, and yes I
changed the version number in environment.rb + ran that rake command.
I commented out my config.log_level line so I can see when that error
occurs, but it's popping up in random places (not just happening when
a certain action gets called -- I've been going to the locations that
have been called right before the error occurs, but everything works
fine for me). I haven't done any load testing.
Philip H. (Guest)
on 2009-03-23 02:09
(Received via mailing list)
I had this happen to me recently and found this post to be useful.

http://billkirtley.wordpress.com/2009/03/03/failsa...

I don't think that will solve your problem though as it's particular
to mongrel, but it should provide some framework to work from.

My understanding is that FAILSAFE happens when another error is being
recued_in_public and the rescuing itself throws an error.

Good luck!
pankaj88 (Guest)
on 2009-03-24 15:07
(Received via mailing list)
i dont know about any other error but the first error dat i
encountered while convertiong it ti rails 2.3.2 was uninitialized
application cntroller and i just renamed application.rb
to application_controller.rb
Greg D. (Guest)
on 2009-03-24 19:55
(Received via mailing list)
On Tue, Mar 24, 2009 at 6:26 AM, pankaj88 <removed_email_address@domain.invalid>
wrote:
>
> i dont know about any other error but the first error dat i
> encountered while convertiong it ti rails 2.3.2 was uninitialized
> application cntroller and i just renamed application.rb
> to application_controller.rb

`rake rails:update` does that for you (in 2.3.2 anyway).


--
Greg D.
http://destiney.com/
Andrew (Guest)
on 2009-03-31 10:36
(Received via mailing list)
Hi everyone, posting to let you know that I discovered that this error
pops up every time I go to /session. Though I'm not sure how the error
could occur all the time unless people go to straight to mysite.com/
session or something. Logging in works for me (and everyone else as
far as I can tell). I'm using the latest update of restful-
authentication. Thanks!
Pirkka H. (Guest)
on 2010-01-26 17:03
I can reproduce the exact same behaviour as Andrew above with 2.3.3, app
works otherwise but any /session urls result in the error because the
"options" variable in cookie_store#call mysteriously evaluates to nil.
Pirkka H. (Guest)
on 2010-01-26 17:40
Actually, looks like any route that is not found can trigger the same
failsafe error, no matter if we use cookie store or the active record
store (in latter case the exception is just raised in
absract_session_store instead).
Pirkka H. (Guest)
on 2010-01-27 15:51
The problem I reported above was solved simply by updating the
exceptional plugin from version 0.0.2. (!) to 2.0.7.

Posting this here in case someone else has failed at keeping their gems
up-to-date when upgrading to Rails 2.3.
This topic is locked and can not be replied to.