Bug #3671

DateTime dumped by Marshal from ruby 1.8 cannot be loaded by ruby 1.9

Added by Eric Hodel over 5 years ago. Updated over 4 years ago.

Assignee:tadayoshi funaba
ruby -v:ruby 1.9.3dev (2010-07-07 trunk 28561) [x86_64-darwin10.4.0] Backport:


$ ruby -rdate -e 'Marshal.dump DateTime.now, $stdout' | ruby19 -rdate -e 'p Marshal.load $stdin.read'
-e:1:in load': class DateTime needs to have method_load' (TypeError)
from -e:1:in `'

$ ruby -v
ruby 1.8.7 (2009-06-12 patchlevel 174) [universal-darwin10.0]
$ ruby19 -v
ruby 1.9.3dev (2010-07-07 trunk 28561) [x86_64-darwin10.4.0]

Ruby 1.9 should implement DateTime._load in order to load from older versions


#1 Updated by Yui NARUSE over 5 years ago

  • Assignee set to tadayoshi funaba
  • Target version set to 2.0.0



#2 Updated by tadayoshi funaba over 5 years ago

  • Status changed from Open to Rejected

this is not a matter of date.
rational or ruby.

$ /usr/local/bin/ruby -rrational -e 'Marshal.dump Rational(1,2), $stdout' | ./ruby -rrational -e 'p Marshal.load $stdin.read'
-e:1:in load': dump format error (ArgumentError)
from -e:1:in


Also available in: Atom PDF