Merge pull request #307098 from r-ryantm/auto-update/cilium-cli
[NixPkgs.git] / pkgs / development / python-modules / aioprometheus / default.nix
blob273d35fe13d983201beaf8ab36ed9751261d8736
1 { lib
2 , buildPythonPackage
3 , fetchFromGitHub
4 , orjson
5 , quantile-python
6 , aiohttp
7 , aiohttp-basicauth
8 , starlette
9 , quart
10 , pytestCheckHook
11 , httpx
12 , fastapi
13 , uvicorn
14 , pythonOlder
17 buildPythonPackage rec {
18   pname = "aioprometheus";
19   version = "unstable-2023-03-14";
20   format = "setuptools";
22   disabled = pythonOlder "3.8";
24   src = fetchFromGitHub {
25     owner = "claws";
26     repo = "aioprometheus";
27     rev = "4786678b413d166c0b6e0041558d11bc1a7097b2";
28     hash = "sha256-2z68rQkMjYqkszg5Noj9owWUWQGOEp/91RGiWiyZVOY=";
29   };
31   propagatedBuildInputs = [
32     orjson
33     quantile-python
34   ];
36   passthru.optional-dependencies = {
37     aiohttp = [
38       aiohttp
39     ];
40     starlette = [
41       starlette
42     ];
43     quart = [
44       quart
45     ];
46   };
48   nativeCheckInputs = [
49     pytestCheckHook
50     aiohttp-basicauth
51     httpx
52     fastapi
53     uvicorn
54   ] ++ lib.flatten (builtins.attrValues passthru.optional-dependencies);
56   pythonImportsCheck = [ "aioprometheus" ];
58   meta = with lib; {
59     description = "A Prometheus Python client library for asyncio-based applications";
60     homepage = "https://github.com/claws/aioprometheus";
61     changelog = "https://github.com/claws/aioprometheus/blob/${src.rev}/CHANGELOG.md";
62     license = licenses.mit;
63     maintainers = with maintainers; [ mbalatsko ];
64   };