Repository navigation
Important
Breaking changes. 1.0.0 settles the public API, so a few types and names change:
- swift-huggingface now requires swift-xet 1.0 (#85). If your package also depends on swift-xet, change its requirement to
from: "1.0.0". HTTPClientErroris now a struct with acode(#89). Switch onerror.code(.requestError,.responseError,.decodingError,.unexpectedError) instead of the error, and readstatusCode,detail, andresponsefrom its properties.ProviderandCapabilityare now structs (#90), so new providers and capabilities can come in 1.x without breaking anyone's code. Exhaustiveswitchstatements need adefaultcase, andProvider.custom(name:baseURL:)is now a static method, so checkprovider.identifierinstead of matchingcase .custom(let name, _).Bucket.Regionis now a struct (#88). Use.usand.euas before, orBucket.Region(rawValue:)for other regions.bucketInfo(_:)is nowgetBucket(_:), andgetBucketPathsInfo(_:paths:)is nowgetBucketFiles(_:paths:), to match the rest of the API (#93).- Some helpers that were public by accident are now internal (#86): the data URL helpers on
Data,DateDecodingStrategy.iso8601WithFractionalSeconds,FileLock,FileLockError,FilePermissions, andMultipartBuilderError.
Buckets can now download files, with progress reporting (#56).
Thanks to @pcuenca for building bucket support and for helping shape this release.
What's Changed
- Require swift-xet 1.0 by @mattt in #85
- Correct the platform requirements in the README by @mattt in #87
- Make internal helpers internal by @mattt in #86
- Make Provider and Capability structs by @mattt in #90
- Make HTTPClientError a struct with a code by @mattt in #89
- Make Bucket.Region a struct by @mattt in #88
- Update the Hub API endpoint coverage in the README by @mattt in #91
- Add a lint job to CI by @mattt in #92
- Rename bucket methods to match the rest of the API by @mattt in #93
- Bucket downloading by @pcuenca in #56
- Bump version to 1.0.0 by @mattt in #94
Full Changelog: 0.13.0...1.0.0