[arch-commits] Commit in python-threadloop/repos/community-any (4 files)

Felix Yan felixonmars at archlinux.org
Wed Dec 23 21:00:28 UTC 2020


    Date: Wednesday, December 23, 2020 @ 21:00:26
  Author: felixonmars
Revision: 785222

archrelease: copy trunk to community-any

Added:
  python-threadloop/repos/community-any/PKGBUILD
    (from rev 785221, python-threadloop/trunk/PKGBUILD)
  python-threadloop/repos/community-any/tornado-5.patch
    (from rev 785221, python-threadloop/trunk/tornado-5.patch)
Deleted:
  python-threadloop/repos/community-any/PKGBUILD
  python-threadloop/repos/community-any/tornado-5.patch

-----------------+
 PKGBUILD        |   83 +++++++++++++++++++-----------------
 tornado-5.patch |  122 +++++++++++++++++++++++++++---------------------------
 2 files changed, 104 insertions(+), 101 deletions(-)

Deleted: PKGBUILD
===================================================================
--- PKGBUILD	2020-12-23 21:00:13 UTC (rev 785221)
+++ PKGBUILD	2020-12-23 21:00:26 UTC (rev 785222)
@@ -1,40 +0,0 @@
-# Maintainer: Felix Yan <felixonmars at archlinux.org>
-
-pkgname=python-threadloop
-pkgver=1.0.2
-pkgrel=3
-pkgdesc="Tornado IOLoop Backed Concurrent Futures"
-url="https://github.com/unhashable/threadloop"
-license=('MIT')
-arch=('any')
-depends=('python-tornado')
-makedepends=('python-setuptools')
-checkdepends=('python-pytest')
-source=("https://github.com/unhashable/threadloop/archive/$pkgver/$pkgname-$pkgver.tar.gz"
-        tornado-5.patch)
-sha512sums=('f6a95d01174cf3dacafda4ebc7f4f8efa1217675004949ce0565441a40aa9867be33f23cd78ce8de83de992b8bb654db34ff49568804790bcf27efa7c0b3643d'
-            '4b9c0f77e4cc004854588d1fcfcd46dabdd57055dd866c18ce9d29b9f746a0abcaa790f727e92e13b4e422f8c0fd82856db6cf4b7a2dca9ed33ad7403bd44998')
-
-prepare() {
-  cd threadloop-$pkgver
-  patch -p1 -i ../tornado-5.patch
-}
-
-build() {
-  cd threadloop-$pkgver
-  python setup.py build
-}
-
-check() {
-  cd threadloop-$pkgver
-  # Deselected tests: deadlocks
-  pytest -v --deselect tests/threadloop/test_threadloop.py::test_plain_function_exception_propagates \
-            --deselect tests/threadloop/test_threadloop.py::test_plain_function_exception_contains_exc_info
-}
-
-package() {
-  cd threadloop-$pkgver
-  python setup.py install --root="$pkgdir" --optimize=1
-
-  install -Dm644 LICENSE -t "$pkgdir"/usr/share/licenses/$pkgname/
-}

Copied: python-threadloop/repos/community-any/PKGBUILD (from rev 785221, python-threadloop/trunk/PKGBUILD)
===================================================================
--- PKGBUILD	                        (rev 0)
+++ PKGBUILD	2020-12-23 21:00:26 UTC (rev 785222)
@@ -0,0 +1,43 @@
+# Maintainer: Felix Yan <felixonmars at archlinux.org>
+
+pkgname=python-threadloop
+pkgver=1.0.2
+pkgrel=4
+pkgdesc="Tornado IOLoop Backed Concurrent Futures"
+url="https://github.com/unhashable/threadloop"
+license=('MIT')
+arch=('any')
+depends=('python-tornado')
+makedepends=('python-setuptools')
+checkdepends=('python-pytest')
+source=("https://github.com/unhashable/threadloop/archive/$pkgver/$pkgname-$pkgver.tar.gz"
+        tornado-5.patch)
+sha512sums=('f6a95d01174cf3dacafda4ebc7f4f8efa1217675004949ce0565441a40aa9867be33f23cd78ce8de83de992b8bb654db34ff49568804790bcf27efa7c0b3643d'
+            '4b9c0f77e4cc004854588d1fcfcd46dabdd57055dd866c18ce9d29b9f746a0abcaa790f727e92e13b4e422f8c0fd82856db6cf4b7a2dca9ed33ad7403bd44998')
+
+prepare() {
+  cd threadloop-$pkgver
+  patch -p1 -i ../tornado-5.patch
+}
+
+build() {
+  cd threadloop-$pkgver
+  python setup.py build
+}
+
+check() {
+  cd threadloop-$pkgver
+  # Deselected tests: deadlocks
+  pytest -v --deselect tests/threadloop/test_threadloop.py::test_plain_function_exception_propagates \
+            --deselect tests/threadloop/test_threadloop.py::test_plain_function_exception_contains_exc_info
+}
+
+package() {
+  cd threadloop-$pkgver
+  python setup.py install --root="$pkgdir" --optimize=1
+
+  # It's only present when tests are enabled, so adding -f
+  rm -rf "$pkgdir"/usr/lib/python3.9/site-packages/tests
+
+  install -Dm644 LICENSE -t "$pkgdir"/usr/share/licenses/$pkgname/
+}

Deleted: tornado-5.patch
===================================================================
--- tornado-5.patch	2020-12-23 21:00:13 UTC (rev 785221)
+++ tornado-5.patch	2020-12-23 21:00:26 UTC (rev 785222)
@@ -1,61 +0,0 @@
-From 236c342dc8594c8d73849c670cd57946f2549451 Mon Sep 17 00:00:00 2001
-From: condorcet <novikov.vz at gmail.com>
-Date: Tue, 3 Sep 2019 20:09:04 +0300
-Subject: [PATCH 1/2] Support asyncio in _start_io_loop method
-
----
- threadloop/threadloop.py | 8 +++++++-
- 1 file changed, 7 insertions(+), 1 deletion(-)
-
-diff --git a/threadloop/threadloop.py b/threadloop/threadloop.py
-index 8b584b6..1916baa 100644
---- a/threadloop/threadloop.py
-+++ b/threadloop/threadloop.py
-@@ -72,6 +72,12 @@ def mark_as_ready():
-             self._ready.set()
- 
-         if not self._io_loop:
-+            _io_loop = ioloop.IOLoop.current(instance=False)
-+            if _io_loop:
-+                self._io_loop = _io_loop
-+                if self._io_loop.is_running():
-+                    mark_as_ready()
-+                    return
-             self._io_loop = ioloop.IOLoop()
- 
-         self._io_loop.add_callback(mark_as_ready)
-@@ -92,7 +98,7 @@ def is_ready(self):
- 
-     def stop(self):
-         """Stop IOLoop & close daemonized thread."""
--        self._io_loop.stop()
-+        self._io_loop.add_callback(self._io_loop.stop)
-         self._thread.join()
- 
-     def submit(self, fn, *args, **kwargs):
-
-From c15556dd79cdf5a5f7c8dc04015fa4a0ef3f2c56 Mon Sep 17 00:00:00 2001
-From: condorcet <novikov.vz at gmail.com>
-Date: Wed, 4 Sep 2019 11:03:26 +0300
-Subject: [PATCH 2/2] Fix mistake
-
----
- threadloop/threadloop.py | 5 ++---
- 1 file changed, 2 insertions(+), 3 deletions(-)
-
-diff --git a/threadloop/threadloop.py b/threadloop/threadloop.py
-index 1916baa..d6847fb 100644
---- a/threadloop/threadloop.py
-+++ b/threadloop/threadloop.py
-@@ -75,9 +75,8 @@ def mark_as_ready():
-             _io_loop = ioloop.IOLoop.current(instance=False)
-             if _io_loop:
-                 self._io_loop = _io_loop
--                if self._io_loop.is_running():
--                    mark_as_ready()
--                    return
-+                mark_as_ready()
-+                return
-             self._io_loop = ioloop.IOLoop()
- 
-         self._io_loop.add_callback(mark_as_ready)

Copied: python-threadloop/repos/community-any/tornado-5.patch (from rev 785221, python-threadloop/trunk/tornado-5.patch)
===================================================================
--- tornado-5.patch	                        (rev 0)
+++ tornado-5.patch	2020-12-23 21:00:26 UTC (rev 785222)
@@ -0,0 +1,61 @@
+From 236c342dc8594c8d73849c670cd57946f2549451 Mon Sep 17 00:00:00 2001
+From: condorcet <novikov.vz at gmail.com>
+Date: Tue, 3 Sep 2019 20:09:04 +0300
+Subject: [PATCH 1/2] Support asyncio in _start_io_loop method
+
+---
+ threadloop/threadloop.py | 8 +++++++-
+ 1 file changed, 7 insertions(+), 1 deletion(-)
+
+diff --git a/threadloop/threadloop.py b/threadloop/threadloop.py
+index 8b584b6..1916baa 100644
+--- a/threadloop/threadloop.py
++++ b/threadloop/threadloop.py
+@@ -72,6 +72,12 @@ def mark_as_ready():
+             self._ready.set()
+ 
+         if not self._io_loop:
++            _io_loop = ioloop.IOLoop.current(instance=False)
++            if _io_loop:
++                self._io_loop = _io_loop
++                if self._io_loop.is_running():
++                    mark_as_ready()
++                    return
+             self._io_loop = ioloop.IOLoop()
+ 
+         self._io_loop.add_callback(mark_as_ready)
+@@ -92,7 +98,7 @@ def is_ready(self):
+ 
+     def stop(self):
+         """Stop IOLoop & close daemonized thread."""
+-        self._io_loop.stop()
++        self._io_loop.add_callback(self._io_loop.stop)
+         self._thread.join()
+ 
+     def submit(self, fn, *args, **kwargs):
+
+From c15556dd79cdf5a5f7c8dc04015fa4a0ef3f2c56 Mon Sep 17 00:00:00 2001
+From: condorcet <novikov.vz at gmail.com>
+Date: Wed, 4 Sep 2019 11:03:26 +0300
+Subject: [PATCH 2/2] Fix mistake
+
+---
+ threadloop/threadloop.py | 5 ++---
+ 1 file changed, 2 insertions(+), 3 deletions(-)
+
+diff --git a/threadloop/threadloop.py b/threadloop/threadloop.py
+index 1916baa..d6847fb 100644
+--- a/threadloop/threadloop.py
++++ b/threadloop/threadloop.py
+@@ -75,9 +75,8 @@ def mark_as_ready():
+             _io_loop = ioloop.IOLoop.current(instance=False)
+             if _io_loop:
+                 self._io_loop = _io_loop
+-                if self._io_loop.is_running():
+-                    mark_as_ready()
+-                    return
++                mark_as_ready()
++                return
+             self._io_loop = ioloop.IOLoop()
+ 
+         self._io_loop.add_callback(mark_as_ready)



More information about the arch-commits mailing list