problem setting multiple cookies
normalperson at yhbt.net
Wed Jun 22 02:02:55 EDT 2011
Jason Su <jason at lookbook.nu> wrote:
> Hey Eric,
> Actually I think I am using OldRails -- don't know what it is or why
> I'm doing it, but this is in my config.ru:
It might be because you were on Rails 2.2 or earlier and upgraded?
> map '/' do
> if RAILS_ENV != 'production'
> require 'rack/bug'
> use Rack::Bug, :password => nil
> rescue LoadError
> use Rails::Rack::Static
> run Unicorn::App::OldRails.new
> Should I not be using OldRails?
OldRails was for Rails <= 2.2, so you should probably try this instead:
This should use the pure Rack backend that avoids the old CGI
and CGIWrapper code which Rails <=2.2 relied on.
> I'm also trying to upgrade to Rails 2.3.11 again. Here's the error
> that's stopping me:
> You have a nil object when you didn't expect it!
> You might have expected an instance of Array.
> The error occurred while evaluating nil.split You have a nil object
> when you didn't expect it!
> I found this, which I think is somehow related to the fix:
> Do you see anything that looks familiar?
I haven't seen it before, but it looks to be on the right track.
OldRails uses the CGIWrapper code which is based on the original
code in Mongrel, too.
If you avoid CGIWrapper, you should be able to avoid the
workarounds/issues with it like the above gist.
More information about the mongrel-unicorn