Join GitHub today
GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
psych parses ":"-delimited time strings differently than syck #153
I'm not sure if this is a bug or changed behavior, perhaps I could get some clarification or resolution via this issue:
colon-delimited strings of integers are parsed by YAML into integer number of seconds. it appears that the psych engine treats the last unit as minutes, whereas syck treated it as seconds, ie.:
#1.9.3 ruby-1.9.3-p392>> require 'yaml' => true ruby-1.9.3-p392>> YAML.load '1:00' => 3600 ruby-1.9.3-p392>> YAML::ENGINE.yamler = 'syck' => "syck" ruby-1.9.3-p392>> YAML.load '1:00' => 60 #2.0.0 ruby-2.0.0-p195>> require 'yaml' => true ruby-2.0.0-p195>> YAML.load '1:00' => 3600
if this change of behavior is documented somewhere, I'd appreciate if you could point me to it.
This comment has been minimized.
This comment has been minimized.Show comment Hide comment
Hrm. I'm not sure what to do about this. I believe this is a bug in the base 60 support. I don't think the behavior should have changed. I must dig further.