python310Packages.karton-classifier: 1.3.0 -> 1.4.0

This commit is contained in:
Fabian Affolter 2022-08-09 22:55:41 +02:00
parent 5c953fb7af
commit 8f39ebbaf9

View file

@ -10,7 +10,8 @@
buildPythonPackage rec {
pname = "karton-classifier";
version = "1.2.0";
version = "1.4.0";
format = "setuptools";
disabled = pythonOlder "3.7";
@ -18,7 +19,7 @@ buildPythonPackage rec {
owner = "CERT-Polska";
repo = pname;
rev = "v${version}";
sha256 = "sha256-AG2CtNMgXYfbdlOqB1ZdjMT8H67fsSMXTgiFg6K41IQ=";
hash = "sha256-TRmAin0TAOIwR5EBMwTOJ9QaHO+mOx/eAjgqvyQZDj4=";
};
propagatedBuildInputs = [
@ -27,17 +28,25 @@ buildPythonPackage rec {
python-magic
];
checkInputs = [
pytestCheckHook
];
postPatch = ''
substituteInPlace requirements.txt \
--replace "chardet==3.0.4" "chardet" \
--replace "python-magic==0.4.18" "python-magic"
'';
checkInputs = [
pytestCheckHook
pythonImportsCheck = [
"karton.classifier"
];
pythonImportsCheck = [ "karton.classifier" ];
disabledTests = [
# Tests expecting results from a different version of libmagic
"test_process_archive_ace"
"test_process_runnable_win32_lnk"
];
meta = with lib; {
description = "File type classifier for the Karton framework";