1{ lib
2, stdenv
3, buildPythonPackage
4, pythonOlder
5, fetchFromGitHub
6, colorama
7, django
8, docopt
9, pytestCheckHook
10, parso
11}:
12
13buildPythonPackage rec {
14 pname = "jedi";
15 version = "0.18.0";
16 disabled = pythonOlder "3.6";
17
18 src = fetchFromGitHub {
19 owner = "davidhalter";
20 repo = "jedi";
21 rev = "v${version}";
22 sha256 = "0d8zdj56hyxbsvvrid6r3nprm0ygxaad6zpsbhbj6k7p3dcx7acw";
23 fetchSubmodules = true;
24 };
25
26 propagatedBuildInputs = [ parso ];
27
28 checkInputs = [
29 colorama
30 django
31 docopt
32 pytestCheckHook
33 ];
34
35 preCheck = ''
36 export HOME=$TMPDIR
37 '';
38
39 disabledTests = [
40 # Assertions mismatches with pytest>=6.0
41 "test_completion"
42
43 # sensitive to platform, causes false negatives on darwin
44 "test_import"
45 ] ++ lib.optionals (stdenv.isAarch64 && pythonOlder "3.9") [
46 # AssertionError: assert 'foo' in ['setup']
47 "test_init_extension_module"
48 ];
49
50 meta = with lib; {
51 homepage = "https://github.com/davidhalter/jedi";
52 description = "An autocompletion tool for Python that can be used for text editors";
53 license = licenses.lgpl3Plus;
54 maintainers = with maintainers; [ ];
55 };
56}