Changelog#

All notable changes to this project will be documented in this file.

The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.

Unreleased#

v1.5.0 - 2023-10-11#

Added#

  • Added get_bytes_range() function.

v1.4.0 - 2023-08-02#

Added#

  • Added support for file paths in the form of a URL like: file://.

v1.3.5 - 2023-07-15#

Changed#

  • Added support for newest versions of FileLock and huggingface-hub.

v1.3.4 - 2023-04-06#

Fixed#

  • Fixed issue where progress bar would jump around for big downloads.

v1.3.3 - 2023-02-16#

Fixed#

  • Fixed handling beaker:// URLs when using dataset ID.

v1.3.2 - 2023-02-15#

Changed#

  • Added support for newest huggingface-hub version.

v1.3.1 - 2023-01-18#

Fixed#

  • No more blank lines when quiet=True.

v1.3.0 - 2023-01-12#

Added#

  • Added optional support for beaker:// URLs.

v1.2.0 - 2023-01-12#

Changed#

  • Downloads from HuggingFace will be passed onto the huggingface_hub library completely so you won’t end up with duplicates of the same objects if your using other libraries that use huggingface_hub directly, such as transformers.

v1.1.6 - 2022-09-28#

Changed#

  • When we’re exceeding the maximum number of retries, the exception object now contains a string message instead of the last unsuccessful request object.

v1.1.5 - 2022-07-05#

v1.1.4 - 2022-06-29#

Changed#

  • Added support for latest huggingface_hub client library (v0.8.1), but dropped support for older versions.

v1.1.3 - 2022-06-13#

Added#

  • Added quiet parameter to cached_path() for turning off progress displays, and progress parameter for customizing displays.

  • Added SchemeClient.get_size() method.

Changed#

  • Switched to rich for progress displays, removed dependency on tqdm.

Removed#

  • Removed file_friendly_logging() function.

v1.1.2 - 2022-04-08#

v1.1.1 - 2022-03-25#

Fixed#

  • Fixed bug where cached_path() would fail to find local files with the home shortcut “~/” in their path.

v1.1.0 - 2022-03-03#

Changed#

  • Python >= 3.7 now required.

  • cached_path() now returns a Path instead of a str.

v1.0.2 - 2021-12-23#

Fixed#

  • Fixed snapshot downloads from HuggingFace Hub.

v1.0.1 - 2021-12-02#

Added#

  • Added support for latest version of huggingface-hub (v0.2.0).

v1.0.0 - 2021-11-29#

Removed#

  • Removed dependency on the overrides package

v0.3.4 - 2021-11-19#

v0.3.3 - 2021-11-17#

Changed#

  • filelock >= 3.4 required.

v0.3.2 - 2021-11-03#

Changed#

  • Updated HuggingFace Hub requirement to support 0.1.0.

v0.3.1 - 2021-10-07#

Fixed#

  • Fixed FileLock issue that overrides was complaining about.

v0.3.0 - 2021-09-23#

Changed#

  • Renamed SchemeClient.connection_error_types to recoverable_errors, and included requests.exceptions.Timeout.

  • HttpClient now considers 502, 503, and 504 as recoverable_errors.

v0.2.0 - 2021-09-22#

Added#

  • Added function set_cache_dir for overriding the global default cache directory.

  • Added function get_cache_dir for getting the global default cache directory.

  • Added function add_scheme_client for extending cached_path to handle more URL schemes.

  • Added function file_friendly_logging to turn file friendly logging on globally.

Changed#

  • _Meta dataclass renamed to Meta.

  • FileLock moved to cached_path.file_lock.

  • CacheFile moved to cached_path.cache_file.

  • The download progress bar uses 1024 instead of 1000 as the unit scale.

  • AWS S3 and Google Cloud Storage downloads now have a progress bar.

Fixed#

  • For HTTP resources, when the server returns a 404 cached_path() now raises FileNotFoundError for consistency.

  • Fixed fetching ETag / MD5 hash for Google Cloud Storage resources.

  • Made Google Cloud Storage requests more robust by adding a retry policy and checking MD5 sums.

v0.1.0 - 2021-09-09#

Added#

  • Added code for a file utility library that provides a unified, simple interface for accessing both local and remote files. This can be used behind other APIs that need to access files agnostic to where they are located.