Updated exception handling to fix bug in which calendar and tasks are duplicated when an an exception occurs while retrieving from an external source.