limo: 1.0.11 > 1.1 (#376325)
[NixPkgs.git] / pkgs / development / python-modules / ase / default.nix
blobfb8dcd8a5998797f033e413cbf10a5d28f3d216d
2   lib,
3   stdenv,
4   fetchPypi,
5   fetchpatch2,
6   buildPythonPackage,
7   isPy27,
8   pythonAtLeast,
9   setuptools,
10   numpy,
11   scipy,
12   matplotlib,
13   flask,
14   pillow,
15   psycopg2,
16   tkinter,
17   pytestCheckHook,
18   pytest-mock,
19   pytest-xdist,
22 buildPythonPackage rec {
23   pname = "ase";
24   version = "3.23.0";
25   pyproject = true;
27   disabled = isPy27;
29   src = fetchPypi {
30     inherit pname version;
31     hash = "sha256-kaKqMdib2QsO/f5KfoQmTzKCiyq/yfOOZeBBrXb+yK4=";
32   };
34   patches = [
35     # https://gitlab.com/ase/ase/-/merge_requests/3400
36     (fetchpatch2 {
37       name = "numpy_2-compatibility.patch";
38       url = "https://gitlab.com/ase/ase/-/commit/5434193ad9dd2cb20a76b3d503fa2b50d7a8ed34.patch";
39       excludes = [ "pyproject.toml" ];
40       hash = "sha256-3hsyzYnFCrlZDT/jqJKKvj2UXjnjLU0U6PJqgOpA7CU=";
41     })
42   ];
44   build-system = [ setuptools ];
46   dependencies =
47     [
48       numpy
49       scipy
50       matplotlib
51       flask
52       pillow
53       psycopg2
54     ]
55     ++ lib.optionals stdenv.hostPlatform.isDarwin [
56       tkinter
57     ];
59   nativeCheckInputs = [
60     pytestCheckHook
61     pytest-mock
62     pytest-xdist
63   ];
65   disabledTests = [
66     "test_fundamental_params"
67     "test_ase_bandstructure"
68     "test_imports"
69     "test_units"
70     "test_favicon"
71     "test_vibrations_methods" # missing attribute
72     "test_jmol_roundtrip" # missing attribute
73     "test_pw_input_write_nested_flat" # Did not raise DeprecationWarning
74     "test_fix_scaled" # Did not raise UserWarning
75   ] ++ lib.optionals (pythonAtLeast "3.12") [ "test_info_calculators" ];
77   preCheck = ''
78     export PATH="$out/bin:$PATH"
79   '';
81   pythonImportsCheck = [ "ase" ];
83   meta = with lib; {
84     description = "Atomic Simulation Environment";
85     homepage = "https://wiki.fysik.dtu.dk/ase/";
86     license = licenses.lgpl21Plus;
87     maintainers = [ ];
88   };