-
Notifications
You must be signed in to change notification settings - Fork 87
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
dev-python/aiohttp-cors: bump to python3.8
Package-Manager: Portage-2.3.99, Repoman-2.3.22 Signed-off-by: Alessandro Barbieri <lssndrbarbieri@gmail.com>
- Loading branch information
1 parent
2db41d8
commit 7406ddd
Showing
1 changed file
with
36 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# Copyright 1999-2020 Gentoo Authors | ||
# Distributed under the terms of the GNU General Public License v2 | ||
|
||
EAPI="7" | ||
|
||
PYTHON_COMPAT=( python3_{6,7,8} ) | ||
|
||
inherit distutils-r1 | ||
|
||
DESCRIPTION="Implements CORS support for aiohttp asyncio-powered asynchronous HTTP server" | ||
HOMEPAGE="https://github.com/aio-libs/aiohttp-cors" | ||
SRC_URI="https://github.com/aio-libs/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz" | ||
|
||
LICENSE="Apache-2.0" | ||
SLOT="0" | ||
KEYWORDS="~amd64 ~x86" | ||
|
||
RDEPEND=">=dev-python/aiohttp-1.1.1[${PYTHON_USEDEP}]" | ||
BDEPEND=" | ||
test? ( | ||
dev-python/pytest-aiohttp[${PYTHON_USEDEP}] | ||
dev-python/selenium[${PYTHON_USEDEP}] | ||
)" | ||
|
||
distutils_enable_tests pytest | ||
|
||
# https://github.com/aio-libs/aiohttp-cors/pull/278 | ||
PATCHES=( | ||
"${FILESDIR}/${P}-tests.patch" | ||
"${FILESDIR}/${P}-py3_7.patch" | ||
) | ||
|
||
src_prepare() { | ||
sed -i -e '/^addopts=/d' setup.cfg || die | ||
distutils-r1_src_prepare | ||
} |
7406ddd
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Test fail with py3_8 for me:
ERROR tests/unit/test_cors_config.py - DeprecationWarning: "@coroutine" decorator is deprecated since Python 3.8, use "async def" instead
Are you sure we should add py3_8 here?
7406ddd
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
reverting
7406ddd
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Or should we restrict the tests?
aio-libs/aiohttp-cors#280
psf/black#1365
7406ddd
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That depends on if the package itself works with py3_8. However, considering that aiohttp-cors does not even officially support py3_7 yet, I expect that it won't work with py3_8 either.