bw2io.download_utils
#
Module Contents#
Functions#
|
Download file from URL and show progress bar. |
|
Get filename from response headers or URL. |
- bw2io.download_utils.download_with_progressbar(url, filename=None, dirpath=None, chunk_size=4096 * 8)[source]#
Download file from URL and show progress bar.
Parameters#
- urlstr
URL to download from.
- filenamestr, optional
Filename to save to. If not given, will be determined from URL.
- dirpathstr, optional
Directory to save to. If not given, will be current working directory.
- chunk_sizeint, optional
Chunk size to use when downloading.
Returns#
- pathlib.Path
Path to downloaded file.