Merge pull request #268619 from tweag/lib-descriptions
[NixPkgs.git] / pkgs / development / python-modules / ssdp / default.nix
blob295ebc98a94152f90fe2ec363d3c45fad3bd22ff
1 { lib
2 , buildPythonPackage
3 , fetchFromGitHub
4 , flit-core
5 , flit-scm
6 , pytestCheckHook
7 , pythonOlder
8 }:
10 buildPythonPackage rec {
11   pname = "ssdp";
12   version = "1.3.0";
13   format = "pyproject";
15   disabled = pythonOlder "3.8";
17   src = fetchFromGitHub {
18     owner = "codingjoe";
19     repo = pname;
20     rev = "refs/tags/${version}";
21     hash = "sha256-mORjMEg7Q/2CKZBLICSGF8dcdl98S6mBgJ4jujPGs6M=";
22   };
24   SETUPTOOLS_SCM_PRETEND_VERSION = version;
26   postPatch = ''
27     substituteInPlace pyproject.toml \
28       --replace "--cov" ""
29   '';
31   nativeBuildInputs = [
32     flit-core
33     flit-scm
34   ];
36   nativeCheckInputs = [
37     pytestCheckHook
38   ];
40   pythonImportsCheck = [
41     "ssdp"
42   ];
44   meta = with lib; {
45     description = "Python asyncio library for Simple Service Discovery Protocol (SSDP)";
46     homepage = "https://github.com/codingjoe/ssdp";
47     changelog = "https://github.com/codingjoe/ssdp/releases/tag/${version}";
48     license = licenses.mit;
49     maintainers = with maintainers; [ fab ];
50   };