From 4f2a291077ddf1afab2420a83b02ea9422fa080a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20G=C3=B3rny?= Date: Sat, 6 Sep 2025 19:27:07 +0200 Subject: [PATCH] dev-python/thriftpy2: Bump to 0.5.3 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Michał Górny --- dev-python/thriftpy2/Manifest | 1 + .../files/thriftpy2-0.5.3-tomllib.patch | 30 +++++++++++++ dev-python/thriftpy2/thriftpy2-0.5.3.ebuild | 44 +++++++++++++++++++ 3 files changed, 75 insertions(+) create mode 100644 dev-python/thriftpy2/files/thriftpy2-0.5.3-tomllib.patch create mode 100644 dev-python/thriftpy2/thriftpy2-0.5.3.ebuild diff --git a/dev-python/thriftpy2/Manifest b/dev-python/thriftpy2/Manifest index 308bf8f007431..46ec58f0dfefc 100644 --- a/dev-python/thriftpy2/Manifest +++ b/dev-python/thriftpy2/Manifest @@ -1 +1,2 @@ DIST thriftpy2-0.5.2.tar.gz 782261 BLAKE2B 657e8dadd8757f9f0f6b4a7f73e4347651f6301c969cf4d2c37cf87c6176322b7afad6372a39ed7d4c9f36d07850d6ae4edb73ff08dd3530b88e0194032abc9b SHA512 89a73d70b7ba74acc5344c1471587a66664331fb3d160eeb31d27434c78a3e76e3ec0d84dec14ec57d0bcc89e867759883d69247ae65bff1a9a8a00fc8ff7747 +DIST thriftpy2-0.5.3.tar.gz 814230 BLAKE2B 33e4702350d22e4f4c1eb4fedfc9358de93012511bcbdee95f266b9b45be85f16040f673c35fa47fd42dc498d2b132b13a1a6c49e957d9b551cd151ddd328e49 SHA512 09a66b623db6ad8e67d0e8ade9c5d2786f6d8fb967cd47492d48812a4553be2d2c50c5de1192a0d7fabc599d94cb50bdc94b73500d48b76804287cb91e9e3e89 diff --git a/dev-python/thriftpy2/files/thriftpy2-0.5.3-tomllib.patch b/dev-python/thriftpy2/files/thriftpy2-0.5.3-tomllib.patch new file mode 100644 index 0000000000000..d778ba9319e4e --- /dev/null +++ b/dev-python/thriftpy2/files/thriftpy2-0.5.3-tomllib.patch @@ -0,0 +1,30 @@ +diff --git a/setup.py b/setup.py +index e4741c6..3294b1a 100644 +--- a/setup.py ++++ b/setup.py +@@ -3,16 +3,20 @@ + + import sys + import platform +-import toml ++if sys.version_info < (3, 11): ++ import tomli as tomllib ++else: ++ import tomllib + + from os.path import join, dirname + from setuptools import setup, find_packages, Extension + + +-meta = toml.load(join(dirname(__file__), 'pyproject.toml') ) +-install_requires = meta["project"]["dependencies"] +-dev_requires = meta["project"]["optional-dependencies"]["dev"] +-tornado_requires = meta["project"]["optional-dependencies"]["tornado"] ++with open(join(dirname(__file__), 'pyproject.toml'), "rb") as f: ++ meta = tomllib.load(f) ++ install_requires = meta["project"]["dependencies"] ++ dev_requires = meta["project"]["optional-dependencies"]["dev"] ++ tornado_requires = meta["project"]["optional-dependencies"]["tornado"] + + try: + from tornado import version as tornado_version diff --git a/dev-python/thriftpy2/thriftpy2-0.5.3.ebuild b/dev-python/thriftpy2/thriftpy2-0.5.3.ebuild new file mode 100644 index 0000000000000..5f60c50112ab3 --- /dev/null +++ b/dev-python/thriftpy2/thriftpy2-0.5.3.ebuild @@ -0,0 +1,44 @@ +# Copyright 2021-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_{11..13} ) + +inherit distutils-r1 pypi + +DESCRIPTION="Pure python approach of Apache Thrift" +HOMEPAGE=" + https://github.com/Thriftpy/thriftpy2/ + https://pypi.org/project/thriftpy2/ +" + +LICENSE="MIT" +SLOT="0" +KEYWORDS="~amd64 ~x86" + +RDEPEND=" +