summaryrefslogtreecommitdiff
path: root/pkgs/development/python-modules/monkeytype/default.nix
blob: 195e5e72f434565df6dd360ccbb2e27b59982757 (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
{
  lib,
  buildPythonPackage,
  fetchFromGitHub,
  setuptools,
  libcst,
  mypy-extensions,
  pytestCheckHook,
}:

buildPythonPackage rec {
  pname = "monkeytype";
  version = "23.3.0";
  pyproject = true;

  src = fetchFromGitHub {
    owner = "Instagram";
    repo = "MonkeyType";
    tag = "v${version}";
    hash = "sha256-DQ/3go53+0PQkhZcL2dX8MI/z4Iq7kTYd5EbacMNxT4=";
  };

  build-system = [
    setuptools
  ];

  dependencies = [
    libcst
    mypy-extensions
  ];

  pythonImportsCheck = [
    "monkeytype"
  ];

  nativeCheckInputs = [
    pytestCheckHook
  ];

  disabledTests = [
    # Disable broken tests
    "test_excludes_site_packages"
    "test_callee_throws_recovers"
    "test_nested_callee_throws_recovers"
    "test_caller_handles_callee_exception"
    "test_generator_trace"
    "test_return_none"
    "test_access_property"
  ];

  meta = {
    description = "Python library that generates static type annotations by collecting runtime types";
    homepage = "https://github.com/Instagram/MonkeyType/";
    changelog = "https://github.com/Instagram/MonkeyType/blob/${src.rev}/CHANGES.rst";
    license = lib.licenses.bsd3;
    maintainers = [ ];
  };
}