Code should never raise an assertion error, there should be some semantic error that's raised.