Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the YAML CPAN distribution.

Report information
The Basics
Id: 17589
Status: resolved
Priority: 0/
Queue: YAML

People
Owner: Nobody in particular
Requestors: michael [...] ndrix.org
Cc:
AdminCc:

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



Subject: ysh dies when reading from STDIN
Executing the following command ysh < some.yml results in this error Can't use string ("YAML::Load") as a subroutine ref while "strict refs" in use at /usr/bin/ysh line 240 The following patch fixes the problem 239a240 Show quoted text
> no strict 'refs';
From: mndrix [...] cpan.org
Show quoted text
> 239a240
> > no strict 'refs';
I've attached a unified diff. That's perhaps a bit more useful.
--- /tmp/old-ysh 2006-02-11 07:25:33.000000000 -0700 +++ /usr/bin/ysh 2006-02-11 07:25:38.000000000 -0700 @@ -237,6 +237,7 @@ if (length($stream)) { my @objects; + no strict 'refs'; eval { @objects = &{"${yaml_module}::Load"}($stream) }; if ($@) { print STDERR $@;
RT-Send-CC: ewilhelm [...] cpan.org
On Sat Feb 11 09:30:45 2006, MNDRIX wrote: Show quoted text
> > 239a240
> > > no strict 'refs';
> > I've attached a unified diff. That's perhaps a bit more useful.
I can confirm this. The patch is exactly what I have done.
This issue has been copied to: https://github.com/ingydotnet/yaml-pm/issues/56 please take all future correspondence there. This ticket will remain open but please do not reply here. This ticket will be closed when the github issue is dealt with.
On Sat Feb 11 15:27:33 2006, guest wrote: Show quoted text
> Executing the following command > > ysh < some.yml > > results in this error > > Can't use string ("YAML::Load") as a subroutine ref > while "strict refs" in use at /usr/bin/ysh line 240 > > The following patch fixes the problem > > 239a240
> > no strict 'refs';
This seems to have been fixed a while ago. Looking into git, I see `no strict 'refs'` there in YAML/Shell.pm but the history only goes back to 2008.