Temp fix for multiple writes to file

Fixed the multiple read write error by adding try catch block.
Applied partial recalculation of non completed task