fix py24 issue with regtests
address a few more remarks