python312Packages.http-ece: refactor, switch tests to pynose

Removed linters from checkInputs, normalized pname, remove python <3.8
compatibility
This commit is contained in:
Martin Weinelt 2024-02-18 05:17:29 +01:00
parent cb8b6dedc4
commit ee5173a417
No known key found for this signature in database
GPG key ID: 87C1E9888F856759

View file

@ -1,20 +1,30 @@
{ lib, fetchPypi, buildPythonPackage, pythonOlder
, coverage, flake8, mock, nose, importlib-metadata
, cryptography }:
{ lib
, buildPythonPackage
, cryptography
, fetchPypi
, mock
, pynose
}:
buildPythonPackage rec {
pname = "http_ece";
pname = "http-ece";
version = "1.2.0";
src = fetchPypi {
inherit pname version;
pname = "http_ece";
inherit version;
sha256 = "sha256-tZIPjvuOG1+wJXE+Ozb9pUM2JiAQY0sm3B+Y+F0es94=";
};
propagatedBuildInputs = [ cryptography ]
++ lib.optionals (pythonOlder "3.8") [ importlib-metadata ];
postPatch = ''
substituteInPlace setup.py \
--replace-fail '"nose",' "" \
--replace-fail '"coverage",' ""
'';
nativeCheckInputs = [ coverage flake8 mock nose ];
propagatedBuildInputs = [ cryptography ];
nativeCheckInputs = [ mock pynose ];
meta = with lib; {
description = "Encipher HTTP Messages";