* [gentoo-commits] repo/gentoo:master commit in: dev-python/tappy/, dev-python/tappy/files/
@ 2020-04-23 11:23 Michał Górny
0 siblings, 0 replies; 3+ messages in thread
From: Michał Górny @ 2020-04-23 11:23 UTC (permalink / raw
To: gentoo-commits
commit: 3a78d40a6fc15db6326c1c5d36cbed78860dc7ec
Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Thu Apr 23 11:12:54 2020 +0000
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Thu Apr 23 11:23:32 2020 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=3a78d40a
dev-python/tappy: Fix pyyaml usage
Closes: https://bugs.gentoo.org/701158
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>
dev-python/tappy/files/tappy-2.4-yaml.patch | 61 ++++++++++++++++++++++
.../{tappy-2.4.ebuild => tappy-2.4-r1.ebuild} | 13 +++--
2 files changed, 67 insertions(+), 7 deletions(-)
diff --git a/dev-python/tappy/files/tappy-2.4-yaml.patch b/dev-python/tappy/files/tappy-2.4-yaml.patch
new file mode 100644
index 00000000000..dee5055ec2f
--- /dev/null
+++ b/dev-python/tappy/files/tappy-2.4-yaml.patch
@@ -0,0 +1,61 @@
+From 62205d0bb2427016938e00fe8e53aed7a947a20d Mon Sep 17 00:00:00 2001
+From: Matt Layman <matthewlayman@gmail.com>
+Date: Sat, 14 Dec 2019 21:20:22 -0500
+Subject: [PATCH] Use PyYAML safe loader and remove deprecation warning. (#103)
+
+Fixes #102
+---
+ tap/line.py | 2 +-
+ tap/tests/test_parser.py | 6 +++---
+ 2 files changed, 4 insertions(+), 4 deletions(-)
+
+(mgorny: rebased for 2.4 and included test fixes that are part
+ of irrelevant commit upstream)
+
+diff --git a/tap/line.py b/tap/line.py
+index 352bc1b..c4d0ca6 100644
+--- a/tap/line.py
++++ b/tap/line.py
+@@ -88,7 +88,7 @@ class Result(Line):
+ """
+ if LOAD_YAML and self._yaml_block is not None:
+ try:
+- yaml_dict = yaml.load(self._yaml_block)
++ yaml_dict = yaml.load(self._yaml_block, Loader=yaml.SafeLoader)
+ return yaml_dict
+ except yaml.error.YAMLError:
+ print('Error parsing yaml block. Check formatting.')
+diff --git a/tap/tests/test_parser.py b/tap/tests/test_parser.py
+index 4e919d1..1e78039 100644
+--- a/tap/tests/test_parser.py
++++ b/tap/tests/test_parser.py
+@@ -235,7 +235,7 @@ class TestParser(unittest.TestCase):
+ try:
+ import yaml
+ from more_itertools import peekable # noqa
+- converted_yaml = yaml.load(u"""test: sample yaml""")
++ converted_yaml = yaml.safe_load(u"""test: sample yaml""")
+ self.assertEqual(4, len(lines))
+ self.assertEqual(13, lines[0].version)
+ self.assertEqual(converted_yaml, lines[2].yaml_block)
+@@ -265,7 +265,7 @@ class TestParser(unittest.TestCase):
+ try:
+ import yaml
+ from more_itertools import peekable # noqa
+- converted_yaml = yaml.load(u"""test: sample yaml""")
++ converted_yaml = yaml.safe_load(u"""test: sample yaml""")
+ self.assertEqual(4, len(lines))
+ self.assertEqual(13, lines[0].version)
+ self.assertEqual(converted_yaml, lines[2].yaml_block)
+@@ -300,7 +300,7 @@ class TestParser(unittest.TestCase):
+ try:
+ import yaml
+ from more_itertools import peekable # noqa
+- converted_yaml = yaml.load(u"""
++ converted_yaml = yaml.safe_load(u"""
+ message: test
+ severity: fail
+ data:
+--
+2.26.2
+
diff --git a/dev-python/tappy/tappy-2.4.ebuild b/dev-python/tappy/tappy-2.4-r1.ebuild
similarity index 83%
rename from dev-python/tappy/tappy-2.4.ebuild
rename to dev-python/tappy/tappy-2.4-r1.ebuild
index 7cffc97077f..31c7271620f 100644
--- a/dev-python/tappy/tappy-2.4.ebuild
+++ b/dev-python/tappy/tappy-2.4-r1.ebuild
@@ -10,12 +10,12 @@ MY_PN=tap.py
DESCRIPTION="Test Anything Protocol (TAP) tools"
HOMEPAGE="https://github.com/python-tap/tappy https://pypi.org/project/tap.py/"
SRC_URI="mirror://pypi/${MY_PN::1}/${MY_PN}/${MY_PN}-${PV}.tar.gz"
+S=${WORKDIR}/${MY_PN}-${PV}
LICENSE="BSD-2"
SLOT="0"
KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 sparc ~x86"
-IUSE="test yaml"
-RESTRICT="!test? ( test )"
+IUSE="yaml"
RDEPEND="dev-python/setuptools[${PYTHON_USEDEP}]
yaml? (
@@ -23,7 +23,6 @@ RDEPEND="dev-python/setuptools[${PYTHON_USEDEP}]
dev-python/pyyaml[${PYTHON_USEDEP}]
)"
DEPEND="dev-python/Babel[${PYTHON_USEDEP}]
- dev-python/setuptools[${PYTHON_USEDEP}]
test? (
dev-python/more-itertools[${PYTHON_USEDEP}]
dev-python/pyyaml[${PYTHON_USEDEP}]
@@ -32,8 +31,8 @@ DEPEND="dev-python/Babel[${PYTHON_USEDEP}]
' -2)
)"
-S=${WORKDIR}/${MY_PN}-${PV}
+distutils_enable_tests unittest
-python_test() {
- "${EPYTHON}" -m unittest discover -v || die "Tests fail with ${EPYTHON}"
-}
+PATCHES=(
+ "${FILESDIR}"/${P}-yaml.patch
+)
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: dev-python/tappy/, dev-python/tappy/files/
@ 2020-06-05 22:43 Andreas Sturmlechner
0 siblings, 0 replies; 3+ messages in thread
From: Andreas Sturmlechner @ 2020-06-05 22:43 UTC (permalink / raw
To: gentoo-commits
commit: ff33740c698bddcdb44a8b72d90b667ca06e82d4
Author: Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
AuthorDate: Fri Jun 5 17:41:51 2020 +0000
Commit: Andreas Sturmlechner <asturm <AT> gentoo <DOT> org>
CommitDate: Fri Jun 5 22:42:07 2020 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ff33740c
dev-python/tappy: 2.6.2 version bump w/ python3_9
Last version w/ py2 support. Tests passed.
Package-Manager: Portage-2.3.100, Repoman-2.3.22
Signed-off-by: Andreas Sturmlechner <asturm <AT> gentoo.org>
dev-python/tappy/Manifest | 1 +
dev-python/tappy/files/tappy-2.6.2-yaml.patch | 37 +++++++++++++++++++++++++
dev-python/tappy/tappy-2.6.2.ebuild | 40 +++++++++++++++++++++++++++
3 files changed, 78 insertions(+)
diff --git a/dev-python/tappy/Manifest b/dev-python/tappy/Manifest
index 0badd7a7948..6e4e73d34bf 100644
--- a/dev-python/tappy/Manifest
+++ b/dev-python/tappy/Manifest
@@ -1,2 +1,3 @@
DIST tap.py-2.4.tar.gz 145440 BLAKE2B 1c6effe086c50cb8b11355db0439207330446a245c42420a948e1c3ff8caf917d9a76ea00f231199a5bd79e7396bcd2a904b764ffa1db611c57947274095a0b9 SHA512 7c843c40f0029bb122fdafec0f5416164b77fac69142c2308a6d815f2f409cddb33c5a08547409e278f06036e21cb2a53cbd3263c23f59c6618c12c201b8209c
+DIST tap.py-2.6.2.tar.gz 148974 BLAKE2B 5e33c7af37c2533b4fd5b45684cc93793027b50c09fde34a4a8ff80c58510a50f5f21295852c14bef506c783cae6293bae521c5fdd696752c221cc49c7d2713e SHA512 2cd0b1b69f155970cf2367766cca96bc8391e074edc754531f0511c3dd027a0a8e95bb8481b627b2610ec9b5f685ebff95f07f5f97eb31c321d96590286be803
DIST tap.py-3.0.tar.gz 141764 BLAKE2B 0d65d9c0691deef31475cf6db172e41340e112cacda240d32a55338665632613f09c98d0c7dcfbf28be997079f789054d71f1059fb74228507041163df9710a1 SHA512 58b0928dd28ba525d9bb5edfab5606cb67af15e75a5f03d2648280d30377e2aa23b314ed41dba3b09b7dfa1aefead53674df43b6087e552b9aa937472838e7db
diff --git a/dev-python/tappy/files/tappy-2.6.2-yaml.patch b/dev-python/tappy/files/tappy-2.6.2-yaml.patch
new file mode 100644
index 00000000000..791ac3bc7b9
--- /dev/null
+++ b/dev-python/tappy/files/tappy-2.6.2-yaml.patch
@@ -0,0 +1,37 @@
+From 116aa55f5d1ae1f82604ae377e07a751f61bb651 Mon Sep 17 00:00:00 2001
+From: Matt Layman <matthewlayman@gmail.com>
+Date: Sat, 14 Dec 2019 21:20:22 -0500
+Subject: [PATCH] Use PyYAML safe loader and remove deprecation warning. (#103)
+
+Fixes #102
+---
+ setup.py | 2 +-
+ tap/line.py | 2 +-
+ 2 files changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/setup.py b/setup.py
+index 2d001da..4c59879 100644
+--- a/setup.py
++++ b/setup.py
+@@ -63,7 +63,7 @@ def run(self):
+ zip_safe=False,
+ platforms="any",
+ install_requires=[],
+- extras_require={"yaml": ["more-itertools", "PyYAML"]},
++ extras_require={"yaml": ["more-itertools", "PyYAML>=5.1"]},
+ classifiers=[
+ "Development Status :: 5 - Production/Stable",
+ "Environment :: Console",
+diff --git a/tap/line.py b/tap/line.py
+index 0d44ff8..fc8f8e2 100644
+--- a/tap/line.py
++++ b/tap/line.py
+@@ -96,7 +96,7 @@ def yaml_block(self):
+ """
+ if LOAD_YAML and self._yaml_block is not None:
+ try:
+- yaml_dict = yaml.load(self._yaml_block)
++ yaml_dict = yaml.load(self._yaml_block, Loader=yaml.SafeLoader)
+ return yaml_dict
+ except yaml.error.YAMLError:
+ print("Error parsing yaml block. Check formatting.")
diff --git a/dev-python/tappy/tappy-2.6.2.ebuild b/dev-python/tappy/tappy-2.6.2.ebuild
new file mode 100644
index 00000000000..de2c6cdf8f8
--- /dev/null
+++ b/dev-python/tappy/tappy-2.6.2.ebuild
@@ -0,0 +1,40 @@
+# Copyright 1999-2020 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+DISTUTILS_USE_SETUPTOOLS=rdepend
+PYTHON_COMPAT=( python2_7 python3_{6,7,8,9} )
+inherit distutils-r1
+
+MY_PN=tap.py
+DESCRIPTION="Test Anything Protocol (TAP) tools"
+HOMEPAGE="https://github.com/python-tap/tappy https://pypi.org/project/tap.py/"
+SRC_URI="mirror://pypi/${MY_PN::1}/${MY_PN}/${MY_PN}-${PV}.tar.gz"
+S=${WORKDIR}/${MY_PN}-${PV}
+
+LICENSE="BSD-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86"
+IUSE="yaml"
+
+RDEPEND="
+ yaml? (
+ dev-python/more-itertools[${PYTHON_USEDEP}]
+ dev-python/pyyaml[${PYTHON_USEDEP}]
+ )"
+BDEPEND="
+ dev-python/Babel[${PYTHON_USEDEP}]
+ test? (
+ dev-python/more-itertools[${PYTHON_USEDEP}]
+ dev-python/pyyaml[${PYTHON_USEDEP}]
+ $(python_gen_cond_dep '
+ dev-python/mock[${PYTHON_USEDEP}]
+ ' -2)
+ )"
+
+distutils_enable_tests unittest
+
+PATCHES=(
+ "${FILESDIR}"/${P}-yaml.patch
+)
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: dev-python/tappy/, dev-python/tappy/files/
@ 2020-09-20 8:16 Michał Górny
0 siblings, 0 replies; 3+ messages in thread
From: Michał Górny @ 2020-09-20 8:16 UTC (permalink / raw
To: gentoo-commits
commit: 537251fddbae481e1c0df76883ff278c966d36d5
Author: Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Sun Sep 20 08:13:58 2020 +0000
Commit: Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Sun Sep 20 08:16:47 2020 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=537251fd
dev-python/tappy: Remove old
Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>
dev-python/tappy/Manifest | 1 -
dev-python/tappy/files/tappy-2.6.2-yaml.patch | 37 -------------------------
dev-python/tappy/tappy-2.6.2.ebuild | 40 ---------------------------
3 files changed, 78 deletions(-)
diff --git a/dev-python/tappy/Manifest b/dev-python/tappy/Manifest
index 7bfa319b971..74f6caad135 100644
--- a/dev-python/tappy/Manifest
+++ b/dev-python/tappy/Manifest
@@ -1,2 +1 @@
-DIST tap.py-2.6.2.tar.gz 148974 BLAKE2B 5e33c7af37c2533b4fd5b45684cc93793027b50c09fde34a4a8ff80c58510a50f5f21295852c14bef506c783cae6293bae521c5fdd696752c221cc49c7d2713e SHA512 2cd0b1b69f155970cf2367766cca96bc8391e074edc754531f0511c3dd027a0a8e95bb8481b627b2610ec9b5f685ebff95f07f5f97eb31c321d96590286be803
DIST tap.py-3.0.tar.gz 141764 BLAKE2B 0d65d9c0691deef31475cf6db172e41340e112cacda240d32a55338665632613f09c98d0c7dcfbf28be997079f789054d71f1059fb74228507041163df9710a1 SHA512 58b0928dd28ba525d9bb5edfab5606cb67af15e75a5f03d2648280d30377e2aa23b314ed41dba3b09b7dfa1aefead53674df43b6087e552b9aa937472838e7db
diff --git a/dev-python/tappy/files/tappy-2.6.2-yaml.patch b/dev-python/tappy/files/tappy-2.6.2-yaml.patch
deleted file mode 100644
index 791ac3bc7b9..00000000000
--- a/dev-python/tappy/files/tappy-2.6.2-yaml.patch
+++ /dev/null
@@ -1,37 +0,0 @@
-From 116aa55f5d1ae1f82604ae377e07a751f61bb651 Mon Sep 17 00:00:00 2001
-From: Matt Layman <matthewlayman@gmail.com>
-Date: Sat, 14 Dec 2019 21:20:22 -0500
-Subject: [PATCH] Use PyYAML safe loader and remove deprecation warning. (#103)
-
-Fixes #102
----
- setup.py | 2 +-
- tap/line.py | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/setup.py b/setup.py
-index 2d001da..4c59879 100644
---- a/setup.py
-+++ b/setup.py
-@@ -63,7 +63,7 @@ def run(self):
- zip_safe=False,
- platforms="any",
- install_requires=[],
-- extras_require={"yaml": ["more-itertools", "PyYAML"]},
-+ extras_require={"yaml": ["more-itertools", "PyYAML>=5.1"]},
- classifiers=[
- "Development Status :: 5 - Production/Stable",
- "Environment :: Console",
-diff --git a/tap/line.py b/tap/line.py
-index 0d44ff8..fc8f8e2 100644
---- a/tap/line.py
-+++ b/tap/line.py
-@@ -96,7 +96,7 @@ def yaml_block(self):
- """
- if LOAD_YAML and self._yaml_block is not None:
- try:
-- yaml_dict = yaml.load(self._yaml_block)
-+ yaml_dict = yaml.load(self._yaml_block, Loader=yaml.SafeLoader)
- return yaml_dict
- except yaml.error.YAMLError:
- print("Error parsing yaml block. Check formatting.")
diff --git a/dev-python/tappy/tappy-2.6.2.ebuild b/dev-python/tappy/tappy-2.6.2.ebuild
deleted file mode 100644
index 70093181232..00000000000
--- a/dev-python/tappy/tappy-2.6.2.ebuild
+++ /dev/null
@@ -1,40 +0,0 @@
-# Copyright 1999-2020 Gentoo Authors
-# Distributed under the terms of the GNU General Public License v2
-
-EAPI=7
-
-DISTUTILS_USE_SETUPTOOLS=rdepend
-PYTHON_COMPAT=( python2_7 python3_{6,7,8,9} )
-inherit distutils-r1
-
-MY_PN=tap.py
-DESCRIPTION="Test Anything Protocol (TAP) tools"
-HOMEPAGE="https://github.com/python-tap/tappy https://pypi.org/project/tap.py/"
-SRC_URI="mirror://pypi/${MY_PN::1}/${MY_PN}/${MY_PN}-${PV}.tar.gz"
-S=${WORKDIR}/${MY_PN}-${PV}
-
-LICENSE="BSD-2"
-SLOT="0"
-KEYWORDS="~alpha amd64 arm arm64 hppa ~ia64 ~mips ppc ppc64 ~s390 sparc x86"
-IUSE="yaml"
-
-RDEPEND="
- yaml? (
- dev-python/more-itertools[${PYTHON_USEDEP}]
- dev-python/pyyaml[${PYTHON_USEDEP}]
- )"
-BDEPEND="
- dev-python/Babel[${PYTHON_USEDEP}]
- test? (
- dev-python/more-itertools[${PYTHON_USEDEP}]
- dev-python/pyyaml[${PYTHON_USEDEP}]
- $(python_gen_cond_dep '
- dev-python/mock[${PYTHON_USEDEP}]
- ' -2)
- )"
-
-distutils_enable_tests unittest
-
-PATCHES=(
- "${FILESDIR}"/${P}-yaml.patch
-)
^ permalink raw reply related [flat|nested] 3+ messages in thread
end of thread, other threads:[~2020-09-20 8:16 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-06-05 22:43 [gentoo-commits] repo/gentoo:master commit in: dev-python/tappy/, dev-python/tappy/files/ Andreas Sturmlechner
-- strict thread matches above, loose matches on Subject: below --
2020-09-20 8:16 Michał Górny
2020-04-23 11:23 Michał Górny
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox