python3-ipython_ipykernel: update to 6.29.5.
This commit is contained in:
parent
ae00d0bdde
commit
8856721c78
|
@ -0,0 +1,129 @@
|
|||
See: https://github.com/ipython/ipykernel/pull/1231
|
||||
|
||||
From 53b63239a543cc9c631db9f63612d80d4182e498 Mon Sep 17 00:00:00 2001
|
||||
From: Steven Silvester <steve.silvester@mongodb.com>
|
||||
Date: Mon, 8 Apr 2024 06:38:30 -0500
|
||||
Subject: [PATCH 1/2] Add compat with pytest 8
|
||||
|
||||
---
|
||||
pyproject.toml | 2 +-
|
||||
tests/__init__.py | 9 +++++----
|
||||
tests/test_async.py | 7 +++----
|
||||
tests/test_eventloop.py | 7 +++----
|
||||
4 files changed, 12 insertions(+), 13 deletions(-)
|
||||
|
||||
diff --git a/pyproject.toml b/pyproject.toml
|
||||
index 909308af9..cdf265f63 100644
|
||||
--- a/pyproject.toml
|
||||
+++ b/pyproject.toml
|
||||
@@ -54,7 +54,7 @@ docs = [
|
||||
"trio"
|
||||
]
|
||||
test = [
|
||||
- "pytest>=7.0",
|
||||
+ "pytest>=7.0,<9",
|
||||
"pytest-cov",
|
||||
"flaky",
|
||||
"ipyparallel",
|
||||
diff --git a/tests/__init__.py b/tests/__init__.py
|
||||
index 013114bd1..ee324a6fa 100644
|
||||
--- a/tests/__init__.py
|
||||
+++ b/tests/__init__.py
|
||||
@@ -7,6 +7,8 @@
|
||||
import tempfile
|
||||
from unittest.mock import patch
|
||||
|
||||
+import pytest
|
||||
+
|
||||
from ipykernel.kernelspec import install
|
||||
|
||||
pjoin = os.path.join
|
||||
@@ -15,7 +17,8 @@
|
||||
patchers: list = []
|
||||
|
||||
|
||||
-def setup():
|
||||
+@pytest.fixture(autouse=True)
|
||||
+def _global_setup():
|
||||
"""setup temporary env for tests"""
|
||||
global tmp
|
||||
tmp = tempfile.mkdtemp()
|
||||
@@ -34,9 +37,7 @@ def setup():
|
||||
|
||||
# install IPython in the temp home:
|
||||
install(user=True)
|
||||
-
|
||||
-
|
||||
-def teardown():
|
||||
+ yield
|
||||
for p in patchers:
|
||||
p.stop()
|
||||
|
||||
diff --git a/tests/test_async.py b/tests/test_async.py
|
||||
index 422673299..a40db4a00 100644
|
||||
--- a/tests/test_async.py
|
||||
+++ b/tests/test_async.py
|
||||
@@ -11,14 +11,13 @@
|
||||
KC = KM = None
|
||||
|
||||
|
||||
-def setup_function():
|
||||
+@pytest.fixture(autouse=True)
|
||||
+def _setup_env():
|
||||
"""start the global kernel (if it isn't running) and return its client"""
|
||||
global KM, KC
|
||||
KM, KC = start_new_kernel()
|
||||
flush_channels(KC)
|
||||
-
|
||||
-
|
||||
-def teardown_function():
|
||||
+ yield
|
||||
assert KC is not None
|
||||
assert KM is not None
|
||||
KC.stop_channels()
|
||||
diff --git a/tests/test_eventloop.py b/tests/test_eventloop.py
|
||||
index 34581b7fb..77596eedd 100644
|
||||
--- a/tests/test_eventloop.py
|
||||
+++ b/tests/test_eventloop.py
|
||||
@@ -42,14 +42,13 @@ def _get_qt_vers():
|
||||
_get_qt_vers()
|
||||
|
||||
|
||||
-def setup():
|
||||
+@pytest.fixture(autouse=True)
|
||||
+def _setup_env():
|
||||
"""start the global kernel (if it isn't running) and return its client"""
|
||||
global KM, KC
|
||||
KM, KC = start_new_kernel()
|
||||
flush_channels(KC)
|
||||
-
|
||||
-
|
||||
-def teardown():
|
||||
+ yield
|
||||
assert KM is not None
|
||||
assert KC is not None
|
||||
KC.stop_channels()
|
||||
|
||||
From b1d42cffb2466533382fb937c522cfcf14847696 Mon Sep 17 00:00:00 2001
|
||||
From: Steven Silvester <steve.silvester@mongodb.com>
|
||||
Date: Mon, 8 Apr 2024 06:43:26 -0500
|
||||
Subject: [PATCH 2/2] fix message spec tests
|
||||
|
||||
---
|
||||
tests/test_message_spec.py | 3 ++-
|
||||
1 file changed, 2 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/tests/test_message_spec.py b/tests/test_message_spec.py
|
||||
index d9d8bb810..d98503ee7 100644
|
||||
--- a/tests/test_message_spec.py
|
||||
+++ b/tests/test_message_spec.py
|
||||
@@ -22,7 +22,8 @@
|
||||
KC: BlockingKernelClient = None # type:ignore
|
||||
|
||||
|
||||
-def setup():
|
||||
+@pytest.fixture(autouse=True)
|
||||
+def _setup_env():
|
||||
global KC
|
||||
KC = start_global_kernel()
|
||||
|
|
@ -1,24 +1,23 @@
|
|||
# Template file for 'python3-ipython_ipykernel'
|
||||
pkgname=python3-ipython_ipykernel
|
||||
version=6.29.4
|
||||
version=6.29.5
|
||||
revision=1
|
||||
build_style=python3-pep517
|
||||
# this test fails with ipython 8.24 (tests a deprecated feature)
|
||||
make_check_args="
|
||||
--deselect tests/inprocess/test_kernel.py::test_pylab"
|
||||
# run all tests available
|
||||
make_check_target="tests"
|
||||
hostmakedepends="hatchling python3-jupyter_client"
|
||||
depends="python3-comm python3-ipython python3-jupyter_client
|
||||
python3-nest_asyncio python3-packaging python3-psutil python3-tornado"
|
||||
checkdepends="$depends python3-flaky python3-pytest-asyncio
|
||||
python3-pytest-timeout python3-trio python3-curio python3-matplotlib
|
||||
python3-PyQt5 python3-PyQt5-svg"
|
||||
python3-PyQt5 python3-PyQt5-svg python3-pytest-xdist"
|
||||
short_desc="IPython kernel for Jupyter"
|
||||
maintainer="Gonzalo Tornaría <tornaria@cmat.edu.uy>"
|
||||
license="BSD-3-Clause"
|
||||
homepage="https://github.com/ipython/ipykernel"
|
||||
changelog="https://raw.githubusercontent.com/ipython/ipykernel/main/CHANGELOG.md"
|
||||
distfiles="${PYPI_SITE}/i/ipykernel/ipykernel-${version}.tar.gz"
|
||||
checksum=3d44070060f9475ac2092b760123fadf105d2e2493c24848b6691a7c4f42af5c
|
||||
checksum=f093a22c4a40f8828f8e330a9c297cb93dcab13bd9678ded6de8e5cf81c56215
|
||||
|
||||
if [ "$XBPS_CHECK_PKGS" = full ]; then
|
||||
# this would cause a build-time circular dependency
|
||||
|
|
Loading…
Reference in New Issue