throw exceptions in command