This repository was archived by the owner on Apr 23, 2025. It is now read-only.
This repository was archived by the owner on Apr 23, 2025. It is now read-only.
Better error message on unzip failure #675
Open
Description
I attempted to run benchmarks on a fresh instance that did not have unzip
installed. The error message is misleading, stating that the file does not exist, even though the download was successful.
We should also document unzip
in the README as a required dependency, or fail more gracefully. Even better, do the unarchiving ourselves, without relying on a local install (@BradLarson).
$ swift run -c release Benchmarks --filter WordSegScore --filter-not x10
running WordSegScore: sentence_4...Loading resource: seg
File does not exist locally at expected path: /home/michellecasbon_google_com/.cache/swift-models/datasets/WordSeg/seg and must be fetched
Fetching URL: https://s3.eu-west-2.amazonaws.com/k-kawakami/seg.zip...
Archive saved to: /home/michellecasbon_google_com/.cache/swift-models/datasets/WordSeg
Failed to extract /home/michellecasbon_google_com/.cache/swift-models/datasets/WordSeg/seg.zip with error: Error Domain=NSCocoaErrorDomain Code=260 "The file doesn’t exist."
$ ls -l /home/michellecasbon_google_com/.cache/swift-models/datasets/WordSeg/seg.zip
-rw-r--r-- 1 michellecasbon_google_com 803248955 7375585 Oct 1 02:38 /home/michellecasbon_google_com/.cache/swift-models/datasets/WordSeg/seg.zip