mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-22 06:53:01 +00:00
5f2d263670
Diff: https://github.com/lmfit/asteval/compare/refs/tags/1.0.4...1.0.5 Changelog: https://github.com/lmfit/asteval/releases/tag/1.0.5
48 lines
1.0 KiB
Nix
48 lines
1.0 KiB
Nix
{
|
|
lib,
|
|
buildPythonPackage,
|
|
fetchFromGitHub,
|
|
pytestCheckHook,
|
|
pythonOlder,
|
|
setuptools-scm,
|
|
}:
|
|
|
|
buildPythonPackage rec {
|
|
pname = "asteval";
|
|
version = "1.0.5";
|
|
pyproject = true;
|
|
|
|
disabled = pythonOlder "3.8";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "lmfit";
|
|
repo = "asteval";
|
|
rev = "refs/tags/${version}";
|
|
hash = "sha256-PRmTbP3zRnkCxdeb45LBz5m/Ymoi4lq2poKuG9Esg9g=";
|
|
};
|
|
|
|
postPatch = ''
|
|
substituteInPlace pyproject.toml \
|
|
--replace-fail "--cov=asteval --cov-report html" ""
|
|
'';
|
|
|
|
build-system = [ setuptools-scm ];
|
|
|
|
nativeCheckInputs = [ pytestCheckHook ];
|
|
|
|
pythonImportsCheck = [ "asteval" ];
|
|
|
|
disabledTests = [
|
|
# AssertionError: 'ImportError' != None
|
|
"test_set_default_nodehandler"
|
|
];
|
|
|
|
meta = with lib; {
|
|
description = "AST evaluator of Python expression using ast module";
|
|
homepage = "https://github.com/lmfit/asteval";
|
|
changelog = "https://github.com/lmfit/asteval/releases/tag/${version}";
|
|
license = with licenses; [ mit ];
|
|
maintainers = with maintainers; [ fab ];
|
|
};
|
|
}
|