Fix unuse imp module that deprecated since Python 3.4