depot/third_party/nixpkgs/pkgs/development/python-modules/ssdp/default.nix
Default email c7e6337bd0 Project import generated by Copybara.
GitOrigin-RevId: 08e4dc3a907a6dfec8bb3bbf1540d8abbffea22b
2023-04-29 12:46:19 -04:00

51 lines
1,004 B
Nix

{ lib
, buildPythonPackage
, fetchFromGitHub
, flit-core
, flit-scm
, pytestCheckHook
, pythonOlder
}:
buildPythonPackage rec {
pname = "ssdp";
version = "1.1.1";
format = "pyproject";
disabled = pythonOlder "3.8";
src = fetchFromGitHub {
owner = "codingjoe";
repo = pname;
rev = "refs/tags/${version}";
hash = "sha256-D2mww3sEc2SvufWNmT450a2CW+ogROn3RHypljkebuY=";
};
SETUPTOOLS_SCM_PRETEND_VERSION = version;
postPatch = ''
substituteInPlace pyproject.toml \
--replace "--cov" ""
'';
nativeBuildInputs = [
flit-core
flit-scm
];
nativeCheckInputs = [
pytestCheckHook
];
pythonImportsCheck = [
"ssdp"
];
meta = with lib; {
description = "Python asyncio library for Simple Service Discovery Protocol (SSDP)";
homepage = "https://github.com/codingjoe/ssdp";
changelog = "https://github.com/codingjoe/ssdp/releases/tag/${version}";
license = licenses.mit;
maintainers = with maintainers; [ fab ];
};
}