Better error handling and notification