[MacRuby] #1163: YAML datetime object with timezone seem to be parseable from mri/yarv but fails on macruby 0.8
MacRuby
ruby-noreply at macosforge.org
Mon Feb 21 12:36:24 PST 2011
#1163: YAML datetime object with timezone seem to be parseable from mri/yarv but
fails on macruby 0.8
-------------------------------+--------------------------------------------
Reporter: rff.rff@… | Owner: lsansonetti@…
Type: defect | Status: new
Priority: major | Milestone: MacRuby 0.8
Component: MacRuby | Keywords: yaml, datetime
-------------------------------+--------------------------------------------
the following YAML snippet
{{{
date: 2011-02-21 00:00:00 +01:00
}}}
is parsed properly by ruby 1.8.7, and 1.9.2
{{{
$ ruby -ryaml -e 'p YAML.load("date: 2011-02-21 00:00:00 +01:00")'
{"date"=>Mon Feb 21 00:00:00 +0100 2011}
}}}
but macruby fails to read it properly failing with a message "argument out
of range".
This seem related to this code im YAML.rb
{{{
def YAML.load(io)
parsr = LibYAML::Parser.new(io)
parsr.load
end
}}}
which seems to indicate the problem lies in the libyaml bindings. Since I
am currently unable to build macruby from source I can't tell if this is
still a problem in trunk.
I encountered this problem trying to install gems packaged on my box with
GMT+1 timezone, so this may be a relatively widespread issue.
--
Ticket URL: <http://www.macruby.org/trac/ticket/1163>
MacRuby <http://macruby.org/>
More information about the macruby-tickets
mailing list