depot/third_party/nixpkgs/pkgs/development/python-modules/setuptools-scm/default.nix
Default email 5e9e1146e1 Project import generated by Copybara.
GitOrigin-RevId: 18036c0be90f4e308ae3ebcab0e14aae0336fe42
2023-08-05 00:07:22 +02:00

54 lines
1 KiB
Nix

{ buildPythonPackage
, callPackage
, fetchPypi
, packaging
, typing-extensions
, tomli
, setuptools
, pythonOlder
, lib
}:
buildPythonPackage rec {
pname = "setuptools-scm";
version = "7.1.0";
format = "pyproject";
src = fetchPypi {
pname = "setuptools_scm";
inherit version;
hash = "sha256-bFCDRadxqtfVbr/w5wYovysOx1c3Yr6ZYCFHMN4njyc=";
};
nativeBuildInputs = [
packaging
setuptools
typing-extensions
];
propagatedBuildInputs = [
packaging
setuptools
typing-extensions
] ++ lib.optionals (pythonOlder "3.11") [
tomli
];
pythonImportsCheck = [
"setuptools_scm"
];
# check in passthru.tests.pytest to escape infinite recursion on pytest
doCheck = false;
passthru.tests = {
pytest = callPackage ./tests.nix { };
};
meta = with lib; {
homepage = "https://github.com/pypa/setuptools_scm/";
description = "Handles managing your python package versions in scm metadata";
license = licenses.mit;
maintainers = with maintainers; [ nickcao ];
};
}