Gentoo Archives: gentoo-commits

From: Louis Sautier <sbraz@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: www-misc/urlwatch/
Date: Mon, 24 Aug 2020 14:01:57
Message-Id: 1598277703.e58b650cb0b8a3f96a111fbc755decb4a94fb2b1.sbraz@gentoo
1 commit: e58b650cb0b8a3f96a111fbc755decb4a94fb2b1
2 Author: Louis Sautier <sbraz <AT> gentoo <DOT> org>
3 AuthorDate: Mon Aug 24 13:43:59 2020 +0000
4 Commit: Louis Sautier <sbraz <AT> gentoo <DOT> org>
5 CommitDate: Mon Aug 24 14:01:43 2020 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e58b650c
7
8 www-misc/urlwatch: bump to 2.21, add Python 3.9 support
9
10 Tests now use pytest instead of nose.
11
12 Package-Manager: Portage-3.0.3, Repoman-2.3.23
13 Signed-off-by: Louis Sautier <sbraz <AT> gentoo.org>
14
15 www-misc/urlwatch/Manifest | 1 +
16 www-misc/urlwatch/urlwatch-2.21.ebuild | 72 ++++++++++++++++++++++++++++++++++
17 2 files changed, 73 insertions(+)
18
19 diff --git a/www-misc/urlwatch/Manifest b/www-misc/urlwatch/Manifest
20 index 8ad3d3c9768..dc25490265c 100644
21 --- a/www-misc/urlwatch/Manifest
22 +++ b/www-misc/urlwatch/Manifest
23 @@ -1,2 +1,3 @@
24 DIST urlwatch-2.17.tar.gz 44178 BLAKE2B 46163b3305a50c3b5165da8f794c252aeb0a3581f16ba04cc1f0d920066accd02f7eba47718012e2ac0071f6bfa31019777a28840179a28a7fe365ae2e8f1d2c SHA512 635bca7e55641dd73447f5ec9ad429539decfaa8a1c19ab073c3bd46acfc518fa6012d855e0c37dd78654da28acf1446f580def611bcb85ae94fe13f567e3613
25 DIST urlwatch-2.18.tar.gz 48268 BLAKE2B e595a6ed27637463f14f92ecafd123eb0c7cef7102cc35ebbc3334804f7e09cc5f933aa2d54e24acd74a1419d6a8683a0d5fb2456b35ae0797c3d8a12efc33de SHA512 4b44a78fe7f2be6f507487ad5de57d79aa55ee790b29b97f2a364c0f3b58828fea5eb2b08235c15cafd3839b9261a7f148ebc9bceb5bedd1ff8319f7f039bb23
26 +DIST urlwatch-2.21.tar.gz 126235 BLAKE2B 9e0f39e51e413355974ce886e019eb86dd07fb9a75c02c5c711ccdbba573c2e6b218cf11b42c714172ad00288ea0219a079fd9b8016d33c29f087537d160e80d SHA512 30d7312c72d839e8ef681a11065f82c2611b650ab1b9b9a33e718bb791712674afb31e4b2e6da97038379fb8cc4ae5bc58b4d0ee6a26c424cba01898b56566b7
27
28 diff --git a/www-misc/urlwatch/urlwatch-2.21.ebuild b/www-misc/urlwatch/urlwatch-2.21.ebuild
29 new file mode 100644
30 index 00000000000..890f051e65f
31 --- /dev/null
32 +++ b/www-misc/urlwatch/urlwatch-2.21.ebuild
33 @@ -0,0 +1,72 @@
34 +# Copyright 1999-2020 Gentoo Authors
35 +# Distributed under the terms of the GNU General Public License v2
36 +
37 +EAPI=7
38 +
39 +PYTHON_COMPAT=( python3_{6,7,8,9} )
40 +# The package uses entry points but setup.py is weird
41 +# so the eclass doesn't detect it
42 +DISTUTILS_USE_SETUPTOOLS=manual
43 +
44 +inherit distutils-r1
45 +
46 +DESCRIPTION="A tool for monitoring webpages for updates"
47 +HOMEPAGE="https://thp.io/2008/urlwatch/"
48 +SRC_URI="mirror://pypi/${PN:0:1}/${PN}/${P}.tar.gz"
49 +
50 +LICENSE="BSD"
51 +SLOT="0"
52 +KEYWORDS="~amd64 ~x86"
53 +IUSE="test"
54 +RESTRICT="!test? ( test )"
55 +
56 +RDEPEND="
57 + dev-python/appdirs[${PYTHON_USEDEP}]
58 + dev-python/cssselect[${PYTHON_USEDEP}]
59 + dev-python/keyring[${PYTHON_USEDEP}]
60 + dev-python/lxml[${PYTHON_USEDEP}]
61 + dev-python/minidb[${PYTHON_USEDEP}]
62 + dev-python/pyyaml[${PYTHON_USEDEP}]
63 + dev-python/requests[${PYTHON_USEDEP}]
64 + dev-python/setuptools[${PYTHON_USEDEP}]
65 +"
66 +BDEPEND="
67 + dev-python/setuptools[${PYTHON_USEDEP}]
68 + test? (
69 + ${RDEPEND}
70 + dev-python/pytest[${PYTHON_USEDEP}]
71 + )
72 +"
73 +
74 +DOCS=( CHANGELOG.md README.md )
75 +
76 +python_test() {
77 + local skipped_tests=(
78 + # Require the pdftotext module
79 + "lib/urlwatch/tests/test_filter_documentation.py::test_url[https://example.net/pdf-test.pdf-job12]"
80 + "lib/urlwatch/tests/test_filter_documentation.py::test_url[https://example.net/pdf-test-password.pdf-job13]"
81 + # Requires the pytesseract module
82 + "lib/urlwatch/tests/test_filter_documentation.py::test_url[https://example.net/ocr-test.png-job26]"
83 + )
84 + pytest -vv ${skipped_tests[@]/#/--deselect } \
85 + || die "Tests failed with ${EPYTHON}"
86 +}
87 +
88 +pkg_postinst() {
89 + if [[ -z "${REPLACING_VERSIONS}" ]]; then
90 + if ! has_version dev-python/chump; then
91 + elog "Install 'dev-python/chump' to enable Pushover" \
92 + "notifications support"
93 + fi
94 + if ! has_version dev-python/pushbullet-py; then
95 + elog "Install 'dev-python/pushbullet-py' to enable" \
96 + "Pushbullet notifications support"
97 + fi
98 + elog "HTML parsing can be improved by installing one of the following packages"
99 + elog "and changing the html2text subfilter parameter:"
100 + elog "dev-python/beautifulsoup:4"
101 + elog "app-text/html2text"
102 + elog "dev-python/html2text"
103 + elog "www-client/lynx"
104 + fi
105 +}