error handling if power mode switch script fails