Changeset 3458

Show
Ignore:
Timestamp:
11/25/08 00:48:28 (14 years ago)
Author:
jerome
Message:

Exports some environment variables much earlier so that the preaccounter
can use them. Fixes #32.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • pykota/trunk/bin/cupspykota

    r3446 r3458  
    224224        # the environment before launching the real backend 
    225225        self.logdebug("Initializing backend...") 
    226  
     226        self.softwareJobSize = None 
    227227        if not self.checkCUPSVersion() : 
    228228            self.printInfo("BEWARE : CUPS is too old. You should use CUPS v1.3.4 or higher.", "error") 
     
    13281328                    raise KeyboardInterrupt 
    13291329                wrapper.saveDatasAndCheckSum() 
     1330                wrapper.exportJobInfo() # exports a first time to give hints to external scripts 
    13301331                wrapper.preaccounter = openAccounter(wrapper, ispreaccounter=1) 
    13311332                wrapper.accounter = openAccounter(wrapper) 
    13321333                wrapper.precomputeJobSize() 
    1333                 wrapper.exportJobInfo() # exports a first time to give hints to external scripts 
     1334                wrapper.exportJobInfo() # exports a second time, now that we know the job's size. TODO : don't reexport all 
    13341335                wrapper.overwriteJobAttributes() 
    1335                 wrapper.exportJobInfo() # re-exports in case it was overwritten 
     1336                wrapper.exportJobInfo() # re-exports in case it was overwritten. TODO : don't reexport all. 
    13361337                retcode = wrapper.mainWork() 
    13371338            except KeyboardInterrupt :