public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Alessandro Barbieri" <lssndrbarbieri@gmail.com>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/proj/guru:dev commit in: dev-python/hunter/files/, dev-python/hunter/
Date: Thu, 17 Mar 2022 01:42:25 +0000 (UTC)	[thread overview]
Message-ID: <1647479434.09ac1bfd7fdaec359650dcb27e4c7f41500345a9.Alessandro-Barbieri@gentoo> (raw)

commit:     09ac1bfd7fdaec359650dcb27e4c7f41500345a9
Author:     Alessandro Barbieri <lssndrbarbieri <AT> gmail <DOT> com>
AuthorDate: Thu Mar 17 01:10:34 2022 +0000
Commit:     Alessandro Barbieri <lssndrbarbieri <AT> gmail <DOT> com>
CommitDate: Thu Mar 17 01:10:34 2022 +0000
URL:        https://gitweb.gentoo.org/repo/proj/guru.git/commit/?id=09ac1bfd

dev-python/hunter: add 3.4.3

Signed-off-by: Alessandro Barbieri <lssndrbarbieri <AT> gmail.com>

 dev-python/hunter/Manifest                         |  1 +
 .../files/hunter-remove-vendored-colorama.patch    | 34 ++++++++++
 dev-python/hunter/hunter-3.4.3.ebuild              | 79 ++++++++++++++++++++++
 3 files changed, 114 insertions(+)

diff --git a/dev-python/hunter/Manifest b/dev-python/hunter/Manifest
index 8d0386983..1cbe63eef 100644
--- a/dev-python/hunter/Manifest
+++ b/dev-python/hunter/Manifest
@@ -1 +1,2 @@
 DIST hunter-3.3.8.tar.gz 536260 BLAKE2B cdb048798dd831229f3c3ff784b16f94ee45c54bc35eb29e9b228f2736c103dbc39357df82476a2b25310501d33be67474f85c2f5a97a61baca20c8dfc5a725f SHA512 4d715893c805afb5ca709f8c8ce20fbf5ec8540a06c7536862d941a5a4f45b0721f8cd3aa2eeb79c072152d243f4d0ce949431defbdc8c17831f744c3f7ff58a
+DIST hunter-3.4.3.tar.gz 538017 BLAKE2B 92ad2b653d0285059ea2f005c6ba9564f357e1ea438a0fe30087f88efa202aaa504bad65985a88484cf7178c24432ac44705098dabc2667328c71e0ee38f718c SHA512 921bb48ac5d384977908dda060e178e623eb7c1e4298cbf3c0a273cab23695f2a2a60221afb257e54cd144399d2b3b55b80ae9a2c7f71ba452894cc86112d5f7

diff --git a/dev-python/hunter/files/hunter-remove-vendored-colorama.patch b/dev-python/hunter/files/hunter-remove-vendored-colorama.patch
new file mode 100644
index 000000000..1fa6342c0
--- /dev/null
+++ b/dev-python/hunter/files/hunter-remove-vendored-colorama.patch
@@ -0,0 +1,34 @@
+--- a/src/hunter/actions.py
++++ b/src/hunter/actions.py
+@@ -8,6 +8,8 @@
+ from itertools import islice
+ from os import getpid
+ 
++from colorama import AnsiToWin32
++
+ from . import config
+ from .util import BUILTIN_SYMBOLS
+ from .util import CALL_COLORS
+@@ -22,7 +20,6 @@
+ from .util import frame_iterator
+ from .util import iter_symbols
+ from .util import safe_repr
+-from .vendor.colorama import AnsiToWin32
+ 
+ try:
+     from threading import get_ident
+--- a/src/hunter/util.py
++++ b/src/hunter/util.py
+@@ -8,9 +8,9 @@
+ from collections import defaultdict
+ from collections import deque
+ 
++from colorama import Back
++from colorama import Fore
++from colorama import Style
+-from .vendor.colorama import Back
+-from .vendor.colorama import Fore
+-from .vendor.colorama import Style
+ 
+ try:
+     import __builtin__ as builtins

diff --git a/dev-python/hunter/hunter-3.4.3.ebuild b/dev-python/hunter/hunter-3.4.3.ebuild
new file mode 100644
index 000000000..08a454f17
--- /dev/null
+++ b/dev-python/hunter/hunter-3.4.3.ebuild
@@ -0,0 +1,79 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+PYTHON_COMPAT=( python3_{8..10} )
+
+inherit distutils-r1
+
+DESCRIPTION="Hunter is a flexible code tracing toolkit"
+HOMEPAGE="
+	https://github.com/ionelmc/python-hunter
+	https://pypi.org/project/hunter/
+"
+SRC_URI="https://github.com/ionelmc/python-${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+S="${WORKDIR}/python-${P}"
+LICENSE="BSD-2"
+SLOT="0"
+KEYWORDS="~amd64"
+
+RDEPEND=">=dev-python/colorama-0.4.4[${PYTHON_USEDEP}]"
+DEPEND="
+	${RDEPEND}
+	dev-python/cython[${PYTHON_USEDEP}]
+"
+BDEPEND="
+	>=dev-python/setuptools_scm-3.3.1[${PYTHON_USEDEP}]
+	test? (
+		dev-python/aspectlib[${PYTHON_USEDEP}]
+		dev-python/ipdb[${PYTHON_USEDEP}]
+		dev-python/manhole[${PYTHON_USEDEP}]
+		dev-python/process-tests[${PYTHON_USEDEP}]
+		dev-python/pytest-benchmark[${PYTHON_USEDEP}]
+		dev-python/six[${PYTHON_USEDEP}]
+	)
+"
+
+DOCS=( AUTHORS.rst CHANGELOG.rst README.rst )
+PATCHES=( "${FILESDIR}/${PN}-remove-vendored-colorama.patch" )
+
+distutils_enable_tests pytest
+distutils_enable_sphinx docs ">=dev-python/sphinx-py3doc-enhanced-theme-2.3.2"
+
+src_prepare() {
+	# remove vendored colorama
+	rm -r src/hunter/vendor || die
+	default
+}
+
+python_compile() {
+	distutils-r1_python_compile
+	if use test; then
+		"${EPYTHON}" tests/setup.py build_ext --force --inplace || die
+	fi
+}
+
+python_test() {
+	local PUREPYTHONHUNTER
+	local -x PYTHONPATH="${S}/tests:${BUILD_DIR}/lib:${PYTHONPATH}"
+	local epytest_args=(
+		--deselect tests/test_remote.py::test_gdb
+		--deselect tests/test_remote.py::test_gdb_clean_exit
+		--deselect tests/test_remote.py::test_manhole
+		--deselect tests/test_remote.py::test_manhole_clean_exit
+	)
+
+	if [[ ${EPYTHON} == python3.10 ]]; then
+		epytest_args+=(
+			--deselect tests/test_cookbook.py::test_probe
+			--deselect tests/test_tracer.py::test_perf_filter[pure]
+			--deselect tests/test_tracer.py::test_perf_stdlib[pure]
+			--deselect tests/test_tracer.py::test_perf_actions[pure]
+			--deselect tests/test_tracer.py::test_proper_backend
+		)
+		PUREPYTHONHUNTER="yes"
+	fi
+
+	epytest "${epytest_args[@]}"
+}


             reply	other threads:[~2022-03-17  1:42 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-03-17  1:42 Alessandro Barbieri [this message]
  -- strict thread matches above, loose matches on Subject: below --
2024-04-13 12:31 [gentoo-commits] repo/proj/guru:dev commit in: dev-python/hunter/files/, dev-python/hunter/ Henri Gasc
2022-06-05  6:16 Anna Vyalkova
2021-05-09  0:16 Alessandro Barbieri

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1647479434.09ac1bfd7fdaec359650dcb27e4c7f41500345a9.Alessandro-Barbieri@gentoo \
    --to=lssndrbarbieri@gmail.com \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox