Clean up orphaned tasks logs

Addresses #229

Without this, tasklogs will accumulate over time and eventually fill up
the master's disk.
Agree. This is not optimal.