summaryrefslogtreecommitdiff
path: root/pkgs/development/python-modules/pyface/default.nix
blob: 1131e47359396d7e5535f63218b9794e685cb93a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
{
  lib,
  fetchFromGitHub,
  buildPythonPackage,
  numpy,
  pillow,
  pygments,
  pyqt5,
  pyqt6,
  pyside2,
  pyside6,
  pytestCheckHook,
  setuptools,
  traits,
  traitsui,
  writableTmpDirAsHomeHook,
  wxpython,
}:

buildPythonPackage (finalAttrs: {
  pname = "pyface";
  version = "8.0.0";
  pyproject = true;

  src = fetchFromGitHub {
    owner = "enthought";
    repo = "pyface";
    tag = finalAttrs.version;
    hash = "sha256-i97cosaFc5GTv5GJgpx1xc81mir/IWljSrAORUapymM=";
  };

  build-system = [ setuptools ];

  dependencies = [
    traits
  ];

  optional-dependencies = {
    pillow = [ pillow ];
    pyqt5 = [
      pygments
      pyqt5
    ];
    pyqt6 = [
      pygments
      pyqt6
    ];
    pyside2 = [
      pygments
      pyside2
    ];
    pyside6 = [
      pygments
      pyside6
    ];
    numpy = [ numpy ];
    traitsui = [ traitsui ];
    wx = [
      wxpython
      numpy
    ];
  };

  nativeCheckInputs = [
    pytestCheckHook
    writableTmpDirAsHomeHook
  ];

  enabledTestPaths = "pyface/tests";

  disabledTestPaths = [
    # tests need an X server
    "pyface/tests/test_beep.py"
    "pyface/tests/test_clipboard.py"
    "pyface/tests/test_font.py"
    "pyface/tests/test_image_cache.py"
    "pyface/tests/test_image_resource.py"
    "pyface/tests/test_system_metrics.py"
    "pyface/tests/test_widget.py"
  ];

  pythonImportsCheck = [ "pyface" ];

  meta = {
    description = "Traits-capable windowing framework";
    homepage = "https://github.com/enthought/pyface";
    changelog = "https://github.com/enthought/pyface/releases/tag/${finalAttrs.src.tag}";
    maintainers = [ ];
    license = lib.licenses.bsdOriginal;
  };
})