From 0844ca9af97621a6adca289572fd57f7d15433d5 Mon Sep 17 00:00:00 2001 From: Geoff Parker Date: Mon, 28 Nov 2022 14:32:33 -0800 Subject: python3-yappi: upgrade 1.3.6 -> 1.4.0, python 3.11 compatible Update to 1.4.0 for python 3.11 compatibilty Add patch to add upstream commit added after the release of 1.4.0 tarball. Adds python 3.11 to setup.py Update 0001-Fix-imports-for-ptest.patch for patch fuzz and removed hunk already in 1.4.0. Signed-off-by: Geoff Parker Signed-off-by: Khem Raj --- .../0001-Fix-imports-for-ptests.patch | 16 ++-------- .../python3-yappi/0002-add-3.11-to-the-setup.patch | 24 +++++++++++++++ .../recipes-devtools/python/python3-yappi_1.3.6.bb | 36 ---------------------- .../recipes-devtools/python/python3-yappi_1.4.0.bb | 36 ++++++++++++++++++++++ 4 files changed, 62 insertions(+), 50 deletions(-) create mode 100644 meta-python/recipes-devtools/python/python3-yappi/0002-add-3.11-to-the-setup.patch delete mode 100644 meta-python/recipes-devtools/python/python3-yappi_1.3.6.bb create mode 100644 meta-python/recipes-devtools/python/python3-yappi_1.4.0.bb (limited to 'meta-python/recipes-devtools/python') diff --git a/meta-python/recipes-devtools/python/python3-yappi/0001-Fix-imports-for-ptests.patch b/meta-python/recipes-devtools/python/python3-yappi/0001-Fix-imports-for-ptests.patch index fa58897e68..274f6f527b 100644 --- a/meta-python/recipes-devtools/python/python3-yappi/0001-Fix-imports-for-ptests.patch +++ b/meta-python/recipes-devtools/python/python3-yappi/0001-Fix-imports-for-ptests.patch @@ -8,10 +8,9 @@ Signed-off-by: Trevor Gamblin tests/test_asyncio.py | 2 +- tests/test_asyncio_context_vars.py | 2 +- tests/test_functionality.py | 2 +- - tests/test_gevent.py | 2 +- tests/test_hooks.py | 2 +- tests/test_tags.py | 2 +- - 6 files changed, 6 insertions(+), 6 deletions(-) + 5 files changed, 6 insertions(+), 6 deletions(-) --- a/tests/test_asyncio.py +++ b/tests/test_asyncio.py @@ -23,7 +22,7 @@ Signed-off-by: Trevor Gamblin +from .utils import YappiUnitTestCase, find_stat_by_name, burn_cpu, burn_io - @asyncio.coroutine + async def async_sleep(sec): --- a/tests/test_asyncio_context_vars.py +++ b/tests/test_asyncio_context_vars.py @@ -5,7 +5,7 @@ import contextvars @@ -3870,17 +3869,6 @@ Signed-off-by: Trevor Gamblin + # import sys;sys.argv = ['', 'BasicUsage.test_run_as_script'] + # import sys;sys.argv = ['', 'MultithreadedScenarios.test_subsequent_profile'] + unittest.main() ---- a/tests/test_gevent.py -+++ b/tests/test_gevent.py -@@ -4,7 +4,7 @@ import yappi - import gevent - from gevent.event import Event - import threading --from utils import ( -+from .utils import ( - YappiUnitTestCase, find_stat_by_name, burn_cpu, burn_io, - burn_io_gevent - ) --- a/tests/test_hooks.py +++ b/tests/test_hooks.py @@ -5,7 +5,7 @@ import unittest diff --git a/meta-python/recipes-devtools/python/python3-yappi/0002-add-3.11-to-the-setup.patch b/meta-python/recipes-devtools/python/python3-yappi/0002-add-3.11-to-the-setup.patch new file mode 100644 index 0000000000..a9bf612db8 --- /dev/null +++ b/meta-python/recipes-devtools/python/python3-yappi/0002-add-3.11-to-the-setup.patch @@ -0,0 +1,24 @@ +From 38afdacf526410f970afc58e147c7377c6c7112c Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?S=C3=BCmer=20Cip?= +Date: Fri, 25 Nov 2022 15:58:03 +0300 +Subject: [PATCH 2/2] add 3.11 to the setup + +--- + setup.py | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/setup.py b/setup.py +index d006787..96e2a66 100644 +--- a/setup.py ++++ b/setup.py +@@ -56,6 +56,7 @@ CLASSIFIERS = [ + 'Programming Language :: Python :: 3.8', + 'Programming Language :: Python :: 3.9', + 'Programming Language :: Python :: 3.10', ++ 'Programming Language :: Python :: 3.11', + 'Programming Language :: Python :: Implementation :: CPython', + 'Operating System :: OS Independent', + 'Topic :: Software Development :: Libraries', +-- +2.30.2 + diff --git a/meta-python/recipes-devtools/python/python3-yappi_1.3.6.bb b/meta-python/recipes-devtools/python/python3-yappi_1.3.6.bb deleted file mode 100644 index 526af346b6..0000000000 --- a/meta-python/recipes-devtools/python/python3-yappi_1.3.6.bb +++ /dev/null @@ -1,36 +0,0 @@ -SUMMARY = "Yet Another Python Profiler" -HOMEPAGE = "https://github.com/sumerc/yappi" - -LICENSE = "MIT" -LIC_FILES_CHKSUM = "file://LICENSE;md5=71c208c9a4fd864385eb69ad4caa3bee" - -SRC_URI[sha256sum] = "0a73c608a2603570a020a32d4369ba744012bc5267f37e5bd8026fb491abba56" - -SRC_URI += " \ - file://run-ptest \ - file://0001-Fix-imports-for-ptests.patch \ -" - -inherit pypi setuptools3 ptest - -RDEPENDS:${PN} += "\ - ${PYTHON_PN}-datetime \ - ${PYTHON_PN}-pickle \ - ${PYTHON_PN}-threading \ -" - -RDEPENDS:${PN}-ptest += " \ - ${PYTHON_PN}-gevent \ - ${PYTHON_PN}-multiprocessing \ - ${PYTHON_PN}-pytest \ - ${PYTHON_PN}-profile \ - ${PYTHON_PN}-zopeinterface \ -" - -do_install_ptest() { - install -d ${D}${PTEST_PATH}/tests - cp -rf ${S}/tests/* ${D}${PTEST_PATH}/tests/ - cp -f ${S}/yappi/yappi.py ${D}/${PTEST_PATH}/ -} - -SKIP_RECIPE[python3-yappi] ?= "Not compatible with py3.11; needs a new release" diff --git a/meta-python/recipes-devtools/python/python3-yappi_1.4.0.bb b/meta-python/recipes-devtools/python/python3-yappi_1.4.0.bb new file mode 100644 index 0000000000..71e74e86f2 --- /dev/null +++ b/meta-python/recipes-devtools/python/python3-yappi_1.4.0.bb @@ -0,0 +1,36 @@ +SUMMARY = "Yet Another Python Profiler" +HOMEPAGE = "https://github.com/sumerc/yappi" + +LICENSE = "MIT" +LIC_FILES_CHKSUM = "file://LICENSE;md5=71c208c9a4fd864385eb69ad4caa3bee" + +SRC_URI[sha256sum] = "504b5d8fc7433736cb5e257991d2e7f2946019174f1faec7b2fe947881a17fc0" + +SRC_URI += " \ + file://run-ptest \ + file://0001-Fix-imports-for-ptests.patch \ + file://0002-add-3.11-to-the-setup.patch \ +" + +inherit pypi setuptools3 ptest + +RDEPENDS:${PN} += "\ + ${PYTHON_PN}-datetime \ + ${PYTHON_PN}-pickle \ + ${PYTHON_PN}-threading \ +" + +RDEPENDS:${PN}-ptest += " \ + ${PYTHON_PN}-gevent \ + ${PYTHON_PN}-multiprocessing \ + ${PYTHON_PN}-pytest \ + ${PYTHON_PN}-profile \ + ${PYTHON_PN}-zopeinterface \ +" + +do_install_ptest() { + install -d ${D}${PTEST_PATH}/tests + cp -rf ${S}/tests/* ${D}${PTEST_PATH}/tests/ + cp -f ${S}/yappi/yappi.py ${D}/${PTEST_PATH}/ +} + -- cgit v1.2.3-54-g00ecf