Skip to main content

tests PyPI version shields.io PyPI pyversions Coverage Status

ghga-service-commons

This Python library serves as a collection of common utilities used by the microservices developed at German Human Genome-Phenome Archive (GHGA).

It collects boilerplate code for common functionalities such as API server setup, authentication and authorization.

This library is primarily intended for internal use at GHGA and should not be seen as a general-purpose microservice chassis. However, if this library matches your specific needs as well, please feel free to use it. It is open source.

Installation

This package is available at PyPI: https://pypi.org/project/ghga_service_commons

You can install it from there using:

pip install ghga_service_commons

Thereby, you may specify following extra(s):

  • api: dependencies needed to use the API server functionalities
  • auth: dependencies needed for dealing with authentication and authorization

Development

For setting up the development environment, we rely on the devcontainer feature of vscode.

To use it, you have to have Docker as well as vscode with its "Remote - Containers" extension (ms-vscode-remote.remote-containers) installed. Then, you just have to open this repo in vscode and run the command Remote-Containers: Reopen in Container from the vscode "Command Palette".

This will give you a full-fledged, pre-configured development environment including:

  • infrastructural dependencies of the service (databases, etc.)
  • all relevant vscode extensions pre-installed
  • pre-configured linting and auto-formatting
  • a pre-configured debugger
  • automatic license-header insertion

Moreover, inside the devcontainer, there is following convenience command available (please type it in the integrated terminal of vscode):

  • dev_install - install the lib with all development dependencies and pre-commit hooks (please run that if you are starting the devcontainer for the first time or if added any python dependencies to the ./pyproject.toml)

If you prefer not to use vscode, you could get a similar setup (without the editor specific features) by running the following commands:

# Execute in the repo's root dir:
cd ./.devcontainer

# build and run the environment with docker-compose
docker build -t ghga-service-commons .
docker run -it ghga-service-commons /bin/bash

License

This repository is free to use and modify according to the Apache 2.0 License.

Metadata

Release files for ghga_service_commons 7.0.5

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for ghga_service_commons 7.0.5
File Size Uploaded Provenance Actions
ghga_service_commons-7.0.5.tar.gz 42.1 kB Without provenance Details for ghga_service_commons-7.0.5.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for ghga_service_commons 7.0.5
File Interpreter ABI Platform Actions
ghga_service_commons-7.0.5-py3-none-any.whl Python 3 none any Details for ghga_service_commons-7.0.5-py3-none-any.whl

Total release size: 113.5 kB

Release files / ghga_service_commons-7.0.5.tar.gz

Download URL ghga_service_commons-7.0.5.tar.gz
Size 42.1 kB
Tags Source
SHA-256 checksum
How to use checksums
e57ca0835f047b1d64eb6c663969b255655fdcbd1bea7385496334a06e5687a3
BLAKE2b-256 checksum
How to use checksums
aff34321ba600854c46a6ac7b3062409f10668621abd47fe98683936226305a4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.12

Release files / ghga_service_commons-7.0.5-py3-none-any.whl

Download URL ghga_service_commons-7.0.5-py3-none-any.whl
Size 71.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
11719e9bf09370bac990316a6b953d1c8bf4e2d4aba23157bc8a29e9b007106b
BLAKE2b-256 checksum
How to use checksums
54588d5157a47d985854f385509c1505fa5d94b3aa4c79009741757831dad635
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.12

Security for ghga_service_commons 7.0.5

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.

Release history Release notifications | RSS feed

This release

7.0.5 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page