我正在嘗試從https://www.fec.gov/data/browse-data/?tab=bulk-data下載 .zip 文件,特別是https://www.fec.gov/files/bulk-downloads/2020 /indiv20.zip。壓縮后,文件大小為 2.7 GB。下載將在 10 秒內啟動并完成。當我嘗試解壓縮該文件時,我收到以下錯誤消息。下載到我的本地計算機時,鏈接會以 .zip 文件形式下載并打開所需的數據。!python --versionPython 3.7.8!curl -O https://www.fec.gov/files/bulk-downloads/2020/indiv20.zip % Total % Received % Xferd Average Speed Time Time Time Current Dload Upload Total Spent Left Speed 100 138 100 138 0 0 690 0 --:--:-- --:--:-- --:--:-- 690!unzip -a indiv20.zipArchive: indiv20.zip End-of-central-directory signature not found. Either this file is not a zipfile, or it constitutes one disk of a multi-part archive. In the latter case the central directory and zipfile comment will be found on the last disk(s) of this archive. unzip: cannot find zipfile directory in one of indiv20.zip or indiv20.zip.zip, and cannot find indiv20.zip.ZIP, period. import zipfilewith zipfile.ZipFile("indiv20.zip", 'r') as zip_ref: zip_ref.extractall()
添加回答
舉報
0/150
提交
取消