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-0.0.1.tar.gz (8.4 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-0.0.1-py3-none-any.whl (14.3 kB view details)

Uploaded Python 3

File details

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

File metadata

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

File hashes

Hashes for rdfc_proto-0.0.1.tar.gz
Algorithm Hash digest
SHA256 a467758bd1485af1659e2996d8d909e695b114cc3158f4b5fa174340197bc396
MD5 82525c1aa3bb735e7500d1d1267f1696
BLAKE2b-256 90e76d05b0d9c9acab1a6c729fad3e500a378179face5600438917625338b402

See more details on using hashes here.

File details

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

File metadata

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

File hashes

Hashes for rdfc_proto-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 f5a4c9958d44b0bb89511b1b7df363f09241f5c9095c89e770e71487eb26cbb6
MD5 925e8f03424c46aa6810bd28ddd33e46
BLAKE2b-256 39b29702dd03e4a2c4091e4127059acdf81612e13f478462320b30d0bb86ded1

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