commit:     7e4e025b8614a5c69be5eddce8984d7805c08c80
Author:     Patrick McLean <patrick.mclean <AT> sony <DOT> com>
AuthorDate: Thu Nov 21 23:18:19 2019 +0000
Commit:     Patrick McLean <chutzpah <AT> gentoo <DOT> org>
CommitDate: Thu Nov 21 23:55:12 2019 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=7e4e025b

dev-python/python-dateutil: Verbump to 2.8.1, add py38

Copyright: Sony Interactive Entertainment Inc.
Package-Manager: Portage-2.3.79, Repoman-2.3.18
Signed-off-by: Patrick McLean <chutzpah <AT> gentoo.org>

 dev-python/python-dateutil/Manifest                |  1 +
 .../python-dateutil-2.8.1-no-pytest-cov.patch      | 18 +++++++
 .../python-dateutil/python-dateutil-2.8.1.ebuild   | 59 ++++++++++++++++++++++
 3 files changed, 78 insertions(+)

diff --git a/dev-python/python-dateutil/Manifest 
b/dev-python/python-dateutil/Manifest
index 46398b25f55..2d1b643357b 100644
--- a/dev-python/python-dateutil/Manifest
+++ b/dev-python/python-dateutil/Manifest
@@ -5,3 +5,4 @@ DIST python-dateutil-2.7.3.tar.gz 302871 BLAKE2B 
8b6cff6f977d52b64665f33d10513a6
 DIST python-dateutil-2.7.4.tar.gz 302229 BLAKE2B 
e2a43d8587f895a9a72ca5ab5c18a5c471497c8f8e89459450219e9f5ecb55223f36f219d77df8da4c04d55fb5feb3a17f9a5c2318c077dac4307da7c0bd9645
 SHA512 
3b02b397e3138dc755f34a2f7a50464f96a73b7be1f335ce7da3fa99e6d59f34a0643dfb1c933d4ef4fbaab88364fab6e760e4b1e7040b8cbbfebdd75e7e9a4f
 DIST python-dateutil-2.7.5.tar.gz 316043 BLAKE2B 
29511f7e484c369084d696f45a07e01e096e7b1114f982026f8df71d569eea30d657956d3e53725ad57564c1e445414c2ed543e3e6d2dd89902d7838cbb9e6fe
 SHA512 
762752191d584a3995b55bbcfadc829261a263e0e6515a52db2fc32157bf0b3f96f787107c49bbd77cab9ce7e3f692ab3e8f392260fc18e6456b74eb190b44d3
 DIST python-dateutil-2.8.0.tar.gz 327134 BLAKE2B 
6525eee57aeaef3c588413210df7c1ad3627a380c6e44af78e9acc9abea523b29e8d9afec495f8d1e585d25d32ab82e6e28bf93dca148893d2e6a533e1f4ce47
 SHA512 
ec7da86203572582f883a4686acf8a732a2de4f396d809057eb51b2c60dbca5623a7fa90c2c0618c281a2282c60841739bd837731a51cc876f4ff369297f2f81
+DIST python-dateutil-2.8.1.tar.gz 331745 BLAKE2B 
9785fe93976d9bbe21d6610133e37e558cdde4062a1a738ccbf2bf80aa062882ba59c60f2b9bfc44c53e0f8fc4b5ebdd5d12b6ba54a60706576360e453b2f160
 SHA512 
337000216e0f8ce32d6363768444144183ab9268f69082f20858f2b3322b1c449e53b2f2b5dcb3645be22294659ce7838f74ace2fd7a7c4f2adc6cf806a9fa2c

diff --git 
a/dev-python/python-dateutil/files/python-dateutil-2.8.1-no-pytest-cov.patch 
b/dev-python/python-dateutil/files/python-dateutil-2.8.1-no-pytest-cov.patch
new file mode 100644
index 00000000000..84adb944548
--- /dev/null
+++ b/dev-python/python-dateutil/files/python-dateutil-2.8.1-no-pytest-cov.patch
@@ -0,0 +1,18 @@
+diff --git a/dateutil/test/conftest.py b/dateutil/test/conftest.py
+index 78ed70a..4bb4c0a 100644
+--- a/dateutil/test/conftest.py
++++ b/dateutil/test/conftest.py
+@@ -14,10 +14,11 @@ def pytest_collection_modifyitems(items):
+ 
+         marker = marker_getter('xfail')
+ 
++        # requires pytest-cov
+         # Need to query the args because conditional xfail tests still have
+         # the xfail mark even if they are not expected to fail
+-        if marker and (not marker.args or marker.args[0]):
+-            item.add_marker(pytest.mark.no_cover)
++        #if marker and (not marker.args or marker.args[0]):
++        #    item.add_marker(pytest.mark.no_cover)
+ 
+ 
+ def set_tzpath():

diff --git a/dev-python/python-dateutil/python-dateutil-2.8.1.ebuild 
b/dev-python/python-dateutil/python-dateutil-2.8.1.ebuild
new file mode 100644
index 00000000000..f2c9ffa8ab9
--- /dev/null
+++ b/dev-python/python-dateutil/python-dateutil-2.8.1.ebuild
@@ -0,0 +1,59 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+PYTHON_COMPAT=( python{2_7,3_{5,6,7,8}} pypy{,3} )
+
+inherit distutils-r1
+
+DESCRIPTION="Extensions to the standard Python datetime module"
+HOMEPAGE="
+       https://dateutil.readthedocs.org/
+       https://pypi.org/project/python-dateutil
+       https://github.com/dateutil/dateutil/
+"
+SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 
~sh ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-macos"
+IUSE="test"
+
+RDEPEND="
+       >=dev-python/six-1.5[${PYTHON_USEDEP}]
+       sys-libs/timezone-data
+"
+BDEPEND="${RDEPEND}
+       dev-python/setuptools[${PYTHON_USEDEP}]
+       test? (
+               dev-python/freezegun[${PYTHON_USEDEP}]
+               dev-python/hypothesis[${PYTHON_USEDEP}]
+       )
+"
+
+RESTRICT="!test? ( test )"
+
+PATCHES=(
+       
"${FILESDIR}/0001-zoneinfo-Get-timezone-data-from-system-tzdata-r1.patch"
+       "${FILESDIR}/python-dateutil-2.8.1-no-pytest-cov.patch"
+)
+
+distutils_enable_tests pytest
+
+python_prepare_all() {
+       # avoid a setuptools_scm dependency
+       sed -i "s:use_scm_version=True:version='${PV}':" setup.py || die
+
+       # don't install zoneinfo tarball
+       sed -i '/package_data=/d' setup.py || die
+
+       distutils-r1_python_prepare_all
+}
+
+python_prepare() {
+       if [[ ${EPYTHON} == python3.7 ]]; then
+               # these tests are flakey on 3.7
+               rm dateutil/test/property/test_{parser,isoparse}_prop.py || die
+       fi
+}

Reply via email to