Show
Ignore:
Timestamp:
04/12/03 18:58:28 (21 years ago)
Author:
jalet
Message:

The workaround for HP printers was not correct, and there's probably no
correct way to workaround the problem because we can't save the internal
page counter in real time. The last job's size is unconditionnally set to
5 pages in this case.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • pykota/trunk/bin/pykota

    r902 r908  
    2323# 
    2424# $Log$ 
     25# Revision 1.20  2003/04/12 16:58:28  jalet 
     26# The workaround for HP printers was not correct, and there's probably no 
     27# correct way to workaround the problem because we can't save the internal 
     28# page counter in real time. The last job's size is unconditionnally set to 
     29# 5 pages in this case. 
     30# 
    2531# Revision 1.19  2003/04/11 08:56:49  jalet 
    2632# Comment 
     
    213219                # its primary counter is only saved in a 10 increment, so 
    214220                # it may be lower than the last page counter saved in the 
    215                 # Quota Storage, we take the absolute value of the difference 
    216                 # this should take care of the "missing" pages. 
     221                # Quota Storage. We unconditionnally set 5 (five) pages 
     222                # as the last job's size. This is a mean. For more accurate 
     223                # accounting, don't switch off your HP printers ! 
    217224                # explanation at : http://web.mit.edu/source/third/lprng/doc/LPRng-HOWTO-15.html 
    218225                kotafilter.logger.log_message(_("Error in page count value %i for user %s on printer %s") % (jobsize, lastusername, kotafilter.printername), "error") 
    219                 jobsize = abs(jobsize) 
     226                jobsize = 5     # Workaround for HP printers' feature ! 
    220227                 
    221228            # update the quota for the previous user on this printer