From 60d1f67e623797b938086b60ea72ee98b2799c74 Mon Sep 17 00:00:00 2001
From: Celeste <20312-Celeste@users.gitlab.alpinelinux.org>
Date: Thu, 5 Oct 2023 04:11:42 +0000
Subject: [PATCH] community/py3-nest_asyncio: upgrade to 1.5.8 & use gpep517
 packaging

---
 community/py3-nest_asyncio/APKBUILD | 17 +++++++++++------
 1 file changed, 11 insertions(+), 6 deletions(-)

diff --git a/community/py3-nest_asyncio/APKBUILD b/community/py3-nest_asyncio/APKBUILD
index e4a9e6cc8d63..8bdb297a1932 100644
--- a/community/py3-nest_asyncio/APKBUILD
+++ b/community/py3-nest_asyncio/APKBUILD
@@ -1,30 +1,35 @@
 # Contributor: Aiden Grossman <agrossman154@yahoo.com>
 # Maintainer: Aiden Grossman <agrossman154@yahoo.com>
 pkgname=py3-nest_asyncio
-pkgver=1.5.7
+pkgver=1.5.8
 pkgrel=0
 pkgdesc="Asyncio patch to allow nested event loops"
 url="https://github.com/erdewit/nest_asyncio"
 arch="noarch"
 license="BSD-2-Clause"
-makedepends="py3-setuptools"
+makedepends="py3-gpep517 py3-setuptools py3-wheel"
 checkdepends="py3-pytest"
 subpackages="$pkgname-pyc"
 source="$pkgname-$pkgver.tar.gz::https://github.com/erdewit/nest_asyncio/archive/refs/tags/v$pkgver.tar.gz"
 builddir="$srcdir/nest_asyncio-$pkgver"
 
 build() {
-	python3 setup.py build
+	gpep517 build-wheel \
+		--wheel-dir .dist \
+		--output-fd 3 3>&1 >&2
 }
 
 check() {
-	pytest
+	python3 -m venv --clear --without-pip --system-site-packages .testenv
+	.testenv/bin/python3 -m installer .dist/*.whl
+	.testenv/bin/python3 -m pytest
 }
 
 package() {
-	python3 setup.py install --skip-build --root="$pkgdir"
+	python3 -m installer -d "$pkgdir" \
+		.dist/*.whl
 }
 
 sha512sums="
-486f2163e16033fb8d21f823fd99fc661342ef90ebc4a57eb49cd9533712e7b215298807b746aefc622fd00ea07298a2325fc69f5cabbf4a98450e31171fb2f2  py3-nest_asyncio-1.5.7.tar.gz
+845900760e50fa0d1aee75f93707dfbbf14044805e1cae53beff42091cbd6855ad134bcfa0130b4b422208270a49efeea415d0c2a7597d37019868c929102f2e  py3-nest_asyncio-1.5.8.tar.gz
 "
-- 
GitLab