Skip Menu |

This queue is for tickets about the GraphViz2 CPAN distribution.

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

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

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



Subject: GraphViz2::Parse::Regexp fails on Windows
The command line that GraphViz2::Parse::Regexp constructs is invalid on Windows and not tested for. I didn't attach a test file, as I couldn't figure out your test setup. The change necessary in the code is simple - eliminate the double quotes, which are used by the Windows toolset for argument quoting. Also, my change adds a warning when the system call fails. You might or might not want to connect this to your logging framework instead. my($stdout, $stderr) = capture{system($^X, '-e', qq|use re 'debug';qr/$regexp/;|) == 0 or warn "$? / $^E"};
Subject: Re: [rt.cpan.org #77869] GraphViz2::Parse::Regexp fails on Windows
Date: Mon, 18 Jun 2012 10:06:29 +1000
To: bug-GraphViz2 [...] rt.cpan.org
From: Ron Savage <ron [...] savage.net.au>
Hi Max On 18/06/12 03:26, Max Maischein via RT wrote: Show quoted text
> Sun Jun 17 13:26:39 2012: Request 77869 was acted upon. > Transaction: Ticket created by CORION > Queue: GraphViz2 > Subject: GraphViz2::Parse::Regexp fails on Windows > Broken in: 2.02 > Severity: Important > Owner: Nobody > Requestors: corion@cpan.org > Status: new > Ticket<URL: https://rt.cpan.org/Ticket/Display.html?id=77869> > > > The command line that GraphViz2::Parse::Regexp constructs is invalid on > Windows and not tested for. > > I didn't attach a test file, as I couldn't figure out your test setup. > The change necessary in the code is simple - eliminate the double > quotes, which are used by the Windows toolset for argument quoting. > Also, my change adds a warning when the system call fails. You might or > might not want to connect this to your logging framework instead. > > my($stdout, $stderr) = capture{system($^X, '-e', qq|use re > 'debug';qr/$regexp/;|) == 0 or warn "$? / $^E"};
Thanx for the report. I'm just build V 2.03 now for release to CPAN. As for testing, you could do (mutatis mutandis for Windows): 1) Show quoted text
shell> perl Build.PL shell> ./Build shell> ./Build test
Or, more easily: 2) Show quoted text
shell> copy html/parse.regexp.svg . shell> perl scripts/parse.regexp.pl
This defaults to SVG format, and defaults to outputting to html/parse.regexp.svg Show quoted text
shell> diff parse.regexp.svg html/parse.regexp.svg
Hopefully the 2 files are almost the same. I say almost because the underlying Graphviz has a frustrating habit of 'adjusting' the precise co-ords of plot points from run to run. So, best view the 2 images in a browser I guess. Cheers -- Ron Savage http://savage.net.au/ Ph: 0421 920 622
Subject: Re: [rt.cpan.org #77869] GraphViz2::Parse::Regexp fails on Windows
Date: Mon, 18 Jun 2012 17:48:02 +0200
To: bug-GraphViz2 [...] rt.cpan.org
From: Max Maischein <corion [...] cpan.org>
Hello Ron, Show quoted text
> Thanx for the report. I'm just build V 2.03 now for release to CPAN.
Thank you for the speedy release! Show quoted text
> As for testing, you could do (mutatis mutandis for Windows): > 1)
> shell> perl Build.PL > shell> ./Build > shell> ./Build test
> Or, more easily: > 2)
> shell> copy html/parse.regexp.svg . > shell> perl scripts/parse.regexp.pl
> This defaults to SVG format, and defaults to outputting to > html/parse.regexp.svg
> shell> diff parse.regexp.svg html/parse.regexp.svg
> Hopefully the 2 files are almost the same. I say almost because the > underlying Graphviz has a frustrating habit of 'adjusting' the precise > co-ords of plot points from run to run. So, best view the 2 images in a > browser I guess.
Yes, the two files are "almost" the same. They match visual inspection, but almost all of the numbers are different, likely owing to the different versions of the dot binaries involved. Thank you again for the quick fix, -max
Subject: Re: [rt.cpan.org #77869] GraphViz2::Parse::Regexp fails on Windows
Date: Tue, 19 Jun 2012 10:20:49 +1000
To: bug-GraphViz2 [...] rt.cpan.org
From: Ron Savage <ron [...] savage.net.au>
Hi Max On 19/06/12 01:48, Max Maischein via RT wrote: Show quoted text
> Queue: GraphViz2 > Ticket<URL: https://rt.cpan.org/Ticket/Display.html?id=77869> > > Hello Ron,
> > Thanx for the report. I'm just build V 2.03 now for release to CPAN.
> Thank you for the speedy release!
Always happy to hear from a happy customer, even if I'm not actually selling anything... Show quoted text
>> As for testing, you could do (mutatis mutandis for Windows): >> 1)
>> shell> perl Build.PL >> shell> ./Build >> shell> ./Build test
>> Or, more easily: >> 2)
>> shell> copy html/parse.regexp.svg . >> shell> perl scripts/parse.regexp.pl
>> This defaults to SVG format, and defaults to outputting to >> html/parse.regexp.svg
>> shell> diff parse.regexp.svg html/parse.regexp.svg
>> Hopefully the 2 files are almost the same. I say almost because the >> underlying Graphviz has a frustrating habit of 'adjusting' the precise >> co-ords of plot points from run to run. So, best view the 2 images in a >> browser I guess.
> > Yes, the two files are "almost" the same. They match visual inspection, > but almost all of the numbers are different, likely owing to the > different versions of the dot binaries involved.
It happens to me too, sometimes. Show quoted text
> Thank you again for the quick fix,
Happy plotting. I'll mark this 'bug' as resolved :-). -- Ron Savage http://savage.net.au/ Ph: 0421 920 622
Fixed in V 2.03.