This project is archived and is in readonly mode.
ActionPack 2.3.5 gem declares incompatibility with rack 1.1.0
-
Vivek Pandey
Ditto! Same with GlassFish gem with rack (1.1.0, 1.0.1) and rails 2.3.4 or 2.3.5 results in to
Missing the Rails 2.3.4 gem. Please
gem install -v=2.3.4 rails, update your RAILS_GEM_VERSION setting in config/environment.rb for the Rails version you do have installed, or comment out RAILS_GEM_VERSION to use the latest version installed.
[Jan 12, 2010 10:18:20 AM] exitfrom /Users/vivek/dev/rails/bookstore/config/boot.rb:38:in `run' from /Users/vivek/dev/rails/bookstore/config/boot.rb:11:in `boot!'Reverting to rack 1.0.1 works just fine.
-
Matt Jones
There's also an issue where the gemspec specifies '~> 1.0.0', but the code actually calls
gem 'rack'with a version of 1.0.1, meaning that installing 2.3.5 over 2.3.2 won't install a new Rack, but will fail. Ticket is #3558 Actionpack 2.3.5 gemspec and Rack requirement don't match - the fix for this will probably cover that as well. -
eveel
When I've uninstalled
rack 1.1.0, everything began to work fine.Thanks, but this issue will be resolved, isn't it? :)
-
Maximilian Schulz
Is there any update on the topic? I am just curious, because I would love to install a rails 3 beta application on the same server and it requires rack 1.1.0
So right now I am not able to deploy the app as long as I still have any rails 2.3.5 apps running.
-
Mihai Târnovan
'~> 1.0.0' means latest 1.0.x gem. So it would pick up 1.0.2 for example, but not 1.1.x
-
Jimmy
Hi eveel,
How to uninstall rack 1.1.0?
Thanks -
bct
- Tag changed from rack to actionpack, action_controller, rack
I had the same problem as the original posters. Following information in this ticket, I found another workaround besides reverting to rack 1.0.1.
In actionpack-2.3.5.gemspec, i changed every occurrence of a rack dependency declaration from "~> 1.0.0" to ">= 1.0.0" (there were 3 changes in the file, example...
s.add_dependency(%q<rack>, ["~> 1.0.0"])changed to...
s.add_dependency(%q<rack>, [">= 1.0.0"]))
Also changed the code in actionpack (lib/action_controller.rb) and commented out line 34...
gem 'rack', '>= 1.0.1'
The very next line just requires rack anyway (require 'rack'). Those changes fixed the problem and I was able to start an app with 'thin start' again.
I'm using version 2.3.5 rails, 1.2.6 thin. I didn't do ANY testing, so I'm sure I've broken several cardinal rules with this fix, but I got sick uninstalling rack everytime I do a gem update when this seems like such a simple (conceptually at least) problem to fix.
-
Yehuda Katz (wycats)
- State changed from new to invalid
- Tag changed from actionpack, action_controller, rack to actionpack, action_controller, bundler, rack, rubygems
- Milestone cleared.
This problem is due to the way Rubygems activates dependencies. The easiest solution to this problem is to use bundler, which will determine the correct gems that you need, and only pull in those. This will guarantee that you won't have an activation error.
-
jashkenas
Yehuda: That's not a satisfactory answer. You can't "just use bundler" if you're working on a gem or library that depends on ActiveRecord, and is meant to be used from other apps. This effectively kills Sinatra/ActiveRecord combinations unless you're willing to either patch your gems or needlessly downgrade your Rack.
It would be great if you (Rails Core) could push out a 2.3.6 release of ActionPack and ActiveRecord that changes the fixed version
~> 1.0.0to>= 1.0.0. -
Chris Wise
I have a really dumb question. In my Rails install, where do I find the gemspec in order to make a change? I need Rack 1.1.0 because I believe it fixes some bugs with read_multipart but I am running into the same issue described here when trying to live with actionpack 2.3.5.
-
Chris Wise
Apologies. I see it's in the RAKEFILE.
-
ronin-95281 (at lighthouseapp)
Might I recommend that using bct's workaround posted on March 1, you should change the references to:
~> 1.0
... instead of:
= 1.0.0
This way it will allow any versions 1.x, but not any 2.x
This could avoid major headaches down the line when rack 2.x comes out long form now and we don't even remember configuring any of this nonsense in the first place.
Thoughts?
-A.
-
Kevin
Worked for me once I upgraded to rails 2.3.8. I'm using thin 1.2.7.
-
Chris Houhoulis
I used "ronin-95281 (at lighthouseapp)"'s advice, which built on bct's solution. Thanks!
I want to second jashkenas's response to Yehuda. Yehuda, that was not a friendly or correct comment. Unless I am missing something, the problem was a minor bug in Rails: three typos in the rails files that bct mentioned. The easiest and most direct solution was to fix the typos. Why is that an "invalid" bug report?
-
Alex Chaffee
- Assigned user set to Yehuda Katz (wycats)
Agreed. Fixing the three inaccurate dependency declarations in the gemspec did the trick for me. Yehuda, please reopen and reprioritize this bug, since (a) it's causing real pain for users, and (b) the declared dependency is just plain factually wrong: since actionpack works fine with rack 1.2, it should declare so.
For the record (and for Chris Wise), on my system this file:
/Library/Ruby/Gems/1.8/specifications/actionpack-2.3.8.gemspec
now ends like this:
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then s.add_runtime_dependency(%q<activesupport>, ["= 2.3.8"]) s.add_runtime_dependency(%q<rack>, ["~> 1.1"]) else s.add_dependency(%q<activesupport>, ["= 2.3.8"]) s.add_dependency(%q<rack>, ["~> 1.1"]) endelse
s.add_dependency(%q<activesupport>, ["= 2.3.8"]) s.add_dependency(%q<rack>, ["~> 1.1"])end end
The patch is a simple matter of changing "1.1.0" to "1.1"
-
tc
- No changes were found…
-
Alex Chaffee
Reported against ActionPack 2.3.8 at https://rails.lighthouseapp.com/projects/8994-ruby-on-rails/tickets...
-
Claus Lensbøl
I'm having the same issue after updating my gems.
The problem for me does not affect my production environment, however with the amount of rails 2.x applications in use right now, I don't think that this should be 3.0 fix only. -
travis (at appoxy)
- Tag set to replica, watches
I agree with the others, giving us the "use bundler" line is just wrong. Please reopen this ticket.
-
allsfashion
I'm having the same issue after updating my gems.please read this article www.5asale.com
