Bug #7568
closedYaml fails to encode zero date string.
Description
"0000-00-00 00:00:00".to_yaml fails with an ArgumentError.
Reproducing steps
In irb type,
require 'yaml'
"0000-00-00 00:00:00".to_yaml
What was expected
=> "--- '0000-00-00 00:00:00'\n"
What happened
ArgumentError: argument out of range
from /usr/local/rbenv/versions/1.9.3-p327/lib/ruby/1.9.1/psych/scalar_scanner.rb:111:in `utc'
Updated by Anonymous almost 12 years ago
- Status changed from Open to Assigned
- Assignee set to tenderlovemaking (Aaron Patterson)
=begin
This was fixed in r37288.
It might be worth backporting the fix to 1.9.3. Thoughts tenderlove?
=end
Updated by Anonymous almost 12 years ago
On Sun, Dec 16, 2012 at 12:53:14PM +0900, charliesome (Charlie Somerville) wrote:
Issue #7568 has been updated by charliesome (Charlie Somerville).
Status changed from Open to Assigned
Assignee set to tenderlovemaking (Aaron Patterson)=begin
This was fixed in r37288.It might be worth backporting the fix to 1.9.3. Thoughts tenderlove?
Ya, I can submit a backport ticket. I need to figure out which commits
should go in to a bugfix release of psych. The alternative is just to
release a new version of the gem, and we don't need to backport
anything.
--
Aaron Patterson
http://tenderlovemaking.com/
Updated by luislavena (Luis Lavena) almost 12 years ago
On Wed, Dec 19, 2012 at 3:06 PM, Aaron Patterson
tenderlove@ruby-lang.org wrote:
Ya, I can submit a backport ticket. I need to figure out which commits
should go in to a bugfix release of psych. The alternative is just to
release a new version of the gem, and we don't need to backport
anything.
The problem with that approach is on a new patchlevel release the user
will get "downgraded" to a previous version of the gem, where the
problem exists.
--
Luis Lavena
AREA 17
Perfection in design is achieved not when there is nothing more to add,
but rather when there is nothing more to take away.
Antoine de Saint-Exupéry
Updated by Anonymous almost 12 years ago
On Thu, Dec 20, 2012 at 11:40:10PM +0900, Luis Lavena wrote:
On Wed, Dec 19, 2012 at 3:06 PM, Aaron Patterson
tenderlove@ruby-lang.org wrote:Ya, I can submit a backport ticket. I need to figure out which commits
should go in to a bugfix release of psych. The alternative is just to
release a new version of the gem, and we don't need to backport
anything.The problem with that approach is on a new patchlevel release the user
will get "downgraded" to a previous version of the gem, where the
problem exists.
Good point. I'll figure out the appropriate backport requests. :-)
--
Aaron Patterson
http://tenderlovemaking.com/
Updated by tenderlovemaking (Aaron Patterson) almost 6 years ago
- Status changed from Assigned to Closed