This project is archived and is in readonly mode.
Rails incorrectly imposes version number as last part of gem directory name
Reported by Chris Ochs | March 29th, 2010 @ 07:05 PM | in 2.3.10
Rails requires that gems have a number as the last part of the filename, so many windows gems can't be frozen since the platform string is the last part of the gem name (and directory name)
version_for_dir in VendorGemSourceIndex makes this assumption,
as does from_directory_name in GemDependency.
The monkey patch is kind of a pain, as you have to load the patch from two different places in boot.rb.
Comments and changes to this ticket
-
Yehuda Katz (wycats) March 29th, 2010 @ 07:22 PM
- Milestone set to 2.3.6
-
Colin Casey May 17th, 2010 @ 03:05 AM
- Tag changed from bugmash to bugmash, bugmash-patch, bugmash-review
Also, I've attached a patch. This patch contains both the test case and the fix so the above patch is unnecessary.
-
Ben Oakes May 26th, 2010 @ 07:46 PM
I'm having the same problem, but it took me a little while to find this ticket. The error message I'm getting is:
Malformed version number string mswin32 (ArgumentError)
Hopefully that makes the ticket easier to search for. :) I had also written up steps to reproduce the bug, which I'm including just for reference:
rails gem_bug_sandbox cd gem_bug_sandbox vim config\environment.rb # # Add a gem with native extensions, such as nokogiri 1.4.2: # config.gem 'nokogiri', :version => '1.4.2' rake gems:install rake gems:unpack
To get the error message:
ruby script\server => Booting WEBrick => Rails 2.3.5 application starting on http://0.0.0.0:3000 C:/Ruby/lib/ruby/site_ruby/1.8/rubygems/version.rb:107:in `initialize': Malformed version number string mswin32 (ArgumentError)
In the meantime, I'm just not unpacking the problem gems. It's not ideal, but it works.
-
Rizwan Reza June 13th, 2010 @ 08:16 PM
- Tag changed from bugmash, bugmash-patch, bugmash-review to bugmash-review
- State changed from new to verified
-
Jeremy Kemper August 30th, 2010 @ 02:28 AM
- Milestone changed from 2.3.9 to 2.3.10
- Importance changed from to Low
-
David Trasbo September 23rd, 2010 @ 10:52 AM
- Assigned user set to José Valim
This patch should really be applied. Perhaps mr. Valim will take care of it?
-
Repository September 24th, 2010 @ 12:18 PM
- State changed from verified to resolved
(from [f2990620d716146064d9d2f88ac487025d4b031a]) Test for imposed version number as last part of gem directory name for frozen gems
[#4295 state:resolved]
Signed-off-by: José Valim jose.valim@gmail.com
http://github.com/rails/rails/commit/f2990620d716146064d9d2f88ac487... -
Ben Oakes September 30th, 2010 @ 12:02 PM
Just curious: how relevant is this ticket with Bundler now being the new hotness? (Does the fix mainly affect Rails 2?)
-
David Trasbo September 30th, 2010 @ 03:51 PM
Ben,
Actually this change exclusively affects Rails 2.3.x. Rails 2 is maintained even now when Rails 3 is out.
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile »
<h2 style="font-size: 14px">Tickets have moved to Github</h2>
The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>
People watching this ticket
Attachments
Tags
Referenced by
- 4295 Rails incorrectly imposes version number as last part of gem directory name [#4295 state:resolved]