summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSam James <sam@gentoo.org>2023-05-30 20:00:02 +0100
committerSam James <sam@gentoo.org>2023-05-30 20:00:11 +0100
commitd670e14e0f618975e82c487a0fe55edcc941e0be (patch)
tree688a62526ed8d7e08bd69321da3c36db295c7b92 /dev-python/websockets
parentdev-vcs/git: enable py3.12 (diff)
downloadgentoo-d670e14e0f618975e82c487a0fe55edcc941e0be.tar.gz
gentoo-d670e14e0f618975e82c487a0fe55edcc941e0be.tar.bz2
gentoo-d670e14e0f618975e82c487a0fe55edcc941e0be.zip
dev-python/websockets: enable py3.12
Signed-off-by: Sam James <sam@gentoo.org>
Diffstat (limited to 'dev-python/websockets')
-rw-r--r--dev-python/websockets/Manifest1
-rw-r--r--dev-python/websockets/websockets-11.0.3-r1.ebuild47
2 files changed, 48 insertions, 0 deletions
diff --git a/dev-python/websockets/Manifest b/dev-python/websockets/Manifest
index fedc94cd9e1d..da242fd5dba9 100644
--- a/dev-python/websockets/Manifest
+++ b/dev-python/websockets/Manifest
@@ -1,2 +1,3 @@
DIST websockets-11.0.2.gh.tar.gz 347575 BLAKE2B 1d609298d072dbd986fa2adcac1c8f80720622fdcd44cb8ab079ba812fa7a750cdd4a5b432a74d422ca3ac8e7baef8e38e227569b8681e033f599fa29b19383c SHA512 e397d7b51c3edcc68fd32dbf8fcd46f5c9230c270be46c45a503108690d5513e2626fc4f4f5d271c831570abeeff51bf27c09ea69459b970a41fb64eb84fc87e
+DIST websockets-11.0.3-python3.12.patch.xz 4328 BLAKE2B 6ef94255ef5d95de8015eca14a5110373ab9ffadf4d1c86a892da1aac46caa2755cafeb643a222000a03262c1b1b1aea58132daff36981c00dbb68ce05484058 SHA512 421a6fb5a2a801850ea1fbaf890c11eac0f55ad288185f16f4244f316132591bc5a814636141ba3ada67aeff340f41de61d06c8db87010c858c1b0b02fd9b5ab
DIST websockets-11.0.3.gh.tar.gz 347652 BLAKE2B b7d796744cb4c7b944e98644dfb9c0e44ba465a6dba71b9e891604f3012b025557dbcd5b7eeae02e71c84350e05b334f99404ddfda814a8984b7a893d3f092f7 SHA512 37a84d7c57da7a3e48870abf992ba96ee454b342610d51c06f7dfc7ee082b7fb51304518c208379c3dbd039eafb1a85444c257fed20b4605a52dc8fc938a4cca
diff --git a/dev-python/websockets/websockets-11.0.3-r1.ebuild b/dev-python/websockets/websockets-11.0.3-r1.ebuild
new file mode 100644
index 000000000000..a6f179e672f2
--- /dev/null
+++ b/dev-python/websockets/websockets-11.0.3-r1.ebuild
@@ -0,0 +1,47 @@
+# Copyright 1999-2023 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+DISTUTILS_EXT=1
+DISTUTILS_USE_PEP517=setuptools
+PYTHON_COMPAT=( pypy3 python3_{10..12} )
+
+inherit distutils-r1
+
+DESCRIPTION="Library for building WebSocket servers and clients in Python"
+HOMEPAGE="
+ https://websockets.readthedocs.io/
+ https://github.com/python-websockets/websockets/
+ https://pypi.org/project/websockets/
+"
+# tests are missing pypi sdist, as of 11.0
+SRC_URI="
+ https://github.com/python-websockets/websockets/archive/${PV}.tar.gz
+ -> ${P}.gh.tar.gz
+ https://dev.gentoo.org/~sam/distfiles/${CATEGORY}/${PN}/${PN}-11.0.3-python3.12.patch.xz
+"
+
+LICENSE="BSD"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86"
+IUSE="+native-extensions"
+
+distutils_enable_tests pytest
+
+PATCHES=(
+ "${WORKDIR}"/${P}-python3.12.patch
+)
+
+src_configure() {
+ export BUILD_EXTENSION=$(usex native-extensions)
+}
+
+python_test() {
+ local EPYTEST_DESELECT=(
+ # very fragile to speed
+ tests/legacy/test_protocol.py::ServerTests::test_local_close_receive_close_frame_timeout
+ )
+
+ epytest tests
+}