Division by zero in innreport
Petr Novopashenniy
pety at rusnet.ru
Wed Jan 18 14:36:26 UTC 2012
Good day, Julien!
On Tue, 17 Jan 2012, Julien ?LIE wrote:
JL> Hi Petr,
JL>
JL> > The line for "Mar 1 00:00:00 -- Feb 29 23:59:59" looks very suspicious.
JL> > goblin2 and goblin3 were not active in 2007 so I can check only on
JL> > goblin1.
JL>
JL> At second glance, they were!
JL>
JL>
JL> > I would suggest to remove the line for "Mar 1 00:00:00 -- Feb 29 23:59:59"
JL> > in innreport.db to fix the problem.
JL> > Maybe it has been generated by a previous version of innreport that had a
JL> > bug;
JL> > yet, it seems strange that it occurred in 2007 (a non-leap year)!!
JL>
JL> Looking at up your reports, I see the following weird dates:
JL>
JL> - goblin1 :
JL> change of year 2007-2008 -> Jan 1 00:00:00 -- Dec 31 23:59:59
JL> 2007 -> Mar 1 00:00:00 -- Feb 29 23:59:59
JL> change of year 2006-2007 -> Jan 1 00:00:00 -- Dec 31 23:59:59
JL>
JL> - goblin2 :
JL> change of year 2010-2011 -> Jan 1 00:00:00 -- Dec 31 23:59:59
JL> change of year 2009-2010 -> Jan 1 00:00:00 -- Dec 31 23:59:59
JL> change of year 2008-2009 -> Jan 1 00:00:00 -- Dec 31 23:59:59
JL> change of year 2007-2008 -> Jan 1 00:00:00 -- Dec 31 23:59:59
JL> change of year 2006-2007 -> Jan 1 00:00:00 -- Dec 31 23:59:59
JL> 2007 -> Mar 1 00:00:00 -- Feb 29 23:59:59
JL> change of year 2006-2007 -> Jan 1 00:00:00 -- Dec 31 23:59:59
JL>
JL> - goblin3 :
JL> change of year 2010-2011 -> Jan 1 00:00:00 -- Dec 31 23:59:59
JL> change of year 2009-2010 -> Jan 1 00:00:00 -- Dec 31 23:59:59
JL> change of year 2008-2009 -> Jan 1 00:00:00 -- Dec 31 23:59:59
JL> change of year 2007-2008 -> Jan 1 00:00:00 -- Dec 31 23:59:59
JL>
JL>
JL> It looks like that INN was upgraded to a newer version in 2008 for goblin1
JL> and in 2011 for goblin2 & goblin3.
JL> Do you confirm?
I upgrade INN (to INN 2.5.0 (20090414 snapshot)) in March-April 2009 for
goblin1, and never upgrade goblin2 (2.4.3) and goblin3 (2.4.5).
For goblin1, INN 2.4.3 is first install, and upgrade to 2.4.6 in March
2009.
JL> As for innreport for INN 2.5.3, what would be the best behaviour?
JL> Maybe checking the validity of a date before using it and not process the
JL> line if the date is not coherent? Should such lines be automatically
JL> removed from innreport.db?
Perhaps, this is a good solution!
--pety
More information about the inn-workers
mailing list