Skip to main content

A memory-efficient packed representation for bit arrays in pure Python

Project description

BitVector

Test Check Links

The BitVector.py module is for a memory-efficient packed representation of bit vectors and for the processing of such vectors.

If you wish, you can execute the code in BitVector.py directly in this directory prior to the installation of the module. This will execute all of the example code in the module file.

To see a working example of the BitVector module, see the file:

This is a fork from Avi Kak's BitVector 3.5.0.

Development

This project uses uv for dependency management and pre-commit to enforce code quality and conventional commit messages.

After cloning the repository, set up the development environment and register both pre-commit and commit-msg git hooks:

uv sync
uv run pre-commit install --hook-type pre-commit --hook-type commit-msg

To execute the automated test suite and check code coverage:

uv run pytest

To continuously run adaptive, coverage-guided property-based fuzzing on the hypothesis test suite (tests/test_properties.py):

uv run hypothesis fuzz tests/test_properties.py

Releasing

Releases are automated via GitHub Actions. We strictly adhere to Semantic Versioning 2.0.0.

Release Process

To trigger a new package build and release:

  1. Bump Version: Update the version string in pyproject.toml.
    • For final releases, use X.Y.Z (e.g., 1.0.0).
    • For release candidates, append -rc.N (e.g., 1.0.0-rc.1, 1.0.0-rc.2).
  2. Commit and Push: Push the version change to main (typically via a pull request).
  3. Tag and Push: Create and push a git tag matching the version, prefixed with a v:
    # Example for a release candidate
    git tag v1.0.0-rc.1
    git push origin v1.0.0-rc.1
    
    # Example for a final release
    git tag v1.0.0
    git push origin v1.0.0
    

Release Workflow Execution

The Release workflow is triggered by tags matching v[0-9]*.[0-9]*.[0-9]*. It executes the following steps:

  • Verification: Runs the test suite to ensure the package builds cleanly.
  • Build: Compiles package wheels and source distributions using uv build.
  • Publish to PyPI: Publishes the package to PyPI (requires PyPI Trusted Publishing setup).
    • Prerelease versions (like v1.0.0-rc.1) are published as pre-releases on PyPI.
  • GitHub Release: Creates a GitHub Release, uploads the built artifacts (dist/*), and auto-generates release notes.
    • Prerelease tags (containing -rc, -beta, -alpha, or -pre) are automatically marked as Pre-release on GitHub.

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

bitvector_modern-0.0.3.tar.gz (121.2 kB view details)

Uploaded Source

Built Distribution

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

bitvector_modern-0.0.3-py3-none-any.whl (18.0 kB view details)

Uploaded Python 3

File details

Details for the file bitvector_modern-0.0.3.tar.gz.

File metadata

  • Download URL: bitvector_modern-0.0.3.tar.gz
  • Upload date:
  • Size: 121.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for bitvector_modern-0.0.3.tar.gz
Algorithm Hash digest
SHA256 56ed4abbc4e3dcf018998c3cc00fb69523dd46aee075daea3d15b6859dc8f8cf
MD5 f3225c964e13cb1f08ac68fa953b24f4
BLAKE2b-256 bcc12907adcaafad88438b9c9abeae5557f961c530915f2e0c2985432ad6a9b7

See more details on using hashes here.

File details

Details for the file bitvector_modern-0.0.3-py3-none-any.whl.

File metadata

File hashes

Hashes for bitvector_modern-0.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 e01acfd4ca938a20ae9f994423384cd94b9a3605390d5c5c61180352a40297c8
MD5 c0a3a41d5f33793c216f5ffb5f057110
BLAKE2b-256 a995432c54d10217bf510abf73c552694fea02a035c7d61789a1346c4d892cd1

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