Skip Menu |

This queue is for tickets about the YAML-Syck CPAN distribution.

Report information
The Basics
Id: 32120
Status: resolved
Priority: 0/
Queue: YAML-Syck

People
Owner: Nobody in particular
Requestors: agentzh [...] yahoo.cn
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 1.00
Fixed in: (no value)



Subject: JSON::Syck: Extra spaces in single-quoted URLs
Hi, there~ It's common that users use single quoted literals in their JSON inputs. When they put URLs, JSON::Syck introduced extra spaces in the values. Here's the test file that exercise the bug: use strict; use warnings; use Test::More tests => 2; use JSON::Syck 'Load'; my $url = 'http://www.pugscode.org'; my $var = Load(<<_EOC_); { url: '$url' } _EOC_ ok $var, "JSON load OK"; is $var->{url}, $url, "no extra space in the URL"; Here's the output on my machine (perl 5.8.8, YAML-Syck 1.00, ubuntu 7.10): 1..2 ok 1 - JSON load OK not ok 2 - no extra space in the URL # Failed test 'no extra space in the URL' # at t.t line 12. # got: 'http: //www.pugscode.org' # expected: 'http://www.pugscode.org' # Looks like you failed 1 test of 2. IMHO, JSON::Syck should 1. croak on single-quoted JSON literals or 2. support single-quoted literals *fully* ;) Thanks! -agentzh
Thanks, resolved in YAML::Syck 1.02.