older python syntax fix