summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam Jorna <wraeth@gentoo.org>2021-07-05 19:40:38 +1000
committerSam Jorna <wraeth@gentoo.org>2021-07-05 19:41:13 +1000
commit295f94bed864d6f54d4abb81f28b40155a614e70 (patch)
tree1ef72c6eedec3bc31ab74bd191dc5fa59def02f0 /net-irc/limnoria/limnoria-20210617-r1.ebuild
parentdev-python/linecache2: Eliminate unittest2 dep (diff)
downloadgentoo-295f94bed864d6f54d4abb81f28b40155a614e70.tar.gz
gentoo-295f94bed864d6f54d4abb81f28b40155a614e70.tar.bz2
gentoo-295f94bed864d6f54d4abb81f28b40155a614e70.zip
net-irc/limnoria: add RSS, fix version, fix tests
Fixes the version reported by the bot - previously would only report as 'installed on timestamp', now reports actual version. Stop removing the RSS plugin as the conflict caused by its presence no longer appears to exist. Also add upstream patch to fix broken test in RSS tests (GH#1479). Re-enable the Aka tests as issue resolved in GH#1392. Bug: https://github.com/ProgVal/Limnoria/issues/1392 Bug: https://github.com/ProgVal/Limnoria/issues/1479 Package-Manager: Portage-3.0.20, Repoman-3.0.3 Signed-off-by: Sam Jorna <wraeth@gentoo.org>
Diffstat (limited to 'net-irc/limnoria/limnoria-20210617-r1.ebuild')
-rw-r--r--net-irc/limnoria/limnoria-20210617-r1.ebuild81
1 files changed, 81 insertions, 0 deletions
diff --git a/net-irc/limnoria/limnoria-20210617-r1.ebuild b/net-irc/limnoria/limnoria-20210617-r1.ebuild
new file mode 100644
index 000000000000..cdecec64aaaf
--- /dev/null
+++ b/net-irc/limnoria/limnoria-20210617-r1.ebuild
@@ -0,0 +1,81 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+PYTHON_COMPAT=( python3_{7..9} )
+DISTUTILS_USE_SETUPTOOLS=no
+DISTUTILS_IN_SOURCE_BUILD=yes # needed for tests
+inherit distutils-r1
+
+MY_PV="${PV:0:4}-${PV:4:2}-${PV:6:2}"
+MY_PN="Limnoria"
+MY_P="${MY_PN}-${MY_PV}"
+
+if [[ ${PV} == *9999 ]]; then
+ EGIT_REPO_URI="https://github.com/ProgVal/${MY_PN}.git"
+ EGIT_BRANCH="testing"
+ inherit git-r3
+else
+ SRC_URI="https://github.com/ProgVal/${MY_PN}/archive/master-${MY_PV}.tar.gz -> ${P}.tar.gz"
+ S="${WORKDIR}/${MY_PN}-master-${MY_PV}"
+ KEYWORDS="~amd64 ~x86"
+fi
+
+DESCRIPTION="Python based extensible IRC infobot and channel bot"
+HOMEPAGE="https://docs.limnoria.net"
+LICENSE="BSD GPL-2 GPL-2+"
+SLOT="0"
+IUSE="crypt ssl test"
+RESTRICT=" !test? ( test )"
+
+RDEPEND="
+ dev-python/chardet[${PYTHON_USEDEP}]
+ dev-python/cryptography[${PYTHON_USEDEP}]
+ dev-python/ecdsa[${PYTHON_USEDEP}]
+ dev-python/feedparser[${PYTHON_USEDEP}]
+ dev-python/python-dateutil[${PYTHON_USEDEP}]
+ dev-python/pytz[${PYTHON_USEDEP}]
+ dev-python/PySocks[${PYTHON_USEDEP}]
+ dev-python/sqlalchemy[${PYTHON_USEDEP}]
+ crypt? ( dev-python/python-gnupg[${PYTHON_USEDEP}] )
+ ssl? ( dev-python/pyopenssl[${PYTHON_USEDEP}] )
+ !net-irc/supybot
+ !net-irc/supybot-plugins"
+BDEPEND="test? ( dev-python/mock[${PYTHON_USEDEP}] )"
+
+PATCHES=(
+ "${FILESDIR}/${P}-rss-testRemoveAliasedFeed-mock_data.patch" # GH#1479
+)
+
+python_prepare_all() {
+ # replace "installed on ${timestamp}" with real version
+ echo "version='${MY_PV}'" > "${S}"/src/version.py || die
+ distutils-r1_python_prepare_all
+}
+
+python_test() {
+ pushd "${T}" > /dev/null || die
+ PLUGINS_DIR="${BUILD_DIR}"/lib/supybot/plugins
+ EXCLUDE_PLUGINS=()
+ # intermittent failure due to issues loading libsandbox.so from LD_PRELOAD
+ # runs successfully when running the tests on the installed system
+ EXCLUDE_PLUGINS+=( --exclude="${PLUGINS_DIR}/Unix" )
+ "${EPYTHON}" "${BUILD_DIR}"/scripts/supybot-test "${BUILD_DIR}/../test" \
+ --plugins-dir="${PLUGINS_DIR}" --no-network \
+ --disable-multiprocessing "${EXCLUDE_PLUGINS[@]}" \
+ || die "Tests failed under ${EPYTHON}"
+ popd > /dev/null || die
+}
+
+python_install_all() {
+ distutils-r1_python_install_all
+ doman man/*
+}
+
+pkg_postinst() {
+ elog "Complete user documentation is available at https://limnoria-doc.readthedocs.org/"
+ elog ""
+ elog "Use supybot-wizard to create a configuration file."
+ elog "Run supybot </path/to/config> to use the bot."
+}