download manager library
Project description
dlmanager
dlmanager is Python 2 and 3 download manager library, with the following features:
Download files in background and in parallel
Cancel downloads
store downloads in a given directory, avoiding re-downloading files
Limit the size of this directory, removing oldest files
Example
from dlmanager import DownloadManager, PersistLimit
manager = DownloadManager(
"dlmanager-destir",
persist_limit=PersistLimit(
size_limit=1073741824, # 1 GB max
file_limit=10, # force to keep 10 files even if size_limit is reached
)
)
# Start downloads in background
# Note that if files are already present, this is a no-op.
manager.download(url1)
manager.download(url2)
# Wait for completion
try:
manager.wait()
except:
manager.cancel()
raise
Installation
Use pip:
pip install -U dlmanager
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
dlmanager-0.1.1.tar.gz
(2.1 kB
view details)
Built Distribution
File details
Details for the file dlmanager-0.1.1.tar.gz
.
File metadata
- Download URL: dlmanager-0.1.1.tar.gz
- Upload date:
- Size: 2.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | ae9d27189dd0fa977a7f30cb30f9bfa1c8ac7f697c5fc053aa0038b82ca31d9b |
|
MD5 | c410da26abe236a2a4803d31e9474b3b |
|
BLAKE2b-256 | a634ce422e0e07f9207bc2a568e912124df7d80d248273f733622b4af01799a2 |
File details
Details for the file dlmanager-0.1.1-py2.py3-none-any.whl
.
File metadata
- Download URL: dlmanager-0.1.1-py2.py3-none-any.whl
- Upload date:
- Size: 3.1 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e44db05e963f70d7472e643a1188086dbd7e1ad25d20ae5d7b23d984402eb825 |
|
MD5 | d104ff341b449fbab8cf936dd3606165 |
|
BLAKE2b-256 | b6a73498ddddc194a856bd707a67a32dea7f4e0a09d66be9f818b8c9c67fbf42 |