2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
|
|
|
fetchPypi,
|
|
|
|
isPyPy,
|
|
|
|
pythonOlder,
|
|
|
|
|
|
|
|
# build-system
|
|
|
|
setuptools,
|
|
|
|
|
|
|
|
# tests
|
|
|
|
freezegun,
|
|
|
|
pytestCheckHook,
|
|
|
|
pytz,
|
|
|
|
tzdata,
|
2023-03-27 19:17:25 +00:00
|
|
|
}:
|
2022-05-18 14:49:53 +00:00
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "babel";
|
2024-07-27 06:49:29 +00:00
|
|
|
version = "2.15.0";
|
2024-01-13 08:15:51 +00:00
|
|
|
pyproject = true;
|
2023-03-27 19:17:25 +00:00
|
|
|
|
2022-11-21 17:40:18 +00:00
|
|
|
disabled = pythonOlder "3.7";
|
2022-05-18 14:49:53 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
2024-07-27 06:49:29 +00:00
|
|
|
inherit pname version;
|
|
|
|
hash = "sha256-ja8OJl0FdovGx6MUzxMh6aEjr8MozGNcGGIqLzCgRBM=";
|
2022-05-18 14:49:53 +00:00
|
|
|
};
|
|
|
|
|
2024-07-27 06:49:29 +00:00
|
|
|
build-system = [ setuptools ];
|
2023-03-27 19:17:25 +00:00
|
|
|
|
|
|
|
nativeCheckInputs = [
|
|
|
|
freezegun
|
|
|
|
pytestCheckHook
|
2023-07-15 17:15:38 +00:00
|
|
|
# https://github.com/python-babel/babel/issues/988#issuecomment-1521765563
|
2023-03-27 19:17:25 +00:00
|
|
|
pytz
|
2024-06-05 15:53:02 +00:00
|
|
|
] ++ lib.optionals isPyPy [ tzdata ];
|
2022-05-18 14:49:53 +00:00
|
|
|
|
2023-03-27 19:17:25 +00:00
|
|
|
disabledTests = [
|
|
|
|
# fails on days switching from and to daylight saving time in EST
|
|
|
|
# https://github.com/python-babel/babel/issues/988
|
|
|
|
"test_format_time"
|
|
|
|
];
|
2022-05-18 14:49:53 +00:00
|
|
|
|
2024-07-27 06:49:29 +00:00
|
|
|
pythonImportsCheck = [ "babel" ];
|
|
|
|
|
|
|
|
meta = {
|
|
|
|
description = "Collection of internationalizing tools";
|
2022-05-18 14:49:53 +00:00
|
|
|
homepage = "https://babel.pocoo.org/";
|
2023-03-27 19:17:25 +00:00
|
|
|
changelog = "https://github.com/python-babel/babel/releases/tag/v${version}";
|
2024-07-27 06:49:29 +00:00
|
|
|
license = lib.licenses.bsd3;
|
|
|
|
maintainers = with lib.maintainers; [ getchoo ];
|
2024-04-21 15:54:59 +00:00
|
|
|
mainProgram = "pybabel";
|
2022-05-18 14:49:53 +00:00
|
|
|
};
|
|
|
|
}
|