public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Michał Górny" <mgorny@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: dev-python/nbclient/files/, dev-python/nbclient/
Date: Fri, 12 Jul 2024 10:36:47 +0000 (UTC)	[thread overview]
Message-ID: <1720780592.86764f7b51b14dceb280f85a336967821456dd53.mgorny@gentoo> (raw)

commit:     86764f7b51b14dceb280f85a336967821456dd53
Author:     Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Fri Jul 12 09:16:02 2024 +0000
Commit:     Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Fri Jul 12 10:36:32 2024 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=86764f7b

dev-python/nbclient: Enable py3.13

Signed-off-by: Michał Górny <mgorny <AT> gentoo.org>

 .../nbclient/files/nbclient-0.10.0-py313.patch     | 35 ++++++++++++++++++++++
 dev-python/nbclient/nbclient-0.10.0.ebuild         |  7 ++++-
 2 files changed, 41 insertions(+), 1 deletion(-)

diff --git a/dev-python/nbclient/files/nbclient-0.10.0-py313.patch b/dev-python/nbclient/files/nbclient-0.10.0-py313.patch
new file mode 100644
index 000000000000..1403cd0e0513
--- /dev/null
+++ b/dev-python/nbclient/files/nbclient-0.10.0-py313.patch
@@ -0,0 +1,35 @@
+From 57222265bfd8bdcf8851997e1dce5cd564e1a573 Mon Sep 17 00:00:00 2001
+From: Lumir Balhar <lbalhar@redhat.com>
+Date: Wed, 3 Jul 2024 14:21:41 +0200
+Subject: [PATCH] Fix compatibility with Python 3.13 beta 2
+
+There are more calls in 3.13 than in previous versions
+so the tests are now more permissive.
+
+Fixes: https://github.com/jupyter/nbclient/issues/316
+---
+ tests/test_cli.py | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/tests/test_cli.py b/tests/test_cli.py
+index 04b9887..55ccbd6 100644
+--- a/tests/test_cli.py
++++ b/tests/test_cli.py
+@@ -60,7 +60,7 @@ def test_mult(input_names, relative, inplace, jupyterapp, client, reader, writer
+     # add suffix if needed
+     paths = [p.with_suffix(".ipynb") for p in paths]
+ 
+-    assert path_open.mock_calls[::3] == [call(p) for p in paths]
++    assert all(call(p) in path_open.mock_calls for p in paths)
+     assert reader.call_count == len(paths)
+     # assert reader.mock_calls == [call(p, as_version=4) for p in paths]
+ 
+@@ -114,7 +114,7 @@ def test_output(input_names, relative, output_base, jupyterapp, client, reader,
+     # add suffix if needed
+     paths = [p.with_suffix(".ipynb") for p in paths]
+ 
+-    assert path_open.mock_calls[::3] == [call(p) for p in paths]
++    assert all(call(p) in path_open.mock_calls for p in paths)
+     assert reader.call_count == len(paths)
+ 
+     expected = []

diff --git a/dev-python/nbclient/nbclient-0.10.0.ebuild b/dev-python/nbclient/nbclient-0.10.0.ebuild
index 927821177ce1..2ae636b41d3d 100644
--- a/dev-python/nbclient/nbclient-0.10.0.ebuild
+++ b/dev-python/nbclient/nbclient-0.10.0.ebuild
@@ -4,7 +4,7 @@
 EAPI=8
 
 DISTUTILS_USE_PEP517=hatchling
-PYTHON_COMPAT=( pypy3 python3_{10..12} )
+PYTHON_COMPAT=( pypy3 python3_{10..13} )
 
 inherit distutils-r1 pypi
 
@@ -41,6 +41,11 @@ BDEPEND="
 EPYTEST_XDIST=1
 distutils_enable_tests pytest
 
+PATCHES=(
+	# https://github.com/jupyter/nbclient/pull/317
+	"${FILESDIR}/${P}-py313.patch"
+)
+
 python_test() {
 	local EPYTEST_DESELECT=(
 		# hangs?


             reply	other threads:[~2024-07-12 10:36 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-07-12 10:36 Michał Górny [this message]
  -- strict thread matches above, loose matches on Subject: below --
2025-01-04 15:00 [gentoo-commits] repo/gentoo:master commit in: dev-python/nbclient/files/, dev-python/nbclient/ Michał Górny

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=1720780592.86764f7b51b14dceb280f85a336967821456dd53.mgorny@gentoo \
    --to=mgorny@gentoo.org \
    --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