From b574f9fc3306de406ba59b0ff8fdbb812c57f66b Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Tue, 9 Nov 2021 09:13:46 +0100 Subject: [PATCH] python3Packages.agate: 1.6.1 -> 1.6.3 --- .../python-modules/agate/default.nix | 66 ++++++++++++++----- 1 file changed, 51 insertions(+), 15 deletions(-) diff --git a/pkgs/development/python-modules/agate/default.nix b/pkgs/development/python-modules/agate/default.nix index a2b622dd2116..04266bc3d883 100644 --- a/pkgs/development/python-modules/agate/default.nix +++ b/pkgs/development/python-modules/agate/default.nix @@ -1,37 +1,73 @@ -{ lib, fetchFromGitHub, buildPythonPackage, isPy3k -, six, pytimeparse, parsedatetime, Babel -, isodate, python-slugify, leather -, glibcLocales, nose, lxml, cssselect, unittest2 }: +{ lib +, Babel +, buildPythonPackage +, cssselect +, fetchFromGitHub +, glibcLocales +, isodate +, leather +, lxml +, nose +, parsedatetime +, PyICU +, python-slugify +, pytimeparse +, pythonOlder +, pytz +, six +}: buildPythonPackage rec { pname = "agate"; - version = "1.6.1"; + version = "1.6.3"; + format = "setuptools"; + + disabled = pythonOlder "3.6"; - # PyPI tarball does not include all test files - # https://github.com/wireservice/agate/pull/716 src = fetchFromGitHub { owner = "wireservice"; repo = pname; rev = version; - sha256 = "077zj8xad8hsa3nqywvf7ircirmx3krxdipl8wr3dynv3l3khcpl"; + sha256 = "sha256-tuUoLvztCYHIPJTBgw1eByM0zfaHDyc+h7SWsxutKos="; }; propagatedBuildInputs = [ - six pytimeparse parsedatetime Babel - isodate python-slugify leather + Babel + isodate + leather + parsedatetime + python-slugify + pytimeparse + six ]; - checkInputs = [ glibcLocales nose lxml cssselect ] - ++ lib.optional (!isPy3k) unittest2; + checkInputs = [ + cssselect + glibcLocales + lxml + nose + PyICU + pytz + ]; + + postPatch = '' + # No Python 2 support, thus constraint is not needed + substituteInPlace setup.py \ + --replace "'parsedatetime>=2.1,!=2.5,!=2.6'," "'parsedatetime>=2.1'," + ''; checkPhase = '' LC_ALL="en_US.UTF-8" nosetests tests ''; + pythonImportsCheck = [ + "agate" + ]; + meta = with lib; { - description = "A Python data analysis library that is optimized for humans instead of machines"; - homepage = "https://github.com/wireservice/agate"; - license = with licenses; [ mit ]; + description = "Python data analysis library that is optimized for humans instead of machines"; + homepage = "https://github.com/wireservice/agate"; + license = with licenses; [ mit ]; maintainers = with maintainers; [ vrthra ]; }; }