Skip Menu |

This queue is for tickets about the GraphViz2 CPAN distribution.

Report information
The Basics
Id: 87525
Status: resolved
Priority: 0/
Queue: GraphViz2

People
Owner: Nobody in particular
Requestors: KENTNL [...] cpan.org
Cc:
AdminCc:

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



Subject: Malformed UTF-8 character (unexpected non-continuation byte 0x00, immediately after start byte 0xff) in print
Malformed UTF-8 character (unexpected non-continuation byte 0x00, immediately after start byte 0xff) in print at /home/kent/perl5/perlbrew/perls/perl-5.18.0/lib/site_perl/5.18.0/GraphViz2.pm line 664.

Add Carp::Always:

Malformed UTF-8 character (unexpected non-continuation byte 0x00, immediately after start byte 0xff) in print at /home/kent/perl5/perlbrew/perls/perl-5.18.0/lib/site_perl/5.18.0/GraphViz2.pm line 664.
    GraphViz2::try {...} () called at /home/kent/perl5/perlbrew/perls/perl-5.18.0/lib/site_perl/5.18.0/Try/Tiny.pm line 81
    eval {...} called at /home/kent/perl5/perlbrew/perls/perl-5.18.0/lib/site_perl/5.18.0/Try/Tiny.pm line 72
    Try::Tiny::try('CODE(0x2782640)', 'Try::Tiny::Catch=REF(0x2782be0)') called at /home/kent/perl5/perlbrew/perls/perl-5.18.0/lib/site_perl/5.18.0/GraphViz2.pm line 673
    GraphViz2::run('GraphViz2=HASH(0x1980ef8)', 'driver', 'dot', 'format', 'png', 'output_file', 'layout/self_structure.png', 'verbose', 1, ...) called at /home/kent/perl5/perlbrew/perls/perl-5.18.0/lib/site_perl/5.18.0/GraphViz2.pm line 675.
    GraphViz2::run('GraphViz2=HASH(0x1980ef8)', 'driver', 'dot', 'format', 'png', 'output_file', 'layout/self_structure.png', 'verbose', 1, ...) called at /home/kent/bin/self_structure_2.pl line 261


I suspect its trying to handle a PNG Image bytestream under the assumption its UTF8.

If I remove the call I make to $g->run( ... format => png => ... )

Then it stops failing.

Additionally, if I generate the image from the canonicalized dot file manually:

xxd png..png  | grep ff00
0000020: 1500 0000 0662 4b47 4400 ff00 ff00 ffa0  .....bKGD.......   <--- suspect bytes found
000ff00: 86ec 17f6 f54e 2a8e 9d06 7f8a 8cb4 e4f5  .....N*.........
0015680: ff00 0000 0025 8499 3300 2a14 634c f685  .....%..3.*.cL..

And if I simply change the format to a non-binary file output type, ie: svg, that also makes the problem go away.

Subject: Re: [rt.cpan.org #87525] Malformed UTF-8 character (unexpected non-continuation byte 0x00, immediately after start byte 0xff) in print
Date: Fri, 02 Aug 2013 08:59:35 +1000
To: bug-GraphViz2 [...] rt.cpan.org
From: Ron Savage <ron [...] savage.net.au>
Hi Kent On 02/08/13 04:06, Kent Fredric via RT wrote: Show quoted text
> Thu Aug 01 14:06:08 2013: Request 87525 was acted upon.
Thanx for the report. Running scripts/generate.png.sh which ships with the distro generates the problem for all test files scripts/*.pl. So, now I have something to work on. -- Ron Savage http://savage.net.au/ Ph: 0421 920 622
Fix in V 2.16.