diff --git a/pkgs/development/python-modules/periodictable/default.nix b/pkgs/development/python-modules/periodictable/default.nix index 31b5b0a4500f..1bde32797813 100644 --- a/pkgs/development/python-modules/periodictable/default.nix +++ b/pkgs/development/python-modules/periodictable/default.nix @@ -1,38 +1,47 @@ { lib, - fetchPypi, + fetchFromGitHub, buildPythonPackage, + setuptools, numpy, pyparsing, + pytest-cov-stub, pytestCheckHook, pythonOlder, }: buildPythonPackage rec { pname = "periodictable"; - version = "1.7.1"; - format = "setuptools"; + version = "2.0.2"; + pyproject = true; - disabled = pythonOlder "3.7"; + disabled = pythonOlder "3.8"; - src = fetchPypi { - inherit pname version; - hash = "sha256-Q9fbcjPWszli+D156lT0fDuSPT6DQDy8A/WPNTr0tSw="; + src = fetchFromGitHub { + owner = "python-periodictable"; + repo = "periodictable"; + tag = "v${version}"; + hash = "sha256-nI6hiLnqmVXT06pPkHCBEMTxZhfnZJqSImW3V9mJ4+8="; }; - propagatedBuildInputs = [ + build-system = [ setuptools ]; + + dependencies = [ numpy pyparsing ]; - nativeCheckInputs = [ pytestCheckHook ]; + nativeCheckInputs = [ + pytest-cov-stub + pytestCheckHook + ]; pythonImportsCheck = [ "periodictable" ]; - meta = with lib; { + meta = { description = "Extensible periodic table of the elements"; homepage = "https://github.com/pkienzle/periodictable"; - license = licenses.publicDomain; - maintainers = with maintainers; [ rprospero ]; + license = lib.licenses.publicDomain; + maintainers = with lib.maintainers; [ rprospero ]; }; }