Refactored runner to catch exceptions and better integration with promises