add run mode with error