2021-09-18 10:52:07 +00:00
|
|
|
{ lib
|
|
|
|
, fetchPypi
|
|
|
|
, buildPythonPackage
|
|
|
|
, setuptools-scm
|
|
|
|
, six
|
|
|
|
, astroid
|
|
|
|
, pytestCheckHook
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "asttokens";
|
2021-09-18 10:52:07 +00:00
|
|
|
version = "2.0.5";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2021-09-18 10:52:07 +00:00
|
|
|
sha256 = "sha256-mlTBFPAsepSA1WVQkyVGo/H+cdigLxvHzNDuPuNc9NU=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2021-09-18 10:52:07 +00:00
|
|
|
nativeBuildInputs = [
|
|
|
|
setuptools-scm
|
2021-03-20 04:20:00 +00:00
|
|
|
];
|
|
|
|
|
2021-09-18 10:52:07 +00:00
|
|
|
propagatedBuildInputs = [
|
|
|
|
six
|
|
|
|
];
|
|
|
|
|
|
|
|
checkInputs = [
|
2022-04-27 09:35:20 +00:00
|
|
|
astroid
|
2021-09-18 10:52:07 +00:00
|
|
|
pytestCheckHook
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-10-01 09:20:50 +00:00
|
|
|
disabledTests = [
|
|
|
|
# Test is currently failing on Hydra, works locally
|
|
|
|
"test_slices"
|
|
|
|
];
|
|
|
|
|
2022-04-27 09:35:20 +00:00
|
|
|
disabledTestPaths = [
|
|
|
|
# incompatible with astroid 2.11.0, pins <= 2.5.3
|
|
|
|
"tests/test_astroid.py"
|
|
|
|
];
|
|
|
|
|
2021-09-18 10:52:07 +00:00
|
|
|
pythonImportsCheck = [ "asttokens" ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
homepage = "https://github.com/gristlabs/asttokens";
|
|
|
|
description = "Annotate Python AST trees with source text and token information";
|
|
|
|
license = licenses.asl20;
|
|
|
|
maintainers = with maintainers; [ leenaars ];
|
|
|
|
};
|
|
|
|
}
|