Rubygems 0.9.5 Platform Bug

If you're building a gem using Rubygems 0.9.5, make sure you have this line in your spec (assuming it's a pure-Ruby gem):

  specification = Gem::Specification.new do |s|
    s.platform = Gem::Platform::RUBY

Without it, the platform gets omitted and the gem cannot be installed from 0.9.4 clients. The gem shows up like this in the gem list:

2. deep_test 1.0.3 ()
3. deep_test 1.0.2 (ruby)
4. deep_test 1.0.1 (ruby)

And then Rubygems tries to download the gem with an extra hyphen at the end of the filename:
http://gems.rubyforge.org/gems/deep_test-1.0.3-.gem

I logged a defect and posted a message to ruby-talk. I haven't had time to look into the code to submitt a patch (assuming this is undesired behavior).

This happened to the following gems, and they will fail installing with 0.9.4:

addressable 1.0.1
aquarium 0.2.0
astro-algo 0.0.1
aurora 0.0.1
contextr 0.1.9
csspool 0.2.3
dango 0.0.38
dango 0.0.39
dango 0.1.0
dango_generator 0.0.38
dango_generator 0.0.39
dango_generator 0.1.0
deep_test 1.0.3
diy 1.0.1
el_req 0.0.1
faker 0.1.0
faker 0.2.0
faker 0.2.1
flac2mp3 0.2.0
gchart 0.1.0
gemsonrails 0.7.1
googlebase 0.1.1
googlereader 0.0.3
guessmethod 0.2.0
heel 0.6.0
oauth 0.1.1
polyglot 0.1.0
publisher 1.1.0
random_data 1.2.0
random_data 1.2.1
rawdio 0.1.0
roo 0.7.0
ruby-libtommath 0.41.0
rutema 0.4.1
rutema 0.4.2
sapo 0.0.2
yelp 0.2.0
yelp 0.2.1
Hi, I'm Dan Manges, a software developer best known for being the founding CTO of Braintree. Send me an email.
blog comments powered by Disqus