Skip to main content

Bitoduc library

Project description

Say Hello!

Say Hello! Logo

Python Package Template using UV

Python PyPi UV PyTest

Getting Started

  1. You need to have UV installed. You can find instructions here.

  2. Create the virtual environment

uv venv # create env .venv
uv sync # install dependencies
  1. Start developping :
  • Add your library code in the src/ directory
  • Write tests in the tests/ directory
  • Add your license
  • Update pyproject.toml with your package information
  1. In order to commit you need to :
    • Have no error from linter (ruff)
    • Pass all tests (pytest)

Development Workflows

Code Quality

To ensure a certain level of code quality, Ruff is used.

Configuration can be found in pyproject.toml.

Test

Tests must be write in tests and follow the convention of pytest

Scripts

All automation scripts are defined in noxfile.py file.

To run them use the following commands :

nox                   # Run all scripts
nox -s <script_name>  # Run a scpecific script

Available scripts :

  • lint : Check the codebase respect all linting and format rules
  • clean : Delete build directory dist
  • tests : Run tests from tests folder with python version from 3.9 to 3.13

You can list them with nox --list.

See Nox documentation if you want to know more.

Publishing your package

Automatic Publishing

Your package is automatically published when you push to:

  • main branch → Published to PyPI
  • dev branch → Published to TestPyPI

Manual Publishing

You can also publish it manually with the following commands :

uv publish --token YOUR_PYPI_TOKEN
# OR
uv publish --index testpypi --token YOUR_TEST_PYPI_TOKEN

Installing your package

Once published, your package can be installed with:

uv add your-package-name
uv add --default-index https://test.pypi.org/simple/ your-package-name # For testing

Or use pip :

pip install your-package-name
pip install --index-url https://test.pypi.org/simple/ your-package-name # For testing

Links

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

plombier-0.0.1.tar.gz (2.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

plombier-0.0.1-py3-none-any.whl (2.8 kB view details)

Uploaded Python 3

File details

Details for the file plombier-0.0.1.tar.gz.

File metadata

  • Download URL: plombier-0.0.1.tar.gz
  • Upload date:
  • Size: 2.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.8.13

File hashes

Hashes for plombier-0.0.1.tar.gz
Algorithm Hash digest
SHA256 212e50190218aa320dd5bfc864696a463fa515a388c2dbb06cfbc9967591920d
MD5 65670a359372ab5131aa603be9c195cf
BLAKE2b-256 f8d02ce49f144a848f009f2948e8f5b98082a3e71d0354f989dd7b73bb14915e

See more details on using hashes here.

File details

Details for the file plombier-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: plombier-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 2.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.8.13

File hashes

Hashes for plombier-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 2fbe7ea888b20f5a567217a7f75f246c10b4805a069dab154d63421ed0c7540c
MD5 a420b221d4dcc8eba05b5dfbea8765ac
BLAKE2b-256 888a949575ebf86d6326d85ee3c7465f4892fcd3978d35542de046152afeba30

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page