Bugs item #26958, was opened at 2009-08-19 22:18
You can respond by visiting: 
http://rubyforge.org/tracker/?func=detail&atid=575&aid=26958&group_id=126

Category: None
Group: None
Status: Open
Resolution: None
Priority: 3
Submitted By: Simon Chiang (prosperity)
Assigned to: Nobody (None)
Summary: Gem::Specification.hash can cause to_yaml RangeError

Initial Comment:
Array.hash for objects do not produce a Fixnum hash will blow up. 
Gem::Specification often produces a Bignum and this prevents an array of 
specifications from being converted to YAML.

This issue (which is really a ruby issue) will be fixed in a future release but 
I thought you might like to know in case you wanted to patch RubyGems for 
versions prior to the fix.

(see http://redmine.ruby-lang.org/issues/show/1883)

==========================
RubyGems Environment:
  - RUBYGEMS VERSION: 1.3.1
  - RUBY VERSION: 1.8.6 (2008-08-11 patchlevel 287) [universal-darwin9.0]
  - INSTALLATION DIRECTORY: /Library/Ruby/Gems/1.8
  - RUBY EXECUTABLE: 
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby
  - EXECUTABLE DIRECTORY: /usr/bin
  - RUBYGEMS PLATFORMS:
    - ruby
    - universal-darwin-9
  - GEM PATHS:
     - /Library/Ruby/Gems/1.8
     - /Users/simonchiang/.gem/ruby/1.8
     - 
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/gems/1.8
  - GEM CONFIGURATION:
     - :update_sources => true
     - :verbose => true
     - :benchmark => false
     - :backtrace => false
     - :bulk_threshold => 1000
     - :sources => ["http://gems.rubyforge.org/";, "http://gems.github.com";]
  - REMOTE SOURCES:
     - http://gems.rubyforge.org/
     - http://gems.github.com


----------------------------------------------------------------------

>Comment By: Eric Hodel (drbrain)
Date: 2009-08-20 13:48

Message:
Why are you converting specs to YAML in the first place?

----------------------------------------------------------------------

Comment By: Chad Woolley (thewoolleyman)
Date: 2009-08-20 10:55

Message:
This looks reasonable and is reproducible, but I'm not sure what is dependent 
upon the current implementation of hash.  Maybe someone else can weigh in...

Regardless, can you please submit this as a proper patch, with your failing 
tests added to the appropriate file (test_gem_specification.rb) - and, of 
course, ensure nothing else in the test suite breaks?

Thanks,
-- Chad

----------------------------------------------------------------------

You can respond by visiting: 
http://rubyforge.org/tracker/?func=detail&atid=575&aid=26958&group_id=126
_______________________________________________
Rubygems-developers mailing list
http://rubyforge.org/projects/rubygems
Rubygems-developers@rubyforge.org
http://rubyforge.org/mailman/listinfo/rubygems-developers

Reply via email to