diff --git a/pkgs/development/python-modules/Mako/default.nix b/pkgs/development/python-modules/Mako/default.nix index 8aa3f687dded..694f3138c928 100644 --- a/pkgs/development/python-modules/Mako/default.nix +++ b/pkgs/development/python-modules/Mako/default.nix @@ -13,6 +13,8 @@ # tests , mock , pytestCheckHook +, lingua +, chameleon }: buildPythonPackage rec { @@ -37,8 +39,10 @@ buildPythonPackage rec { }; checkInputs = [ - pytestCheckHook + chameleon + lingua mock + pytestCheckHook ] ++ passthru.optional-dependencies.babel; disabledTests = lib.optionals isPyPy [ @@ -51,11 +55,6 @@ buildPythonPackage rec { "test_bytestring_passthru" ]; - disabledTestPaths = [ - # lingua dependency is not packaged - "test/ext/test_linguaplugin.py" - ]; - meta = with lib; { description = "Super-fast templating language"; homepage = "https://www.makotemplates.org/"; diff --git a/pkgs/development/python-modules/lingua/default.nix b/pkgs/development/python-modules/lingua/default.nix new file mode 100644 index 000000000000..f116df7e2fda --- /dev/null +++ b/pkgs/development/python-modules/lingua/default.nix @@ -0,0 +1,35 @@ +{ lib +, fetchPypi +, buildPythonPackage +, flit-core +, polib +, click }: + +buildPythonPackage rec { + pname = "lingua"; + version = "4.15.0"; + format = "pyproject"; + + src = fetchPypi { + inherit pname version; + sha256 = "sha256-DhqUZ0HbKIpANhrQT/OP4EvwgZg0uKu4TEtTX+2bpO8="; + }; + + nativeBuildInputs = [ + flit-core + ]; + + propagatedBuildInputs = [ + click + polib + ]; + + pythonImportsCheck = [ "lingua" ]; + + meta = with lib; { + description = "Translation toolset"; + homepage = "https://github.com/wichert/lingua"; + license = licenses.bsd3; + maintainers = with maintainers; [ np ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 850006795bca..6d65e1402ec6 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -5097,6 +5097,8 @@ in { line_profiler = callPackage ../development/python-modules/line_profiler { }; + lingua = callPackage ../development/python-modules/lingua { }; + linkify-it-py = callPackage ../development/python-modules/linkify-it-py { }; linode-api = callPackage ../development/python-modules/linode-api { };