This project can be used to mirror the pypi index using the new warehouse api.
Project description
pypi-downloader
Description
This project can be used to mirror the pypi index using the new warehouse API.
This project consists of two scripts:
- a multithreaded version of the main script, pypi-downloader-mt.py, as command: pypi-downloader
- a helper script to get the current list of packages from the pypi index site currently located at: https://pypi.org/, as command: pypi-packages
Config file
If a config file is specified as a command line parameter, the config file uses the YAML format.
The config file consists of four sections:
- logging - Specifies a logging.dictConfig dictionary
- threads - Number of threads to use
- packages - List of packages to download, if no packages are specified, all packages are downloaded from the pypi index site
- blacklist - List of packages to not download
Note: For logging, this module uses the root logger only. Note: Values specified in the config file (threads and packages) can be overridden by values specified on the command line.
Config file examples
Default configuration
logging:
version: 1
formatters:
simple:
format: '[%(levelname)s]: %(message)s'
handlers:
console1:
class: logging.StreamHandler
level: ERROR
formatter: simple
stream: ext://sys.stderr
console2:
class: logging.StreamHandler
level: DEBUG
formatter: simple
stream: ext://sys.stdout
root:
level: INFO
stream: ext://sys.stdout
handlers: [console1, console2]
threads: 1
packages:
blacklist:
Default configuration with packages and blacklist specified and non default thread count
logging:
version: 1
formatters:
simple:
format: '[%(levelname)s]: %(message)s'
handlers:
console1:
class: logging.StreamHandler
level: ERROR
formatter: simple
stream: ext://sys.stderr
console2:
class: logging.StreamHandler
level: DEBUG
formatter: simple
stream: ext://sys.stdout
root:
level: INFO
stream: ext://sys.stdout
handlers: [console1, console2]
threads: 5
packages:
- tox
- mypy
blacklist:
- pyyaml
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
pypi-downloader-2.0.4.tar.gz
(9.0 kB
view details)
Built Distribution
File details
Details for the file pypi-downloader-2.0.4.tar.gz
.
File metadata
- Download URL: pypi-downloader-2.0.4.tar.gz
- Upload date:
- Size: 9.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.0.0 requests-toolbelt/0.9.1 tqdm/4.44.1 CPython/3.7.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | ccf6e97ee4788672f8ee91d95d7cad9d5d6132a8b7de59a2f1d177b101b718df |
|
MD5 | e2229a268d3bf636fe3da2d1beccc8df |
|
BLAKE2b-256 | 403ef4d43f214b71d02884aebb35953cb1970a598d38a742035c9de3fb95a963 |
File details
Details for the file pypi_downloader-2.0.4-py3-none-any.whl
.
File metadata
- Download URL: pypi_downloader-2.0.4-py3-none-any.whl
- Upload date:
- Size: 9.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.0.0 requests-toolbelt/0.9.1 tqdm/4.44.1 CPython/3.7.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | ee3ee1ad4b5783f07a0dde7d4f8389ac02bce44047ca81ff87d9c2ce487a6a90 |
|
MD5 | f7c1e90f647fac281d193c3e8a36423e |
|
BLAKE2b-256 | 59ea431cc1222d8e2d10b2c34a10f286589e57bd849603a198acc8e91f4f5d8d |