Skip Menu | will be shut down on March 1st, 2021.

This queue is for tickets about the AnyData CPAN distribution.

Report information
The Basics
Id: 5859
Status: resolved
Priority: 0/
Queue: AnyData

Owner: JZUCKER [...]
Requestors: wright [...]

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

Date: Wed, 31 Mar 2004 13:32:28 -0500 (EST)
From: Dan Wright <wright [...]>
To: bug-AnyData [...]
Subject: AnyData bug?
Download (untitled) / with headers
text/plain 1.1k
Jeff, I'm looking at the source code for and I'm really confused about the adConvert sub. It looks like it is calling get_undeleted_record, and expecting an arrayref back, but I don't think you are guaranteed to get an arrayref back. In fact, I'm sure you aren't. Here's an example failure case: % cat example1.csv name,expires,nameserver,17-aug-2012,NS1.PAIR.COM,15-jun-2008,NS0.NS0.COM,21-Aug-2005,NS.DEVELOOPER.COM,10-sep-2006,NS1.EASYDNS.COM,31-mar-2005,NS1.PAIRNIC.COM wright@pit24% perl -MAnyData -e "adConvert( 'CSV', 'example1.csv', 'HTMLtable', 'example1.html')" Can't use string (",17-aug-2012,NS1.PAIR.CO") as an ARRAY ref while "strict refs" in use at /usr/local/lib/perl5/site_perl/5.6.1/ line 657, <GEN0> line 2. In order to make this work, I think you need to copy over some code that you are using in fetch_row(). Here's the diff for AnyData 0.08: 366c366,370 < return $rec; --- Show quoted text
> return $rec if ref $rec eq 'ARRAY'; > return unless $rec; > my @fields = $self->{parser}->read_fields($rec); > return undef if scalar @fields == 1 and !defined $fields[0]; > return \@fields;
Download (untitled) / with headers
text/plain 128b
Thanks much for the patch. I applied it only slightly modified. The problem should be fixed in AnyData 0.09. Thanks! -- Jeff

This service is sponsored and maintained by Best Practical Solutions and runs on infrastructure.

Please report any issues with to