depot/third_party/nixpkgs/pkgs/development/python-modules/kiss-headers/default.nix
Default email e7ec2969af Project import generated by Copybara.
GitOrigin-RevId: 9b19f5e77dd906cb52dade0b7bd280339d2a1f3d
2024-01-13 09:15:51 +01:00

39 lines
1 KiB
Nix

{ lib, buildPythonPackage, fetchFromGitHub, requests, pytestCheckHook }:
buildPythonPackage rec {
pname = "kiss-headers";
version = "2.4.3";
format = "setuptools";
src = fetchFromGitHub {
owner = "Ousret";
repo = pname;
rev = "refs/tags/${version}";
hash = "sha256-WeAzlC1yT+0nPSuB278z8T0XvPjbre051f/Rva5ujAk=";
};
propagatedBuildInputs = [ requests ];
nativeCheckInputs = [ 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 ];
};
}