Clean up orphaned tasks logs

Addresses #229

Without this, tasklogs will accumulate over time and eventually fill up
the master's disk.
Fix import order
Move imports to the top of the file
Handle ENOENT when deleting task logs
Simplify log message, use logger for formatting
Don't use built-in name file for variable name
Import ENOENT symbol
Rename file-filepath everywhere
Fix one more occurence of "file"
Merge pull request #272 from guidow/cleanup_orphaned_task_logs

Clean up orphaned tasks logs