{"id":27811,"library":"ghga-service-commons","title":"GHGA Service Commons","description":"A library providing common functionality for GHGA services, including FastAPI utilities, authentication, config management, and custom HTTPX transports (caching, retry, rate limiting). Current version: 7.0.1. Requires Python >=3.10. Release cadence: irregular, with breaking changes in major versions (6.0.0, 7.0.0).","status":"active","version":"7.0.1","language":"python","source_language":"en","source_url":"https://github.com/ghga-de/ghga-service-commons","tags":["ghga","fastapi","httpx","authentication","health-check","transport","rate-limiting","retry"],"install":[{"cmd":"pip install ghga-service-commons","lang":"bash","label":"default"},{"cmd":"pip install ghga-service-commons[transports]","lang":"bash","label":"with transports support"}],"dependencies":[{"reason":"core web framework dependency","package":"fastapi","optional":false},{"reason":"HTTP client for transports","package":"httpx","optional":false},{"reason":"caching support (transports extra)","package":"hishel","optional":true}],"imports":[{"wrong":"from ghga_service_commons.utils.health_check import HealthEndpointConfig","symbol":"HealthEndpointConfig","correct":"from ghga_service_commons.utils.health_check import HealthEndpointConfig"}],"quickstart":{"code":"import os\nfrom ghga_service_commons.utils.health_check import HealthEndpointConfig\nfrom ghga_service_commons.auth.context import AuthContext\n\n# Example: configure health endpoint\nconfig = HealthEndpointConfig()\nprint(f\"Health endpoint configured: {config}\")\n\n# Example: create an auth context\n# (requires GHGA credentials or use environment variable)\nauth = AuthContext()\nprint(f\"Auth context: {auth}\")","lang":"python","description":"Basic usage: health endpoint configuration and auth context creation."},"warnings":[{"fix":"Review your FastAPI error handling: expect 401 instead of 403 for auth failures. If using caching, check Hishel compatibility.","message":"Version 7.0.0 introduced potentially breaking changes: FastAPI now returns 401 instead of 403 for missing authentication. Also Hishel was upgraded to a stable version, removing some caching features.","severity":"breaking","affected_versions":">=7.0.0"},{"fix":"See the migration guide in the GitHub release notes for 6.0.0.","message":"Version 6.0.0 introduced changes to the transport layer. CompositeRetryAndRateLimitTransport and other custom transports may require updated instantiation patterns.","severity":"breaking","affected_versions":">=6.0.0 <7.0.0"},{"fix":"Add the 'transports' extra to your dependency.","message":"The transports subpackage requires the optional dependency 'transports' extra. Install with 'pip install ghga-service-commons[transports]'.","severity":"gotcha","affected_versions":">=5.3.0"},{"fix":"Update imports to the correct submodules.","message":"Old import paths like 'ghga_service_commons.utils.health' are deprecated. Use 'ghga_service_commons.utils.health_check' instead.","severity":"deprecated","affected_versions":">=6.0.0"}],"env_vars":null,"search_vec":"'3.10':31 '6.0.0':41 '7.0.0':42 '7.0.1':28 'authent':15,46 'break':36 'cach':22 'cadenc':33 'chang':37 'check':49 'common':3,7 'config':16 'current':26 'custom':19 'fastapi':13,44 'function':8 'ghga':1,10,43 'health':48 'health-check':47 'httpx':20,45 'includ':12 'irregular':34 'librari':5 'limit':25,53 'major':39 'manag':17 'provid':6 'python':30 'rate':24,52 'rate-limit':51 'releas':32 'requir':29 'retri':23,54 'servic':2,11 'transport':21,50 'util':14 'version':27,40","created_at":"2026-05-09T05:52:12.690389+00:00","updated_at":"2026-05-09T05:52:12.690389+00:00","problems":{"verify_error":"Traceback (most recent call last):\n  File \"<string>\", line 1, in <module>\nModuleNotFoundError: No module named 'ghga_service_commons.utils.health_check'"},"ecosystem":"pypi","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":null,"cli_name":"","cli_version":null,"type":"library","homepage":null,"github":"https://github.com/ghga-de/ghga-service-commons","docs":null,"changelog":null,"pypi":"https://pypi.org/project/ghga-service-commons/","npm":null,"openapi_spec":null,"status_page":null,"smithery":null,"categories":["web-framework","http-networking","auth-security","testing","observability"],"base_url":null,"auth_type":null,"provenance":{"verified_status":"import_fail","verified_at":"2026-07-03","last_verified":"2026-07-03","next_check":"2026-07-10","install_tag":null}}