Fix Python 3 errors with rmtp downloads