fgallery broken which might be caused by bug in libjson-xs-perl

Andreas Tille tille at debian.org
Sun Jun 24 12:33:23 BST 2018


Hi,

it took a long time to assemble some simple debug info but finally I got
bored to pin the working libjson-xs-perl version 3.010.  The issue
persists in 3.040 in Debian.  To give a short summary:  The Debian
packaged fgallery works with libjson-xs-perl.  However, I have patched
fgallery to gain some additional functionality - thus I've added the
complete script to the tarball[1] that contains a minimum test.  If you
run the test script run_me it creates a log file named according to the
installed libjson-xs-perl package.  It succeeds with libjson-xs-perl
version < 3.020 and fails for 3.020 >= (including current version
3.040).

The failure is in all versions

  hash- or arrayref expected (not a simple scalar, use allow_nonref to allow this) at ./fgallery line 875.

but I have no idea how to fix this. :-(

Any help would be welcome

       Andreas.

[1] https://people.debian.org/~tille/debug_libjson-xs-perl/debug_libjson-xs-perl.tgz

On Fri, Oct 07, 2016 at 10:47:49AM +0300, Niko Tyni wrote:
> On Fri, Oct 07, 2016 at 09:25:38AM +0200, Andreas Tille wrote:
> 
> > This is the situation: I'm using a Git commit from fgallery with extra
> > features I've added locally.  So this is a bad test case for somebody
> > else since it derives from the official Debian package.  This fgallery
> > is unchanged since three monthes and
> > 
> >   1. worked until 16. September under testing
> >   2. stopped working after my upgrade yesterday to libjson-xs-perl
> >      3.020-1+b1
> >   3. works again with libjson-xs-perl 3.010-2 (which I needed to
> >      rebuild since the binary deb on snapshots requires an older
> >      perl version
> > 
> > The failure is identical to what is described here:
> > 
> >    https://stackoverflow.com/questions/33738849/strange-behavior-of-a-tied-hash-in-perl-when-asking-for-an-arrayref
> >    https://rt.cpan.org/Ticket/Display.html?id=109026
> > 
> > and may be these links lead to an easily reproducible example.
> 
> Those discuss encoding a special 'magical' variable.
> I don't think that ever worked.
> 
> The same error message can be triggered by other means.
> There's this in 3.02 changelog:
> 
>     - allow_nonref now affects booleans (\1, $Types::Serialiser::Boolean)
>           as well (reported by Alex Efros).
> 
> and from that I can construct a test case that has intentionally changed
> behaviour recently, now giving the same error message.
> 
> # perl -MJSON=encode_json -le '$x=1; print encode_json(\$x)'
> 
> > > > If needed I can try to create a simple test case.
> > > 
> > > That would be helpful in case you come to the conclusion there's
> > > really a problem in one of the packages in the archive.
> > 
> > I have some backlog from holidays but I'll try to do my best
> > if the hints above are not sufficient.
> 
> Please do, too much guesswork at the moment.
> -- 
> Niko Tyni   ntyni at debian.org
> 

-- 
http://fam-tille.de



More information about the pkg-perl-maintainers mailing list