depot/third_party/nixpkgs/pkgs/development/python-modules/kiss-headers/default.nix
Default email 22017988c6 Project import generated by Copybara.
GitOrigin-RevId: c777cdf5c564015d5f63b09cc93bef4178b19b01
2022-04-27 11:35:20 +02:00

39 lines
1 KiB
Nix

{ lib, buildPythonPackage, fetchFromGitHub, requests, pytestCheckHook }:
buildPythonPackage rec {
pname = "kiss-headers";
version = "2.3.1";
format = "setuptools";
src = fetchFromGitHub {
owner = "Ousret";
repo = pname;
rev = "refs/tags/${version}";
sha256 = "sha256-xPjw/uJTmvmQZDrI3i1KTUeAZuDF1mc13hvFBl8Erh0=";
};
propagatedBuildInputs = [ requests ];
checkInputs = [ pytestCheckHook ];
postPatch = ''
substituteInPlace setup.cfg \
--replace "--cov=kiss_headers --doctest-modules --cov-report=term-missing -rxXs" "--doctest-modules -rxXs"
'';
disabledTestPaths = [
# Tests require internet access
"kiss_headers/__init__.py"
"tests/test_serializer.py"
"tests/test_with_http_request.py"
];
pythonImportsCheck = [ "kiss_headers" ];
meta = with lib; {
description = "Python package for HTTP/1.1 style headers";
homepage = "https://github.com/Ousret/kiss-headers";
license = licenses.mit;
maintainers = with maintainers; [ wolfangaukang ];
};
}