python 2.6 && 3.x compability.