!1 Init package python-nest-asyncio with v1.5.7
From: @li-miaomiao_zhr Reviewed-by: @desert-sailor Signed-off-by: @desert-sailor
This commit is contained in:
commit
d2f834ddaf
BIN
nest_asyncio-1.5.7.tar.gz
Normal file
BIN
nest_asyncio-1.5.7.tar.gz
Normal file
Binary file not shown.
56
python-nest_asyncio.spec
Normal file
56
python-nest_asyncio.spec
Normal file
@ -0,0 +1,56 @@
|
||||
%global _empty_manifest_terminate_build 0
|
||||
%global pypi_name nest_asyncio
|
||||
|
||||
%global _description %{expand:
|
||||
By design asyncio does not allow its event loop to be nested.
|
||||
This presents a practical problem: When in an environment
|
||||
where the event loop is already running it's impossible to run tasks
|
||||
and wait for the result. Trying to do so will give the error
|
||||
"RuntimeError: This event loop is already running".
|
||||
The issue pops up in various environments, such as web servers,
|
||||
GUI applications and in Jupyter notebooks.
|
||||
This module patches asyncio to allow nested use of asyncio.run
|
||||
and loop.run_until_complete.}
|
||||
|
||||
Name: python-%{pypi_name}
|
||||
Version: 1.5.7
|
||||
Release: 1
|
||||
Summary: Patch asyncio to allow nested event loops
|
||||
License: BSD
|
||||
URL: https://github.com/erdewit/nest_asyncio
|
||||
Source0: %{pypi_source}
|
||||
BuildArch: noarch
|
||||
|
||||
BuildRequires: python3-devel
|
||||
BuildRequires: python3-pip
|
||||
BuildRequires: python3-wheel
|
||||
BuildRequires: python3-setuptools
|
||||
BuildRequires: python3-setuptools_scm
|
||||
|
||||
%description %_description
|
||||
|
||||
%package -n python3-%{pypi_name}
|
||||
Summary: Patch asyncio to allow nested event loops
|
||||
%{?python_provide:%python_provide python3-%{pypi_name}}
|
||||
|
||||
%description -n python3-%{pypi_name} %_description
|
||||
|
||||
%prep
|
||||
%autosetup -n %{pypi_name}-%{version}
|
||||
|
||||
%build
|
||||
%pyproject_build
|
||||
|
||||
%install
|
||||
%pyproject_install
|
||||
|
||||
%files -n python3-%{pypi_name}
|
||||
%license LICENSE
|
||||
%doc README.rst
|
||||
%{python3_sitelib}/__pycache__/nest_asyncio.*
|
||||
%{python3_sitelib}/nest_asyncio-*.dist-info/
|
||||
%{python3_sitelib}/nest_asyncio.py
|
||||
|
||||
%changelog
|
||||
* Tue Aug 1 2023 li-miaomiao_zhr <mmlidc@isoftstone.com> - 1.5.7-1
|
||||
- package init
|
||||
Loading…
x
Reference in New Issue
Block a user