Merge pull request #307098 from r-ryantm/auto-update/cilium-cli
[NixPkgs.git] / pkgs / development / python-modules / mypy / extensions.nix
blobe8622b84eb7c9ede4e62aa2273f6222fa6c433f5
1 { lib
2 , fetchFromGitHub
3 , buildPythonPackage
4 , typing
5 , pytestCheckHook
6 , pythonAtLeast
7 , pythonOlder
8 }:
10 buildPythonPackage rec {
11   pname = "mypy-extensions";
12   version = "1.0.0";
14   src = fetchFromGitHub {
15     owner = "python";
16     repo = "mypy_extensions";
17     rev = version;
18     hash = "sha256-gOfHC6dUeBE7SsWItpUHHIxW3wzhPM5SuGW1U8P7DD0=";
19   };
21   propagatedBuildInputs = lib.optional (pythonOlder "3.5") typing;
23   # make the testsuite run with pytest, so we can disable individual tests
24   nativeCheckInputs = [
25     pytestCheckHook
26   ];
28   pytestFlagsArray = [
29     "tests/testextensions.py"
30   ];
32   disabledTests = lib.optionals (pythonAtLeast "3.11") [
33     # https://github.com/python/mypy_extensions/issues/24
34     "test_typeddict_errors"
35   ];
37   pythonImportsCheck = [
38     "mypy_extensions"
39   ];
41   meta = with lib; {
42     description = "Experimental type system extensions for programs checked with the mypy typechecker";
43     homepage = "https://www.mypy-lang.org";
44     license = licenses.mit;
45     maintainers = with maintainers; [ lnl7 ];
46   };