Skip to main content

Python protobuf bindings for RDF-Connect

Project description

Python protobuf bindings for RDF-Connect

Development

The Packaging Python Projects guide was used to set up this project. As build backend, the default Hatchling is used, for which the pyproject.toml file is configured. That file tells build frontend tools like pip which backend to use. This project uses uv as package manager.

First, make sure you have Hatch installed:

pip install hatch
# OR
brew install hatch
# OR another method of your choice

Then, create a virtual environment and spawn a shell. This will automatically install the project dependencies defined in pyproject.toml:

hatch env create
hatch shell

Next, generate the gRPC interfaces and code for Python from the proto files by running the following command:

hatch run proto

Next to generating the code, this command also fixes the import statements in the generated files to ensure they are relative imports. This is necessary because the generated code is placed in a subdirectory (src/rdfc_proto/generated) and the imports need to be adjusted accordingly. The fix_proto_imports.py script is responsible for this adjustment.

All the generated code will be placed in the src/rdfc_proto/generated directory, which is where the Python package expects to find the generated files. You can safely delete the src/rdfc_proto/generated directory and re-run the command to regenerate the code if needed.

You can build the project with:

hatch build

Lastly, you can publish the package to PyPI with:

hatch publish

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

rdfc_proto-1.0.0.tar.gz (8.5 kB view details)

Uploaded Source

Built Distribution

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

rdfc_proto-1.0.0-py3-none-any.whl (9.3 kB view details)

Uploaded Python 3

File details

Details for the file rdfc_proto-1.0.0.tar.gz.

File metadata

  • Download URL: rdfc_proto-1.0.0.tar.gz
  • Upload date:
  • Size: 8.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: python-httpx/0.28.1

File hashes

Hashes for rdfc_proto-1.0.0.tar.gz
Algorithm Hash digest
SHA256 0ee22540731b6ca6484539cc0438d1f02e5f5311074bb17c55a5b89ec6ed9e2e
MD5 9090dd9e65ff7f366e82baa5694054c5
BLAKE2b-256 1fbe4b2bc88dbfc3f8c4403f0b23d2310298387ad3966a481ab0a7639d7cf8d4

See more details on using hashes here.

File details

Details for the file rdfc_proto-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: rdfc_proto-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 9.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: python-httpx/0.28.1

File hashes

Hashes for rdfc_proto-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 29d2c7867b740e0b69e986d697919e36371b918fc58fef716840d6493d295cab
MD5 bf86a523b9158e56361bc084807b5b26
BLAKE2b-256 91f1f7196734119e437d8d5c33bd2442f878da8dff1922663350f3099c69e54e

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