2021-03-22 18:50:31 +01:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
|
|
|
, hypothesis
|
|
|
|
, pythonOlder
|
|
|
|
, pytestCheckHook
|
|
|
|
}:
|
2017-09-05 11:16:41 +02:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "chardet";
|
2022-07-16 12:59:01 +02:00
|
|
|
version = "5.0.0";
|
2021-03-22 18:50:31 +01:00
|
|
|
disabled = pythonOlder "3.6";
|
2017-09-05 11:16:41 +02:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2022-07-16 12:59:01 +02:00
|
|
|
sha256 = "sha256-A2jfK/14tfwgVyu06bt/tT4sCU9grpmTM56GcdCvuKo=";
|
2017-09-05 11:16:41 +02:00
|
|
|
};
|
|
|
|
|
2021-03-22 18:50:31 +01:00
|
|
|
checkInputs = [
|
|
|
|
hypothesis
|
|
|
|
pytestCheckHook
|
2019-05-25 03:03:00 +02:00
|
|
|
];
|
|
|
|
|
2022-07-16 12:59:01 +02:00
|
|
|
disabledTests = [
|
|
|
|
# flaky; https://github.com/chardet/chardet/issues/256
|
|
|
|
"test_detect_all_and_detect_one_should_agree"
|
|
|
|
];
|
|
|
|
|
2021-03-22 18:50:31 +01:00
|
|
|
pythonImportsCheck = [ "chardet" ];
|
2017-09-05 11:16:41 +02:00
|
|
|
|
2021-01-11 08:54:33 +01:00
|
|
|
meta = with lib; {
|
2017-09-05 11:16:41 +02:00
|
|
|
description = "Universal encoding detector";
|
2021-03-22 18:50:31 +01:00
|
|
|
homepage = "https://github.com/chardet/chardet";
|
|
|
|
license = licenses.lgpl21Plus;
|
2017-09-05 11:16:41 +02:00
|
|
|
maintainers = with maintainers; [ domenkozar ];
|
|
|
|
};
|
|
|
|
}
|