fix assertion usage that is not in py3k