Fix pathnames when downloading plugins using requests