attempt fix of py2.7 portability