Fix for CommandError (orig. syntax was not working on Python 3.x)