It may be enough, though, to do the commit in the task's top-level procedure (what you queue for the scheduler), when you've returned from the calls into the modules. That would depend in part on whether rolling back a single transaction is adequate, or whether you need several transactions to capture progress along the task.
(My scheduler job isn't an example -- it's read-only on the db -- but the functions to handle starting and stopping the scheduling, and adding a "manual" run to the schedule (that is, running the task an extra time to handle something between periodic runs) are done with functions in controller/default.py using the -S switch, and each of those does a db.commit so that the scheduler sees the changes.)
/dps