biome: 1.9.2 -> 1.9.3 (#349335)
[NixPkgs.git] / pkgs / development / python-modules / wagtail-localize / default.nix
blob43aa722abdaad351e2887a2f573fc74ff4d58b72
2   lib,
3   buildPythonPackage,
4   dj-database-url,
5   django,
6   django-rq,
7   fetchFromGitHub,
8   flit-core,
9   freezegun,
10   google-cloud-translate,
11   polib,
12   python,
13   pythonOlder,
14   typing-extensions,
15   wagtail,
16   wagtail-modeladmin,
19 buildPythonPackage rec {
20   pname = "wagtail-localize";
21   version = "1.10";
22   pyproject = true;
24   disabled = pythonOlder "3.9";
26   src = fetchFromGitHub {
27     repo = "wagtail-localize";
28     owner = "wagtail";
29     rev = "refs/tags/v${version}";
30     hash = "sha256-khGzJj7LBxz5WPU8l20CmQjC9p5umk6spSyMMHBBguc=";
31   };
33   build-system = [ flit-core ];
35   dependencies = [
36     django
37     wagtail
38     polib
39     typing-extensions
40     wagtail-modeladmin
41   ];
43   nativeCheckInputs = [
44     dj-database-url
45     django-rq
46     freezegun
47     google-cloud-translate
48   ];
50   optional-dependencies = {
51     google = [ google-cloud-translate ];
52   };
54   checkPhase = ''
55     # test_translate_html fails with later Beautifulsoup releases
56     rm wagtail_localize/machine_translators/tests/test_dummy_translator.py
57     ${python.interpreter} testmanage.py test
58   '';
60   meta = with lib; {
61     description = "Translation plugin for Wagtail CMS";
62     homepage = "https://github.com/wagtail/wagtail-localize";
63     changelog = "https://github.com/wagtail/wagtail-localize/blob/v${version}/CHANGELOG.md";
64     license = licenses.bsd3;
65     maintainers = with maintainers; [ sephi ];
66   };