[arch-commits] Commit in python-anyio/repos/community-any (3 files)

Chih-Hsuan Yen yan12125 at gemini.archlinux.org
Fri Sep 10 03:14:19 UTC 2021


    Date: Friday, September 10, 2021 @ 03:14:19
  Author: yan12125
Revision: 1013337

archrelease: copy trunk to community-any

Added:
  python-anyio/repos/community-any/PKGBUILD
    (from rev 1013336, python-anyio/trunk/PKGBUILD)
  python-anyio/repos/community-any/bpo-45097.diff
    (from rev 1013336, python-anyio/trunk/bpo-45097.diff)
Deleted:
  python-anyio/repos/community-any/PKGBUILD

----------------+
 PKGBUILD       |  111 +++++++++++++++++++++++++++----------------------------
 bpo-45097.diff |   14 ++++++
 2 files changed, 70 insertions(+), 55 deletions(-)

Deleted: PKGBUILD
===================================================================
--- PKGBUILD	2021-09-10 03:14:04 UTC (rev 1013336)
+++ PKGBUILD	2021-09-10 03:14:19 UTC (rev 1013337)
@@ -1,55 +0,0 @@
-# Maintainer: Chih-Hsuan Yen <yan12125 at archlinux.org>
-
-pkgname=python-anyio
-pkgver=3.3.0
-pkgrel=1
-pkgdesc='High level compatibility layer for multiple asynchronous event loop implementations'
-arch=(any)
-url='https://github.com/agronholm/anyio'
-license=(MIT)
-depends=(python python-idna python-sniffio)
-makedepends=(python-setuptools python-setuptools-scm)
-checkdepends=(python-pytest python-trustme python-hypothesis python-uvloop
-              python-curio python-trio python-pytest-mock)
-optdepends=(
-  'python-curio: curio backend'
-  'python-trio: trio backend'
-)
-source=(https://github.com/agronholm/anyio/archive/$pkgver/anyio-$pkgver.tar.gz
-        https://github.com/agronholm/anyio/commit/5ed3270c8d12cffc4cd3349d9ff32bc32451ae65.patch)
-sha256sums=('5872afba5b2a03461e8eb64538d8050d1f64fe54192ad67d8f34f6287ea7c729'
-            '30e94b5a37c124d3620c77abd835384b224eee3349bea0ddd19f3a268e71c9ca')
-
-export SETUPTOOLS_SCM_PRETEND_VERSION=$pkgver
-
-prepare() {
-  cd anyio-$pkgver
-  # pytest-mock 3.3 comes with an API change [1], and anyio uses the new API,
-  # while python-pytest-mock in Arch is out-dated. Patch the sources to use
-  # the old API.
-  # [1] https://github.com/pytest-dev/pytest-mock/issues/202
-  sed -i 's#MockerFixture#MockFixture#' tests/test_eventloop.py
-
-  # https://github.com/agronholm/anyio/issues/347
-  patch -Np1 -i ../5ed3270c8d12cffc4cd3349d9ff32bc32451ae65.patch
-}
-
-build() {
-  cd anyio-$pkgver
-  python setup.py build
-}
-
-check() {
-  cd anyio-$pkgver
-  # Install to a temporary root as the test suite requires the entry point for
-  # its pytest plugin
-  pyver=$(python -c "import sys; print('{}.{}'.format(*sys.version_info[:2]))")
-  python setup.py install --root="$PWD/tmp_install" --skip-build
-  PYTHONPATH="$PWD/tmp_install/usr/lib/python$pyver/site-packages" pytest
-}
-
-package() {
-  cd anyio-$pkgver
-  python setup.py install --root="${pkgdir}" --optimize=1 --skip-build
-  install -Dm644 LICENSE -t "$pkgdir"/usr/share/licenses/$pkgname
-}

Copied: python-anyio/repos/community-any/PKGBUILD (from rev 1013336, python-anyio/trunk/PKGBUILD)
===================================================================
--- PKGBUILD	                        (rev 0)
+++ PKGBUILD	2021-09-10 03:14:19 UTC (rev 1013337)
@@ -0,0 +1,56 @@
+# Maintainer: Chih-Hsuan Yen <yan12125 at archlinux.org>
+
+pkgname=python-anyio
+# https://github.com/agronholm/anyio/blob/master/docs/versionhistory.rst
+pkgver=3.3.1
+pkgrel=1
+pkgdesc='High level compatibility layer for multiple asynchronous event loop implementations'
+arch=(any)
+url='https://github.com/agronholm/anyio'
+license=(MIT)
+depends=(python python-idna python-sniffio)
+makedepends=(python-setuptools python-setuptools-scm)
+checkdepends=(python-pytest python-trustme python-hypothesis python-uvloop
+              python-curio python-trio python-pytest-mock)
+optdepends=(
+  'python-curio: curio backend'
+  'python-trio: trio backend'
+)
+source=(https://github.com/agronholm/anyio/archive/$pkgver/anyio-$pkgver.tar.gz
+        bpo-45097.diff)
+sha256sums=('2f27663b77aa484ca85544f6701f7d6710e9cf4fbb23df0990c8447983aabb32'
+            'ed0ad72f604697d247a2d74f5b4740fcda0fe478040fa6ff75120cd97d5985c8')
+
+export SETUPTOOLS_SCM_PRETEND_VERSION=$pkgver
+
+prepare() {
+  cd anyio-$pkgver
+  # pytest-mock 3.3 comes with an API change [1], and anyio uses the new API,
+  # while python-pytest-mock in Arch is out-dated. Patch the sources to use
+  # the old API.
+  # [1] https://github.com/pytest-dev/pytest-mock/issues/202
+  sed -i 's#MockerFixture#MockFixture#' tests/test_eventloop.py
+
+  # Work around https://bugs.python.org/issue45097
+  patch -Np1 -i ../bpo-45097.diff
+}
+
+build() {
+  cd anyio-$pkgver
+  python setup.py build
+}
+
+check() {
+  cd anyio-$pkgver
+  # Install to a temporary root as the test suite requires the entry point for
+  # its pytest plugin
+  pyver=$(python -c "import sys; print('{}.{}'.format(*sys.version_info[:2]))")
+  python setup.py install --root="$PWD/tmp_install" --skip-build
+  PYTHONPATH="$PWD/tmp_install/usr/lib/python$pyver/site-packages" pytest
+}
+
+package() {
+  cd anyio-$pkgver
+  python setup.py install --root="${pkgdir}" --optimize=1 --skip-build
+  install -Dm644 LICENSE -t "$pkgdir"/usr/share/licenses/$pkgname
+}

Copied: python-anyio/repos/community-any/bpo-45097.diff (from rev 1013336, python-anyio/trunk/bpo-45097.diff)
===================================================================
--- bpo-45097.diff	                        (rev 0)
+++ bpo-45097.diff	2021-09-10 03:14:19 UTC (rev 1013337)
@@ -0,0 +1,14 @@
+diff --git a/pyproject.toml b/pyproject.toml
+index d6c4fa1..541290d 100644
+--- a/pyproject.toml
++++ b/pyproject.toml
+@@ -38,7 +38,8 @@ testpaths = ["tests"]
+ filterwarnings = [
+     "error",
+     "ignore:unclosed <socket.socket.*:ResourceWarning",
+-    "ignore:unclosed transport <_ProactorSocketTransport.*:ResourceWarning"
++    "ignore:unclosed transport <_ProactorSocketTransport.*:ResourceWarning",
++    "ignore:The loop argument is deprecated.*:DeprecationWarning",
+ ]
+ markers = [
+     "network: marks tests as requiring Internet access",



More information about the arch-commits mailing list