mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-07-13 13:40:28 +03:00

Changelog: https://github.com/python/mypy_extensions/compare/1.0.0...1.1.0
The `test_py36_class_syntax_usage` test currently fails on Python 3.14.
It has been disabled for now.
Upstream replaced their `setup.py` why `pyproject.toml` in 6d9c7b756486a654e795095d393bf8206cd11dea [2].
The nix package has been adjusted accordingly.
In the same commit, upstream deprecated Python 3.7 support, and nixpkgs doesn't ship 3.5 or older anymore.
This means the conditional checking for 3.5 or older can be dropped.
Upstream also implicitly dropped python 2 support: The now-required flit-core does not support python 2.
The test failure on python 3.11+ [3] was fixed upstream in cd8b0c9c9561d806db4644d772e4ab43279d3d1a [4].
[1] https://github.com/python/mypy_extensions/issues/65
[2] 6d9c7b7564
[3] https://github.com/python/mypy_extensions/issues/24
[4] https://github.com/python/mypy_extensions/pull/28/commits/cd8b0c9c9561d806db4644d772e4ab43279d3d1a
42 lines
1 KiB
Nix
42 lines
1 KiB
Nix
{
|
|
lib,
|
|
fetchFromGitHub,
|
|
buildPythonPackage,
|
|
flit-core,
|
|
pytestCheckHook,
|
|
pythonAtLeast,
|
|
}:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "mypy-extensions";
|
|
version = "1.1.0";
|
|
pyproject = true;
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "python";
|
|
repo = "mypy_extensions";
|
|
tag = version;
|
|
hash = "sha256-HNAFsWX4tU9hfZkKxLNJn1J+H3uTesQflbRPlo3GQ4k=";
|
|
};
|
|
|
|
dependencies = [ flit-core ];
|
|
|
|
# make the testsuite run with pytest, so we can disable individual tests
|
|
nativeCheckInputs = [ pytestCheckHook ];
|
|
|
|
pytestFlagsArray = [ "tests/testextensions.py" ];
|
|
|
|
disabledTests = lib.optionals (pythonAtLeast "3.14") [
|
|
# https://github.com/python/mypy_extensions/issues/65
|
|
"test_py36_class_syntax_usage"
|
|
];
|
|
|
|
pythonImportsCheck = [ "mypy_extensions" ];
|
|
|
|
meta = {
|
|
description = "Experimental type system extensions for programs checked with the mypy typechecker";
|
|
homepage = "https://www.mypy-lang.org";
|
|
license = lib.licenses.mit;
|
|
maintainers = with lib.maintainers; [ lnl7 ];
|
|
};
|
|
}
|