detection of midnight spanning tasks

detection of midnight spanning tasks.
Also added complete printr