added further logging to identify caught errors