Skip Menu |

This queue is for tickets about the GD-Sparkline CPAN distribution.

Report information
The Basics
Id: 46751
Status: resolved
Priority: 0/
Queue: GD-Sparkline

People
Owner: Nobody in particular
Requestors: tbruner [...] sandia.gov
Cc:
AdminCc:

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



Subject: Illegal division by zero at line 118
Date: Mon, 8 Jun 2009 15:07:19 -0600
To: "bug-GD-Sparkline [...] rt.cpan.org" <bug-GD-Sparkline [...] rt.cpan.org>
From: "Bruner, Todd" <tbruner [...] sandia.gov>
Hello: First thanks for writing GD::Sparkline. Calling code: my $spark = GD::Sparkline->new({ s => $sdata, l => "000000", a => "003366", b => "CCCCCC", }); Where $sdata is a string of comma separated numbers. Error message "Illegal division by zero at /usr/lib/perl5/site_perl/5.8.8/GD/Sparkline.pm line 118." Encountered when passed the following data: 4,4,4,4,4,4 Line 118 in your module calculates scale by dividing height by difference in y values ($dy). You need special case handling for when $max and $min are the same. Something like: my $diff = $max - $min; if ($diff == 0) { $min--; $max++; } Just prior to 118. -- Todd Bruner CEM Project Lead Sandia National Labs 505-844-9997 tbruner@sandia.gov
Subject: Re: [rt.cpan.org #46751] Illegal division by zero at line 118
Date: Tue, 9 Jun 2009 10:03:41 +0100
To: bug-GD-Sparkline [...] rt.cpan.org
From: Roger Pettett <rmp [...] psyphi.net>
Thanks Todd. Fix should be in in a few hours. I'd be interested to know if GD::Sparkline does everything you need. As I'm sure you've realised it's functionality is *very* basic, so let me know if it's not doing something you'd like it to. R. On 8 Jun 2009, at 22:08, Bruner, Todd via RT wrote: Show quoted text
> Mon Jun 08 17:08:07 2009: Request 46751 was acted upon. > Transaction: Ticket created by tbruner@sandia.gov > Queue: GD-Sparkline > Subject: Illegal division by zero at line 118 > Broken in: (no value) > Severity: (no value) > Owner: Nobody > Requestors: tbruner@sandia.gov > Status: new > Ticket <URL: http://rt.cpan.org/Ticket/Display.html?id=46751 > > > > Hello: > > First thanks for writing GD::Sparkline. > > Calling code: > > my $spark = GD::Sparkline->new({ > s => $sdata, > l => "000000", > a => "003366", > b => "CCCCCC", > }); > > Where $sdata is a string of comma separated numbers. > Error message "Illegal division by zero at /usr/lib/perl5/site_perl/ > 5.8.8/GD/Sparkline.pm line 118." > Encountered when passed the following data: > 4,4,4,4,4,4 > > Line 118 in your module calculates scale by dividing height by > difference in y values ($dy). You need special case handling for > when $max and $min are the same. > Something like: > > my $diff = $max - $min; > if ($diff == 0) { > $min--; > $max++; > } > > Just prior to 118. > > > > > -- > Todd Bruner > CEM Project Lead > Sandia National Labs > 505-844-9997 > tbruner@sandia.gov > > > Hello: > > First thanks for writing GD::Sparkline. > > Calling code: > > my $spark = GD::Sparkline->new({ > s => $sdata, > l => "000000", > a => "003366", > b => "CCCCCC", > }); > > Where $sdata is a string of comma separated numbers. > Error message “Illegal division by zero at /usr/lib/perl5/site_perl/ > 5.8.8/GD/Sparkline.pm line 118.” > Encountered when passed the following data: > 4,4,4,4,4,4 > > Line 118 in your module calculates scale by dividing height by > difference in y values ($dy). You need special case handling for > when $max and $min are the same. > Something like: > > my $diff = $max - $min; > if ($diff == 0) { > $min--; > $max++; > } > > Just prior to 118. > > > > > -- > Todd Bruner > CEM Project Lead > Sandia National Labs > 505-844-9997 > tbruner@sandia.gov >
Roger Pettett Web Application Architect --------------------------------------------- PsyPhi Network Web Solutions 2 Windmill Close, Great Dunmow, CM63AX, United Kingdom Tel: +44 (0)7715 740715 Email: rmp@psyphi.net Web: http://psyphi.net/ ---------------------------------------------

Message body is not shown because it is too large.

Should be fixed in 0.03 just uploaded to the CPAN.
Subject: Re: [rt.cpan.org #46751] Illegal division by zero at line 118
Date: Tue, 9 Jun 2009 13:26:13 -0600
To: "bug-GD-Sparkline [...] rt.cpan.org" <bug-GD-Sparkline [...] rt.cpan.org>
From: "Bruner, Todd" <tbruner [...] sandia.gov>
Roger: Thanks for the quick reply. GD::Sparkline does what I need, creating simple sparkline graphs...wasn't hard to adapt to my needs. One request would be to put in the ability to set a transparent background. Thanks, Todd On 6/9/09 3:04 AM, "Roger Pettett via RT" <bug-GD-Sparkline@rt.cpan.org> wrote: <URL: http://rt.cpan.org/Ticket/Display.html?id=46751 > Thanks Todd. Fix should be in in a few hours. I'd be interested to know if GD::Sparkline does everything you need. As I'm sure you've realised it's functionality is *very* basic, so let me know if it's not doing something you'd like it to. R. On 8 Jun 2009, at 22:08, Bruner, Todd via RT wrote: Show quoted text
> Mon Jun 08 17:08:07 2009: Request 46751 was acted upon. > Transaction: Ticket created by tbruner@sandia.gov > Queue: GD-Sparkline > Subject: Illegal division by zero at line 118 > Broken in: (no value) > Severity: (no value) > Owner: Nobody > Requestors: tbruner@sandia.gov > Status: new > Ticket <URL: http://rt.cpan.org/Ticket/Display.html?id=46751 > > > > Hello: > > First thanks for writing GD::Sparkline. > > Calling code: > > my $spark = GD::Sparkline->new({ > s => $sdata, > l => "000000", > a => "003366", > b => "CCCCCC", > }); > > Where $sdata is a string of comma separated numbers. > Error message "Illegal division by zero at /usr/lib/perl5/site_perl/ > 5.8.8/GD/Sparkline.pm line 118." > Encountered when passed the following data: > 4,4,4,4,4,4 > > Line 118 in your module calculates scale by dividing height by > difference in y values ($dy). You need special case handling for > when $max and $min are the same. > Something like: > > my $diff = $max - $min; > if ($diff == 0) { > $min--; > $max++; > } > > Just prior to 118. > > > > > -- > Todd Bruner > CEM Project Lead > Sandia National Labs > 505-844-9997 > tbruner@sandia.gov > > > Hello: > > First thanks for writing GD::Sparkline. > > Calling code: > > my $spark = GD::Sparkline->new({ > s => $sdata, > l => "000000", > a => "003366", > b => "CCCCCC", > }); > > Where $sdata is a string of comma separated numbers. > Error message "Illegal division by zero at /usr/lib/perl5/site_perl/ > 5.8.8/GD/Sparkline.pm line 118." > Encountered when passed the following data: > 4,4,4,4,4,4 > > Line 118 in your module calculates scale by dividing height by > difference in y values ($dy). You need special case handling for > when $max and $min are the same. > Something like: > > my $diff = $max - $min; > if ($diff == 0) { > $min--; > $max++; > } > > Just prior to 118. > > > > > -- > Todd Bruner > CEM Project Lead > Sandia National Labs > 505-844-9997 > tbruner@sandia.gov >
Roger Pettett Web Application Architect --------------------------------------------- PsyPhi Network Web Solutions 2 Windmill Close, Great Dunmow, CM63AX, United Kingdom Tel: +44 (0)7715 740715 Email: rmp@psyphi.net Web: http://psyphi.net/ --------------------------------------------- -- Todd Bruner CEM Project Lead Sandia National Labs 505-844-9997 tbruner@sandia.gov
Subject: Re: [rt.cpan.org #46751] Illegal division by zero at line 118
Date: Tue, 9 Jun 2009 20:57:20 +0100
To: bug-GD-Sparkline [...] rt.cpan.org
From: Roger Pettett <rmp [...] psyphi.net>
Good idea. b=transparent implemented in 0.04 just pushed to CPAN. R. On 9 Jun 2009, at 20:26, Bruner, Todd via RT wrote: Show quoted text
> Queue: GD-Sparkline > Ticket <URL: http://rt.cpan.org/Ticket/Display.html?id=46751 > > > Roger: > > Thanks for the quick reply. GD::Sparkline does what I need, > creating simple sparkline graphs...wasn't hard to adapt to my needs. > > One request would be to put in the ability to set a transparent > background. > > Thanks, > Todd > > > On 6/9/09 3:04 AM, "Roger Pettett via RT" <bug-GD-Sparkline@rt.cpan.org
> > wrote:
> > <URL: http://rt.cpan.org/Ticket/Display.html?id=46751 > > > Thanks Todd. Fix should be in in a few hours. > > I'd be interested to know if GD::Sparkline does everything you need. > As I'm sure you've realised it's functionality is *very* basic, so let > me know if it's not doing something you'd like it to. > > R. > > > On 8 Jun 2009, at 22:08, Bruner, Todd via RT wrote: >
>> Mon Jun 08 17:08:07 2009: Request 46751 was acted upon. >> Transaction: Ticket created by tbruner@sandia.gov >> Queue: GD-Sparkline >> Subject: Illegal division by zero at line 118 >> Broken in: (no value) >> Severity: (no value) >> Owner: Nobody >> Requestors: tbruner@sandia.gov >> Status: new >> Ticket <URL: http://rt.cpan.org/Ticket/Display.html?id=46751 > >> >> >> Hello: >> >> First thanks for writing GD::Sparkline. >> >> Calling code: >> >> my $spark = GD::Sparkline->new({ >> s => $sdata, >> l => "000000", >> a => "003366", >> b => "CCCCCC", >> }); >> >> Where $sdata is a string of comma separated numbers. >> Error message "Illegal division by zero at /usr/lib/perl5/site_perl/ >> 5.8.8/GD/Sparkline.pm line 118." >> Encountered when passed the following data: >> 4,4,4,4,4,4 >> >> Line 118 in your module calculates scale by dividing height by >> difference in y values ($dy). You need special case handling for >> when $max and $min are the same. >> Something like: >> >> my $diff = $max - $min; >> if ($diff == 0) { >> $min--; >> $max++; >> } >> >> Just prior to 118. >> >> >> >> >> -- >> Todd Bruner >> CEM Project Lead >> Sandia National Labs >> 505-844-9997 >> tbruner@sandia.gov >> >> >> Hello: >> >> First thanks for writing GD::Sparkline. >> >> Calling code: >> >> my $spark = GD::Sparkline->new({ >> s => $sdata, >> l => "000000", >> a => "003366", >> b => "CCCCCC", >> }); >> >> Where $sdata is a string of comma separated numbers. >> Error message "Illegal division by zero at /usr/lib/perl5/site_perl/ >> 5.8.8/GD/Sparkline.pm line 118." >> Encountered when passed the following data: >> 4,4,4,4,4,4 >> >> Line 118 in your module calculates scale by dividing height by >> difference in y values ($dy). You need special case handling for >> when $max and $min are the same. >> Something like: >> >> my $diff = $max - $min; >> if ($diff == 0) { >> $min--; >> $max++; >> } >> >> Just prior to 118. >> >> >> >> >> -- >> Todd Bruner >> CEM Project Lead >> Sandia National Labs >> 505-844-9997 >> tbruner@sandia.gov >>
> > Roger Pettett > Web Application Architect > --------------------------------------------- > PsyPhi Network Web Solutions > 2 Windmill Close, > Great Dunmow, CM63AX, United Kingdom > Tel: +44 (0)7715 740715 > Email: rmp@psyphi.net > Web: http://psyphi.net/ > --------------------------------------------- > > > > > > > -- > Todd Bruner > CEM Project Lead > Sandia National Labs > 505-844-9997 > tbruner@sandia.gov > > > Roger: > > Thanks for the quick reply. GD::Sparkline does what I need, > creating simple sparkline graphs...wasn’t hard to adapt to my needs. > > One request would be to put in the ability to set a transparent > background. > > Thanks, > Todd > > > On 6/9/09 3:04 AM, "Roger Pettett via RT" <bug-GD-Sparkline@rt.cpan.org
> > wrote:
> > <URL: http://rt.cpan.org/Ticket/Display.html?id=46751 > > > Thanks Todd. Fix should be in in a few hours. > > I'd be interested to know if GD::Sparkline does everything you need. > As I'm sure you've realised it's functionality is *very* basic, so let > me know if it's not doing something you'd like it to. > > R. > > > On 8 Jun 2009, at 22:08, Bruner, Todd via RT wrote: >
> > Mon Jun 08 17:08:07 2009: Request 46751 was acted upon. > > Transaction: Ticket created by tbruner@sandia.gov > > Queue: GD-Sparkline > > Subject: Illegal division by zero at line 118 > > Broken in: (no value) > > Severity: (no value) > > Owner: Nobody > > Requestors: tbruner@sandia.gov > > Status: new > > Ticket <URL: http://rt.cpan.org/Ticket/Display.html?id=46751 > > > > > > > Hello: > > > > First thanks for writing GD::Sparkline. > > > > Calling code: > > > > my $spark = GD::Sparkline->new({ > > s => $sdata, > > l => "000000", > > a => "003366", > > b => "CCCCCC", > > }); > > > > Where $sdata is a string of comma separated numbers. > > Error message "Illegal division by zero at /usr/lib/perl5/site_perl/ > > 5.8.8/GD/Sparkline.pm line 118." > > Encountered when passed the following data: > > 4,4,4,4,4,4 > > > > Line 118 in your module calculates scale by dividing height by > > difference in y values ($dy). You need special case handling for > > when $max and $min are the same. > > Something like: > > > > my $diff = $max - $min; > > if ($diff == 0) { > > $min--; > > $max++; > > } > > > > Just prior to 118. > > > > > > > > > > -- > > Todd Bruner > > CEM Project Lead > > Sandia National Labs > > 505-844-9997 > > tbruner@sandia.gov > > > > > > Hello: > > > > First thanks for writing GD::Sparkline. > > > > Calling code: > > > > my $spark = GD::Sparkline->new({ > > s => $sdata, > > l => "000000", > > a => "003366", > > b => "CCCCCC", > > }); > > > > Where $sdata is a string of comma separated numbers. > > Error message “Illegal division by zero at /usr/lib/perl5/site_perl/ > > 5.8.8/GD/Sparkline.pm line 118.” > > Encountered when passed the following data: > > 4,4,4,4,4,4 > > > > Line 118 in your module calculates scale by dividing height by > > difference in y values ($dy). You need special case handling for > > when $max and $min are the same. > > Something like: > > > > my $diff = $max - $min; > > if ($diff == 0) { > > $min--; > > $max++; > > } > > > > Just prior to 118. > > > > > > > > > > -- > > Todd Bruner > > CEM Project Lead > > Sandia National Labs > > 505-844-9997 > > tbruner@sandia.gov > >
> > Roger Pettett > Web Application Architect > --------------------------------------------- > PsyPhi Network Web Solutions > 2 Windmill Close, > Great Dunmow, CM63AX, United Kingdom > Tel: +44 (0)7715 740715 > Email: rmp@psyphi.net > Web: http://psyphi.net/ > --------------------------------------------- > > > > > > > -- > Todd Bruner > CEM Project Lead > Sandia National Labs > 505-844-9997 > tbruner@sandia.gov >
Roger Pettett Web Application Architect --------------------------------------------- PsyPhi Network Web Solutions 2 Windmill Close, Great Dunmow, CM63AX, United Kingdom Tel: +44 (0)7715 740715 Email: rmp@psyphi.net Web: http://psyphi.net/ ---------------------------------------------

Message body is not shown because it is too large.