remove compatiblity code for old python version as we support python 2.7
only