btrbk: add mainProgram (#356350)
[NixPkgs.git] / pkgs / development / python-modules / httpx-sse / default.nix
blobff0a4069090bf292f83416acb8ff1b4d580c9b5f
2   lib,
3   buildPythonPackage,
4   fetchFromGitHub,
5   setuptools,
6   setuptools-scm,
7   wheel,
8   httpx,
9   pytest-asyncio,
10   pytestCheckHook,
11   sse-starlette,
14 buildPythonPackage rec {
15   pname = "httpx-sse";
16   version = "0.4.0";
17   pyproject = true;
19   src = fetchFromGitHub {
20     owner = "florimondmanca";
21     repo = "httpx-sse";
22     rev = "refs/tags/${version}";
23     hash = "sha256-nU8vkmV/WynzQrSrq9+FQXtfAJPVLpMsRSuntU0HWrE=";
24   };
26   # pytest-cov configuration is not necessary for packaging
27   postPatch = ''
28     rm setup.cfg
29   '';
31   build-system = [
32     setuptools
33     setuptools-scm
34     wheel
35   ];
37   dependencies = [ httpx ];
39   pythonImportsCheck = [ "httpx_sse" ];
41   nativeCheckInputs = [
42     pytest-asyncio
43     pytestCheckHook
44     sse-starlette
45   ];
47   meta = with lib; {
48     description = "Consume Server-Sent Event (SSE) messages with HTTPX";
49     homepage = "https://github.com/florimondmanca/httpx-sse";
50     changelog = "https://github.com/florimondmanca/httpx-sse/blob/${src.rev}/CHANGELOG.md";
51     license = licenses.mit;
52     maintainers = with maintainers; [ natsukium ];
53   };