summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEli Schwartz <eschwartz93@gmail.com>2024-06-26 00:05:48 -0400
committerSam James <sam@gentoo.org>2024-06-26 10:03:50 +0100
commit050f75a4ee9c22ef3f32193c94cafa7c1781429e (patch)
tree7ad1ad7ae934125ff7d53bf9c6e62f1166347149 /dev-python/doit
parentapp-misc/check-jsonschema: fix overdependency on tomli (diff)
downloadgentoo-050f75a4ee9c22ef3f32193c94cafa7c1781429e.tar.gz
gentoo-050f75a4ee9c22ef3f32193c94cafa7c1781429e.tar.bz2
gentoo-050f75a4ee9c22ef3f32193c94cafa7c1781429e.zip
dev-python/doit: conditionalize tomli/tomlkit imports after stdlib tomllib
This project attempts to support every kitchen sink when it comes to loading a toml file. And since 0.36.0 it also supports the dev-python/tomli library: https://github.com/pydoit/doit/commit/b2ed5ba798622d9ac1d2b50de81a4eb24e02f844 This was added by mgorny! :) It also supported tomllib at the same time. But when someone else packaged it in commit 0e5347e6b3e6d2ac0af7777dfb010368a78dcd06 this was overlooked. Drop the dependency on 3.11+. Fixes: 0e5347e6b3e6d2ac0af7777dfb010368a78dcd06 Signed-off-by: Eli Schwartz <eschwartz93@gmail.com> Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'dev-python/doit')
-rw-r--r--dev-python/doit/doit-0.36.0-r2.ebuild70
1 files changed, 70 insertions, 0 deletions
diff --git a/dev-python/doit/doit-0.36.0-r2.ebuild b/dev-python/doit/doit-0.36.0-r2.ebuild
new file mode 100644
index 000000000000..37fc353b936c
--- /dev/null
+++ b/dev-python/doit/doit-0.36.0-r2.ebuild
@@ -0,0 +1,70 @@
+# Copyright 1999-2024 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+DISTUTILS_USE_PEP517=setuptools
+PYTHON_COMPAT=( python3_{10..12} )
+
+inherit bash-completion-r1 distutils-r1 pypi
+
+DESCRIPTION="Automation tool"
+HOMEPAGE="
+ https://pydoit.org/
+ https://github.com/pydoit/doit/
+ https://pypi.org/project/doit/
+"
+
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="~amd64 ~arm64 ~riscv ~x86"
+
+RDEPEND="
+ dev-python/cloudpickle[${PYTHON_USEDEP}]
+ dev-python/pyinotify[${PYTHON_USEDEP}]
+ $(python_gen_cond_dep '
+ || (
+ dev-python/tomli[${PYTHON_USEDEP}]
+ dev-python/tomlkit[${PYTHON_USEDEP}]
+ )
+ ' 3.10)
+"
+PDEPEND="
+ >=dev-python/doit-py-0.4.0[${PYTHON_USEDEP}]
+"
+BDEPEND="
+ test? (
+ ${PDEPEND}
+ $(python_gen_impl_dep sqlite)
+ dev-python/pyflakes[${PYTHON_USEDEP}]
+ )
+"
+
+distutils_enable_tests pytest
+distutils_enable_sphinx doc \
+ dev-python/sphinx-rtd-theme
+
+EPYTEST_DESELECT=(
+ # test failing due to impact on PATH run in a sandbox
+ tests/test_cmd_strace.py::TestCmdStrace::test_dep # #836164
+ tests/test_cmd_strace.py::TestCmdStrace::test_target
+)
+
+src_prepare() {
+ # Replace custom theme with builtin for documentation
+ sed -e '/html_theme/s/press/sphinx_rtd_theme/' -i doc/conf.py || die
+ # Remove non-exist modules for doc generation (#832754)
+ sed \
+ -e '/sphinx_sitemap/d' \
+ -e '/sphinx_reredirects/d' \
+ -i doc/conf.py || die
+
+ distutils-r1_src_prepare
+}
+
+src_install() {
+ distutils-r1_src_install
+ newbashcomp bash_completion_doit ${PN}
+ insinto /usr/share/zsh/site-functions
+ newins zsh_completion_doit _${PN}
+}