better py3 folder downloader support

fix some import error in py3 and better performance of download folders.