pipette.cache_url

pipette.cache_url(url: str, pkg: str = 'pipette', update: bool = False) str

Download and cache a URL locally.

Files are cached in ~/.cache/<pkg>/.

Parameters:
  • url (str) – URL to download.

  • pkg (str) – Package name for cache subdirectory.

  • update (bool) – Force re-download if True.

Returns:

Path to the cached file.

Return type:

str