From 6f67f8505181672ac2e29af6e8ef8763f63ada54 Mon Sep 17 00:00:00 2001 From: Simon Bruder Date: Sat, 23 Jul 2022 12:43:03 +0200 Subject: [PATCH] python3Packages.univers: init at 30.7.0 --- .../python-modules/univers/default.nix | 50 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 + 2 files changed, 52 insertions(+) create mode 100644 pkgs/development/python-modules/univers/default.nix diff --git a/pkgs/development/python-modules/univers/default.nix b/pkgs/development/python-modules/univers/default.nix new file mode 100644 index 000000000000..ca3f2b6ce445 --- /dev/null +++ b/pkgs/development/python-modules/univers/default.nix @@ -0,0 +1,50 @@ +{ lib +, fetchPypi +, fetchpatch +, buildPythonPackage +, setuptools-scm +, attrs +, packaging +, pyparsing +, semantic-version +, semver +, commoncode +, pytestCheckHook +, saneyaml +}: + +buildPythonPackage rec { + pname = "univers"; + version = "30.7.0"; + + src = fetchPypi { + inherit pname version; + sha256 = "sha256-yM0SDBpkiZEbaZ0ugjiMwwUFKqZGbmh1JNlv5qvPAYo="; + }; + + patches = [ + # Make tests work when not using virtualenv, can be dropped with the next version + # Upstream PR (already merged): https://github.com/nexB/univers/pull/77 + (fetchpatch { + url = "https://github.com/nexB/univers/commit/b74229cc1c8790287633cd7220d6b2e97c508302.patch"; + sha256 = "sha256-i6zWv9rAlwCMghd9g5FP6WIQLLDLYvp+6qJ1E7nfTSY="; + }) + ]; + + nativeBuildInputs = [ setuptools-scm ]; + propagatedBuildInputs = [ attrs packaging pyparsing semantic-version semver ]; + checkInputs = [ commoncode pytestCheckHook saneyaml ]; + + dontConfigure = true; # ./configure tries to setup virtualenv and downloads dependencies + + disabledTests = [ "test_codestyle" ]; + + pythonImportsCheck = [ "univers" ]; + + meta = with lib; { + description = "Library for parsing version ranges and expressions"; + homepage = "https://github.com/nexB/univers"; + license = with licenses; [ asl20 bsd3 mit ]; + maintainers = with maintainers; [ armijnhemel sbruder ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 7e36f7283157..d3b0e846ac6c 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -11011,6 +11011,8 @@ in { unittest-xml-reporting = callPackage ../development/python-modules/unittest-xml-reporting { }; + univers = callPackage ../development/python-modules/univers { }; + unpaddedbase64 = callPackage ../development/python-modules/unpaddedbase64 { }; unrardll = callPackage ../development/python-modules/unrardll { };