commit:     4d30e4e19f085cdb50ec3c80aa5e1105cae4ed73
Author:     Michał Górny <mgorny <AT> gentoo <DOT> org>
AuthorDate: Sat Apr 26 04:27:06 2025 +0000
Commit:     Michał Górny <mgorny <AT> gentoo <DOT> org>
CommitDate: Sat Apr 26 07:02:21 2025 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=4d30e4e1

dev-python/grpcio: Bump to 1.72.0

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

 dev-python/grpcio/Manifest             |   3 +
 dev-python/grpcio/grpcio-1.72.0.ebuild | 119 +++++++++++++++++++++++++++++++++
 2 files changed, 122 insertions(+)

diff --git a/dev-python/grpcio/Manifest b/dev-python/grpcio/Manifest
index 26383e03b69c..ba31b48a5ef4 100644
--- a/dev-python/grpcio/Manifest
+++ b/dev-python/grpcio/Manifest
@@ -1,6 +1,9 @@
 DIST grpc-1.68.1.gh.tar.gz 17320674 BLAKE2B 
46f4ae35c6a3a6ddfd47918a68a42d10e115ef81052715e8d8a73abf973063c730ddda06373278f3a4a6280dd4938e530a5e7377ab76aa653bb208583deab7f3
 SHA512 
cfb88a1290e2ee46fbd5f2b50b9c066ac174b1077170088c3b1a30bd37e66c6ca5254d2b951329a3991ac2b4320d12a50b1464babffbfc3bcf4eab670a449fd1
 DIST grpc-1.71.0.gh.tar.gz 14659092 BLAKE2B 
8c08020eca27c97d5a47e61a758e482662425c8afe6feef8f3ba9cd0fe2d2c100c9087b16fbf3f2ba3d447aee5d7da3267db7c6e642e2a94f554640364135990
 SHA512 
25783f75295919d0a077e3d0ff70ea2e651eaf107da2ebe8af40a584540f2f56aae0e04c7b809f3b1eb7d5adc3892f84464662d80b1234a111836f454ba84a18
+DIST grpc-1.72.0.gh.tar.gz 14730317 BLAKE2B 
f4b16fcef3efa086cce043197e0d7bb6dc858074c329c3c993f33a5a65db72d8cf8106bc3d96cf72a12cf3040405e91f1d2fda2ac64b558ed00b18d6aef5821a
 SHA512 
e56c37f6b2370426df63e700d9cf227864812911ae071f1c34626d0c336d6b6b42ca5d7cdc6d5d04744009aca6be8769fe9b0f15992f3aa2112e6166ed326f6a
 DIST grpcio-1.68.1.tar.gz 12694654 BLAKE2B 
73dc8ef4371f43d232e452b4aba4a7a3c32f83a93631179123a020660484ecb54ce6da14ef262442ab537a60859c624876e9b6285882f998a17c3a1a144c5416
 SHA512 
98f517687a9e46f316a08943122e2d002eac03637049e319b070832121ec8b4f140a0e0e1c530d6f3e83973e3503b5a50cdf1532b59e23a2b2e3d8514cd4132d
 DIST grpcio-1.71.0.tar.gz 12549828 BLAKE2B 
c533654643d4c67edbf9b7416f4bda82e5c910e44c2ed08427b9fecace6aeca01e427f4ad2d235309e740d3039600c21eff15d80dea61b3b6d3fcda931446d2a
 SHA512 
07df111b787ac84a2d8ff824ed62603ea9040c8d522e689bc4901243b582c120ec0a71ed2037f7d5f7833b19453c6bf891c7c5611a6c64641651d01c53c4c3ec
+DIST grpcio-1.72.0.tar.gz 12588545 BLAKE2B 
baa9d4432900fd3ec700b0cd1794ad129f7a3dfeb3cb98e235eb4f0d944838beb1f6e7b823e6c465c6cb770236f76ef42e01f2dc0dc51db0157e9ab01371eaea
 SHA512 
d1a178a58c0579bf1a975548b9d52bd312b03cacc13e056f5ed7d0da0aa4dc1391f293bac481d1ccf2d8c0940cbc47d862f5d272a1df8bafb4f6f8d8665bf843
 DIST grpcio_tools-1.68.1.tar.gz 5275384 BLAKE2B 
29f504ccb3335c8f183c78c286b36c8e220dd30bd3ffb07770d330b232e40f87977bfe10e0099b05ca2a1d86c5743b056a5a4ae54f5343d9de0a9036a9b5cde4
 SHA512 
a967137875a50a28293d90a2b4ba6ceb35ce7532b73ea727cca0a40e734227a70e2b1f4ce201477b8418c4b29766e21d40fe33c92522d7d94c92c3a55cf265c4
 DIST grpcio_tools-1.71.0.tar.gz 5326008 BLAKE2B 
70dae192880c861e659f1901e00d7189637843c25c309791857fdc1ef58692fcd3a42d34587896b67d19b2a067561d0cc51e5c9f530352d5345fd06f00fea045
 SHA512 
33ec4c4a5f09e41af3c20cf030a16f69b8b9d0b8f107f84be6666afce026367d710c0fe4b383f3b45a56e3403fd4f23309ca16ea7d1a122245572868bf7a1507
+DIST grpcio_tools-1.72.0.tar.gz 5396558 BLAKE2B 
db25a36efd70270b0b91c0e3b73f7595cf32b613dacf6c9d053659610e5a10773666a18776bf01d4904222ebe2b855def3accfc4c778ecd1f37f0d1f7913a3ba
 SHA512 
b2317fdaba0d1c7cffc652443a42fd4d452fa9d188d9908eb73826448bafbce76ac898497da2fb3dbf709fed6666916f026c05af3e4a6dd5db71a13f895d345a

diff --git a/dev-python/grpcio/grpcio-1.72.0.ebuild 
b/dev-python/grpcio/grpcio-1.72.0.ebuild
new file mode 100644
index 000000000000..657c90c527d9
--- /dev/null
+++ b/dev-python/grpcio/grpcio-1.72.0.ebuild
@@ -0,0 +1,119 @@
+# Copyright 2024-2025 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+DISTUTILS_EXT=1
+DISTUTILS_USE_PEP517=setuptools
+PYTHON_COMPAT=( python3_{10..13} )
+
+inherit distutils-r1 flag-o-matic multiprocessing pypi
+
+MY_P=grpc-${PV}
+DESCRIPTION="HTTP/2-based RPC framework"
+HOMEPAGE="
+       https://grpc.io/
+       https://github.com/grpc/grpc/
+       https://pypi.org/project/grpcio/
+"
+# Tests need other packages from the source tree, so use a GitHub
+# archive.  sdist provides bundled library sources (git submodules).
+SRC_URI+="
+       test? (
+               https://github.com/grpc/grpc/archive/v${PV}.tar.gz
+                       -> ${MY_P}.gh.tar.gz
+               $(pypi_sdist_url grpcio_tools)
+       )
+"
+
+LICENSE="Apache-2.0"
+SLOT="0"
+KEYWORDS="~amd64 ~arm64 ~x86"
+
+DEPEND="
+       dev-libs/openssl:=
+       net-dns/c-ares:=
+       sys-libs/zlib:=
+"
+RDEPEND="
+       ${DEPEND}
+"
+# TODO: try to remove coverage dep
+BDEPEND="
+       dev-python/cython[${PYTHON_USEDEP}]
+       test? (
+               dev-python/coverage[${PYTHON_USEDEP}]
+               >=dev-python/protobuf-6.30.0[${PYTHON_USEDEP}]
+       )
+"
+
+EPYTEST_XDIST=1
+distutils_enable_tests pytest
+
+src_configure() {
+       export GRPC_PYTHON_BUILD_EXT_COMPILER_JOBS="$(makeopts_jobs)"
+       # system abseil-cpp crashes with USE=-debug, sigh
+       # https://bugs.gentoo.org/942021
+       #export GRPC_PYTHON_BUILD_SYSTEM_ABSL=1
+       export GRPC_PYTHON_BUILD_SYSTEM_CARES=1
+       export GRPC_PYTHON_BUILD_SYSTEM_OPENSSL=1
+       # re2 needs to be built against the same abseil-cpp version
+       #export GRPC_PYTHON_BUILD_SYSTEM_RE2=1
+       export GRPC_PYTHON_BUILD_SYSTEM_ZLIB=1
+       export GRPC_PYTHON_BUILD_WITH_CYTHON=1
+
+       # copied from setup.py, except for removed -std= that does not apply
+       # to C code and causes warnings
+       export GRPC_PYTHON_CFLAGS="-fvisibility=hidden -fno-wrapv 
-fno-exceptions"
+       # required by abseil-cpp
+       append-cxxflags -std=c++17
+       # silence a lot of harmless noise from bad quality code
+       append-cxxflags -Wno-attributes
+}
+
+python_test() {
+       local EPYTEST_DESELECT=(
+               # Internet
+               
tests/unit/_dns_resolver_test.py::DNSResolverTest::test_connect_loopback
+               # not a test
+               
tests_aio/unit/channel_argument_test.py::test_if_reuse_port_enabled
+               # expects grpcio-admin
+               
tests/unit/test_all_modules_installed.py::TestAllModulesInstalled::test_import_all_modules
+               # TODO
+               
tests_py3_only/unit/_simple_stubs_test.py::SimpleStubsTest::test_default_ssl
+       )
+       local EPYTEST_IGNORE=(
+               # not a test
+               tests/unit/test_common.py
+               # requires oauth2client
+               tests/unit/beta/_implementations_test.py
+       )
+       local -x PYTEST_DISABLE_PLUGIN_AUTOLOAD=1
+
+       cp -a "${BUILD_DIR}"/{install,test} || die
+       local -x PATH=${BUILD_DIR}/test/usr/bin:${PATH}
+
+       # grpcio proper builds against system libs
+       # grpcio_tools supports bundled libs only, and requires different
+       # flags
+       unset GRPC_PYTHON_CFLAGS
+       cd "${WORKDIR}/grpcio_tools-${PV}" || die
+       distutils_pep517_install "${BUILD_DIR}"/test
+
+       cd "${WORKDIR}/${MY_P}" || die
+       local protodir=src/proto/grpc/testing
+       local testdir=src/python/grpcio_tests
+       "${EPYTHON}" -m grpc_tools.protoc -I. --python_out="${testdir}" \
+               "${protodir}"/{empty,messages}.proto || die
+       "${EPYTHON}" -m grpc_tools.protoc -I. --grpc_python_out="${testdir}" \
+               "${protodir}"/test.proto || die
+
+       cd "${testdir}" || die
+       "${EPYTHON}" -m grpc_tools.protoc -I. --python_out=. \
+               tests/testing/proto/{requests,services}.proto || die
+       "${EPYTHON}" -m grpc_tools.protoc -I. --grpc_python_out=. \
+               tests/testing/proto/services.proto || die
+
+       # TODO: aio tests are failing randomly, so we're skipping them entirely
+       epytest tests{_py3_only,}/unit
+}

Reply via email to