ds-reify
A CLI helper tool for Distributed-Something
Development
Setup Virtual Environment
Setup a python environment using the method of your choice.
Using the builtin venv:
python -m venv <ENV_NAME>
source <ENV_NAME>/bin/activate
Using conda (replace with any python >= 3.8):
conda create -n <ENV_NAME> python=3.8
conda activate <ENV_NAME>
Using whatever else you want, like pyenv.
Install dev tools
Install Poetry
curl -sSL https://install.python-poetry.org/ | python
source ~/.poetry/env
Install Nox
pip install --user --upgrade nox
See this post if you're curious as to why we don't install nox via Poetry.
Install pre-commit
pip install --user --upgrade pre-commit
Let Poetry install the rest from pyproject.toml
poetry install
Testing
Coverage.py is used for test coverage, alongside pytest, via the pytest-cov plugin.
To run the tests directly, in you virtual environment, run pytest --cov.
To let nox run across multiple isolated environments, run nox.
To avoid nox recreating the virtual environments from scratch on each invocation, run nox -r.
Run a specific test with nox -s tests -- tests/test_TESTNAME.
Static analysis
Autoformatting is performed with Black.
Run formatting with nox -s black or specify files/directors with nox -s black -- file1 dir1 ....
Black auto-formatting is not run by default when running nox in isolation, it must be specified.
Flake8 is used for linting. Under the hood, it uses:
- pylint
- pyflakes - invalid python code
- errors reported as
F
- errors reported as
- pycodestyle - PEP 8 style checking
Wfor warnings,Efor errors
- mccabe - code complexity
- errors reported as
C.
- errors reported as
- flake8-black plugin - adherence to Black code style
- erros reported as
BLK.
- erros reported as
- flake8-import-order plugin - import grouping and ordering checked against the Google styleguide
- errors reported as
I
- errors reported as
- flake8-bugbear plugin - various miscellaneous bugs and design problems
- likely bugs reported as
B - opinionated bugs reported as
B9 B950replacesE501for max line length checking (adds tolerance margin of 10%)
- likely bugs reported as
- flake8-bandit plugin - uses Bandit to find common security issues
- issues reported as
S
- issues reported as
- flake8-annotations plugin - detects absence of type annotations for functions
- issues reported as
ANN
- issues reported as
All of these are configured in the .flake8 file.
Run linting with nox -s lint or specify files/directoriess with nox -s lint -- file1 dir1 ....
Import ordering is not auto-formatted although may in the future by migrating to flake8-isort.
Safety is uesd for checking project dependencies against known security violations. For example, insecure-package.
Run it with nox -s safety.
Pre-commit
If you would like to enable the pre-commit hooks, run pre-commit install.
The hooks will run on files changed by the commit in question. To trigger hooks automatically run pre-commit run --all-files.
Metadata
Release files for ds-reify 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| ds_reify-0.1.0.tar.gz | 5.1 kB | Without provenance | Details for ds_reify-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| ds_reify-0.1.0-py3-none-any.whl | Python 3 | none | any | Details for ds_reify-0.1.0-py3-none-any.whl |
Total release size: 11.1 kB
Release files / ds_reify-0.1.0.tar.gz
| Download URL | ds_reify-0.1.0.tar.gz |
|---|---|
| Size | 5.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
69e85157810599b041f3ad4d76567693da6b4a730a8a711e48bc3e2c93ebd64f
|
|
BLAKE2b-256 checksum How to use checksums |
a743997e9147ab5661980b2c3b944cc994510d38366fb055917606df51334705
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.4.0 CPython/3.8.16 Darwin/22.3.0
|
Release files / ds_reify-0.1.0-py3-none-any.whl
| Download URL | ds_reify-0.1.0-py3-none-any.whl |
|---|---|
| Size | 6.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
4d0b0f98c877d1941aa8b54fbcdf34aed125b29e5ebb5b125c642681b862e2dc
|
|
BLAKE2b-256 checksum How to use checksums |
2c7ce61eea119d174a74fb03c206b9a82835d8147841eb1e4392f656447f7417
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.4.0 CPython/3.8.16 Darwin/22.3.0
|
Security for ds-reify 0.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.