summaryrefslogtreecommitdiff
path: root/dev-python/trio-asyncio
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2021-06-29 10:15:54 +0100
committerV3n3RiX <venerix@redcorelinux.org>2021-06-29 10:15:54 +0100
commit9aa80713372911cec499b3adb2cd746790920916 (patch)
treeb8e99dc5dd60ac2094a27cc52f74aada8df38f05 /dev-python/trio-asyncio
parentb4d43e8c611df4a8061b6f88d9e9f6b1e3c83903 (diff)
gentoo resync : 29.06.2021
Diffstat (limited to 'dev-python/trio-asyncio')
-rw-r--r--dev-python/trio-asyncio/Manifest4
-rw-r--r--dev-python/trio-asyncio/files/no-pytest-runner.patch10
-rw-r--r--dev-python/trio-asyncio/metadata.xml28
-rw-r--r--dev-python/trio-asyncio/trio-asyncio-0.12.0.ebuild34
4 files changed, 76 insertions, 0 deletions
diff --git a/dev-python/trio-asyncio/Manifest b/dev-python/trio-asyncio/Manifest
new file mode 100644
index 000000000000..abf01cdc5ee9
--- /dev/null
+++ b/dev-python/trio-asyncio/Manifest
@@ -0,0 +1,4 @@
+AUX no-pytest-runner.patch 442 BLAKE2B ff5900203f9c5d113a822f6233e2391d7eb1dd815709dd8a9e2ed30c18273125cdcd9ac2940870f81e9de3bcf9db130f2dd3a9492820b15ddec282759fb5e52b SHA512 7776f8a2445f35ff83324eba5aed4672f2e20e57a8a89c13360e32aa6c12d13df6fa1801b4a671797d5f7de8e1fee174f4e94d36617a382e536261bf05a64bcc
+DIST trio-asyncio-0.12.0.tar.gz 72508 BLAKE2B f2dad48e20dadb81f603f8e7edf5d108f5c1dec332e65599e06495a9e3b919d20a15e3cb0d4f06c46a0e844cd79a88c172043b5cae2bc632661679a9ac854c04 SHA512 da630bf95d0736efd419a7b84d3fcb55f4440ef5f3ac584f36b2eca9188145d4581b20d4842b1322b07f176822f7c76e32ae57ac71899ea2445ce1783bcd382c
+EBUILD trio-asyncio-0.12.0.ebuild 836 BLAKE2B 05a5a2df4f84eefe7f3f8ec20f60fc0f131b66d14e82fe2f66019fb7315d7848d0e6fc0bf85eb801810db25d90bf3f2a427da9115d1db75f90875a5699bb2cc9 SHA512 5b70b92265cd452d286a7927c4056d51dee87b56d54e32ba7967d622b7111316004466459db4616f722d85e8c95b884464c8b62436df79fa083eced5d0fd68c0
+MISC metadata.xml 1454 BLAKE2B 83ff665a02485c83a88fa3337d2bc4aa6192ddf3f02624a4c44d081656a32477ab9bad59d8c02e333e7634cbced29b64d527c0eca7cb33a602d2b78df18ac678 SHA512 9c374c5b75e586c5549e58d3238c3ea6952641774857396118992f8a6aeced4f85afb831d6f3b00965af22d37eb9d5e3efc21a65c6f5f3a598fa8307e41009c6
diff --git a/dev-python/trio-asyncio/files/no-pytest-runner.patch b/dev-python/trio-asyncio/files/no-pytest-runner.patch
new file mode 100644
index 000000000000..6eec59da4286
--- /dev/null
+++ b/dev-python/trio-asyncio/files/no-pytest-runner.patch
@@ -0,0 +1,10 @@
+--- a/setup.py 2021-03-27 18:54:07.104800689 +0100
++++ b/setup.py 2021-03-27 18:54:23.197091635 +0100
+@@ -77,7 +77,6 @@
+ include_package_data=True,
+ python_requires=">=3.6", # temporary, for RTD
+ keywords=["async", "io", "trio", "asyncio", "trio-asyncio"],
+- setup_requires=['pytest-runner'],
+ tests_require=['pytest >= 5.4', 'pytest-trio >= 0.6', 'outcome'],
+ classifiers=[
+ "Development Status :: 4 - Beta",
diff --git a/dev-python/trio-asyncio/metadata.xml b/dev-python/trio-asyncio/metadata.xml
new file mode 100644
index 000000000000..e006b6313aca
--- /dev/null
+++ b/dev-python/trio-asyncio/metadata.xml
@@ -0,0 +1,28 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+
+<pkgmetadata>
+ <maintainer type="person">
+ <email>andrewammerlaan@gentoo.org</email>
+ <name>Andrew Ammerlaan</name>
+ </maintainer>
+ <stabilize-allarches/>
+ <longdescription lang="en">
+Rationale
+
+Trio has native concepts of tasks and task cancellation. Asyncio is based on callbacks and chaining Futures, albeit with nicer syntax, which make handling of failures and timeouts fundamentally less reliable, especially in larger programs. Thus, you really want to base your async project on Trio.
+
+On the other hand, there are quite a few asyncio-enhanced libraries. You really don't want to re-invent any wheels in your project.
+
+Thus, being able to use asyncio libraries from Trio is useful. trio-asyncio enables you to do that, and more.
+Transparent vs. explicit translation
+
+trio_asyncio does not try to magically allow calling await trio_code() from asyncio or vice versa. There are multiple reasons for this; the executive summary is that cross-domain calls can't be made to work correctly, and any such call is likely to result in an irrecoverable error. You need to keep your code's asyncio and trio domains rigidly separate.
+
+Fortunately, this is not difficult.
+ </longdescription>
+ <upstream>
+ <remote-id type="github">python-trio/trio-asyncio</remote-id>
+ <remote-id type="pypi">trio-asyncio</remote-id>
+ </upstream>
+</pkgmetadata>
diff --git a/dev-python/trio-asyncio/trio-asyncio-0.12.0.ebuild b/dev-python/trio-asyncio/trio-asyncio-0.12.0.ebuild
new file mode 100644
index 000000000000..296d8886411b
--- /dev/null
+++ b/dev-python/trio-asyncio/trio-asyncio-0.12.0.ebuild
@@ -0,0 +1,34 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+PYTHON_COMPAT=( python3_{8..9} )
+
+inherit distutils-r1
+
+DESCRIPTION="a re-implementation of the asyncio mainloop on top of Trio"
+HOMEPAGE="
+ https://github.com/python-trio/trio-asyncio
+ https://pypi.org/project/trio-asyncio/
+"
+SRC_URI="https://github.com/python-trio/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
+
+LICENSE="|| ( Apache-2.0 MIT )"
+SLOT="0"
+KEYWORDS="~amd64"
+
+RDEPEND="
+ dev-python/outcome[${PYTHON_USEDEP}]
+ dev-python/sniffio[${PYTHON_USEDEP}]
+ >=dev-python/trio-0.15.0[${PYTHON_USEDEP}]
+"
+BDEPEND="
+ test? (
+ >=dev-python/pytest-trio-0.6[${PYTHON_USEDEP}]
+ )
+"
+PATCHES=( "${FILESDIR}/no-pytest-runner.patch" )
+
+distutils_enable_tests pytest
+distutils_enable_sphinx docs/source dev-python/sphinxcontrib-trio