diff --git a/README.en.md b/README.en.md deleted file mode 100644 index 4847f994ac7b5becdd4d37387870325b8c4dc5a9..0000000000000000000000000000000000000000 --- a/README.en.md +++ /dev/null @@ -1,36 +0,0 @@ -# python-eventlet - -#### Description -{**When you're done, you can delete the content in this README and update the file with details for others getting started with your repository**} - -#### Software Architecture -Software architecture description - -#### Installation - -1. xxxx -2. xxxx -3. xxxx - -#### Instructions - -1. xxxx -2. xxxx -3. xxxx - -#### Contribution - -1. Fork the repository -2. Create Feat_xxx branch -3. Commit your code -4. Create Pull Request - - -#### Gitee Feature - -1. You can use Readme\_XXX.md to support different languages, such as Readme\_en.md, Readme\_zh.md -2. Gitee blog [blog.gitee.com](https://blog.gitee.com) -3. Explore open source project [https://gitee.com/explore](https://gitee.com/explore) -4. The most valuable open source project [GVP](https://gitee.com/gvp) -5. The manual of Gitee [https://gitee.com/help](https://gitee.com/help) -6. The most popular members [https://gitee.com/gitee-stars/](https://gitee.com/gitee-stars/) diff --git a/README.md b/README.md deleted file mode 100644 index 815fee20f08824fc3786f6ccf2c8410e5ff756f1..0000000000000000000000000000000000000000 --- a/README.md +++ /dev/null @@ -1,39 +0,0 @@ -# python-eventlet - -#### 介绍 -{**以下是码云平台说明,您可以替换此简介** -码云是 OSCHINA 推出的基于 Git 的代码托管平台(同时支持 SVN)。专为开发者提供稳定、高效、安全的云端软件开发协作平台 -无论是个人、团队、或是企业,都能够用码云实现代码托管、项目管理、协作开发。企业项目请看 [https://gitee.com/enterprises](https://gitee.com/enterprises)} - -#### 软件架构 -软件架构说明 - - -#### 安装教程 - -1. xxxx -2. xxxx -3. xxxx - -#### 使用说明 - -1. xxxx -2. xxxx -3. xxxx - -#### 参与贡献 - -1. Fork 本仓库 -2. 新建 Feat_xxx 分支 -3. 提交代码 -4. 新建 Pull Request - - -#### 码云特技 - -1. 使用 Readme\_XXX.md 来支持不同的语言,例如 Readme\_en.md, Readme\_zh.md -2. 码云官方博客 [blog.gitee.com](https://blog.gitee.com) -3. 你可以 [https://gitee.com/explore](https://gitee.com/explore) 这个地址来了解码云上的优秀开源项目 -4. [GVP](https://gitee.com/gvp) 全称是码云最有价值开源项目,是码云综合评定出的优秀开源项目 -5. 码云官方提供的使用手册 [https://gitee.com/help](https://gitee.com/help) -6. 码云封面人物是一档用来展示码云会员风采的栏目 [https://gitee.com/gitee-stars/](https://gitee.com/gitee-stars/) diff --git a/eventlet-0.25.2.tar.gz b/eventlet-0.25.2.tar.gz new file mode 100644 index 0000000000000000000000000000000000000000..ed3aa499aa7979c8d396509da53a58e2580711eb Binary files /dev/null and b/eventlet-0.25.2.tar.gz differ diff --git a/eventlet-0.30.0.tar.gz b/eventlet-0.30.0.tar.gz deleted file mode 100644 index 1fe4dd68121c6aed9badabd0ea7e4790097c9206..0000000000000000000000000000000000000000 Binary files a/eventlet-0.30.0.tar.gz and /dev/null differ diff --git a/python-eventlet.spec b/python-eventlet.spec index 9579de53dce17752525e4d24428feaf6d3e8c586..86ad8fc728a8323381e90668dcaf3331919fe82c 100644 --- a/python-eventlet.spec +++ b/python-eventlet.spec @@ -1,78 +1,72 @@ -%global _empty_manifest_terminate_build 0 -Name: python-eventlet -Version: 0.30.0 -Release: 1 -Summary: Highly concurrent networking library -License: MIT License -URL: https://github.com/eventlet/eventlet -Source0: https://files.pythonhosted.org/packages/0c/dd/cda72b013472d570f9d5670b9260a6d6491829bd4b7697829e8591a24168/eventlet-0.30.0.tar.gz -BuildArch: noarch +%global modname eventlet -Requires: python3-dnspython -Requires: python3-greenlet -Requires: python3-six -Requires: python3-monotonic +Name: python-%{modname} +Version: 0.25.2 +Release: 1 +Summary: Highly concurrent networking library +License: MIT +URL: http://eventlet.net +Source0: https://files.pythonhosted.org/packages/2a/df/943d5aa7029b47dd3eb41e1ea48f843d3441d24b7e0b76a0b3af4df35a83/eventlet-0.25.2.tar.gz + +BuildArch: noarch %description -Concurrent networking library for Python +Eventlet is a networking library written in Python. It achieves high +scalability by using non-blocking io while at the same time retaining +high programmer usability by using coroutines to make the non-blocking +io operations appear blocking at the source code level. + +%package -n python2-%{modname} +Summary: %{summary} +BuildRequires: python2-devel +BuildRequires: python2-setuptools +BuildRequires: python2-nose +BuildRequires: python2-greenlet +BuildRequires: python2-pyOpenSSL +BuildRequires: python2-pbr +Requires: python2-greenlet +Requires: python2-enum34 +Requires: python2-dns +Requires: python2-monotonic +Requires: python2-six +%{?python_provide:%python_provide python2-%{modname}} -%package -n python3-eventlet -Summary: Highly concurrent networking library -Provides: python-eventlet -BuildRequires: python3-devel -BuildRequires: python3-setuptools -%description -n python3-eventlet -Concurrent networking library for Python +%description -n python2-%{modname} +Eventlet is a networking library written in Python. It achieves high +scalability by using non-blocking io while at the same time retaining +high programmer usability by using coroutines to make the non-blocking +io operations appear blocking at the source code level. -%package help -Summary: Development documents and examples for eventlet -Provides: python3-eventlet-doc -%description help -Concurrent networking library for Python %prep -%autosetup -n eventlet-0.30.0 +%autosetup -n %{modname}-%{version} -p1 +rm -vrf *.egg-info +# Remove dependency on enum-compat from setup.py. enum-compat is installed +# as Require for python2 subpackage and it is not needed for Python 3 +sed -i "/'enum-compat',/d" setup.py %build -%py3_build +%py2_build -%install -%py3_install -install -d -m755 %{buildroot}/%{_pkgdocdir} -if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi -if [ -d docs ]; then cp -arf docs %{buildroot}/%{_pkgdocdir}; fi -if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi -if [ -d examples ]; then cp -arf examples %{buildroot}/%{_pkgdocdir}; fi -pushd %{buildroot} -if [ -d usr/lib ]; then - find usr/lib -type f -printf "/%h/%f\n" >> filelist.lst -fi -if [ -d usr/lib64 ]; then - find usr/lib64 -type f -printf "/%h/%f\n" >> filelist.lst -fi -if [ -d usr/bin ]; then - find usr/bin -type f -printf "/%h/%f\n" >> filelist.lst -fi -if [ -d usr/sbin ]; then - find usr/sbin -type f -printf "/%h/%f\n" >> filelist.lst -fi -touch doclist.lst -if [ -d usr/share/man ]; then - find usr/share/man -type f -printf "/%h/%f.gz\n" >> doclist.lst -fi -popd -mv %{buildroot}/filelist.lst . -mv %{buildroot}/doclist.lst . -%files -n python3-eventlet -f filelist.lst -%dir %{python3_sitelib}/* +%install +%py2_install +rm -vrf %{buildroot}%{python2_sitelib}/tests +# FIXME: Those files are not meant to be used with Python 2.7 +# Anyway the whole module eventlet.green.http is Python 3 only +# Trying to import it will fail under Python 2.7 +# https://github.com/eventlet/eventlet/issues/369 +rm -rf %{buildroot}/%{python2_sitelib}/%{modname}/green/http/{cookiejar,client}.py -%files help -f doclist.lst -%{_docdir}/* +%files -n python2-%{modname} +%doc README.rst AUTHORS LICENSE NEWS +%license LICENSE +%{python2_sitelib}/%{modname}/ +%{python2_sitelib}/%{modname}-*.egg-info/ %changelog -* Fri Jan 15 2021 Python_Bot +* Tue Jun 15 2021 wangxiyuan +- Bump version to 0.25.2 +* Mon May 31 2021 openstack-sig - Package Spec generated -* Thu Mar 12 2020 zoushuangshuang - 0.23.0-3 -- Package init diff --git a/python37.patch b/python37.patch deleted file mode 100644 index 62816babd721b1f353b0fdd28fb0b2ca10a5bdb1..0000000000000000000000000000000000000000 --- a/python37.patch +++ /dev/null @@ -1,140 +0,0 @@ -From 0d4e7bcb90800d6700b2c81c41c9770ee5f94358 Mon Sep 17 00:00:00 2001 -From: Marcel Plch -Date: Mon, 9 Jul 2018 16:45:45 +0200 -Subject: [PATCH] Fix for Python 3.7 - ---- - eventlet/green/ssl.py | 46 ++++++++++++++++++++++++++++++++++++++++------ - tests/debug_test.py | 14 ++++++++++++-- - tests/hub_test.py | 4 +++- - 3 files changed, 55 insertions(+), 9 deletions(-) - -diff --git a/eventlet/green/ssl.py b/eventlet/green/ssl.py -index 53ee9a3c..df72869e 100644 ---- a/eventlet/green/ssl.py -+++ b/eventlet/green/ssl.py -@@ -24,6 +24,7 @@ - 'create_default_context', '_create_default_https_context'] - - _original_sslsocket = __ssl.SSLSocket -+_original_wrap_socket = __ssl.wrap_socket - - - class GreenSSLSocket(_original_sslsocket): -@@ -57,11 +58,41 @@ def __init__(self, sock, keyfile=None, certfile=None, - # this assignment - self._timeout = sock.gettimeout() - -- # nonblocking socket handshaking on connect got disabled so let's pretend it's disabled -- # even when it's on -- super(GreenSSLSocket, self).__init__( -- sock.fd, keyfile, certfile, server_side, cert_reqs, ssl_version, -- ca_certs, do_handshake_on_connect and six.PY2, *args, **kw) -+ if sys.version_info >= (3, 7): -+ # Monkey-patch the sslsocket so our modified self gets -+ # injected into its _create method. -+ def fake_new(self, cls, *args, **kwargs): -+ return self -+ -+ orig_new = _original_sslsocket.__new__ -+ try: -+ _original_sslsocket.__new__ = fake_new.__get__(self, GreenSSLSocket) -+ -+ self = _original_wrap_socket( -+ sock=sock.fd, -+ keyfile=keyfile, -+ certfile=certfile, -+ server_side=server_side, -+ cert_reqs=cert_reqs, -+ ssl_version=ssl_version, -+ ca_certs=ca_certs, -+ do_handshake_on_connect=do_handshake_on_connect and six.PY2, -+ *args, **kw -+ ) -+ self.keyfile = keyfile -+ self.certfile = certfile -+ self.cert_reqs = cert_reqs -+ self.ssl_version = ssl_version -+ self.ca_certs = ca_certs -+ finally: -+ # Unpatch -+ _original_sslsocket.__new__ = orig_new -+ else: -+ # nonblocking socket handshaking on connect got disabled so let's pretend it's disabled -+ # even when it's on -+ super(GreenSSLSocket, self).__init__( -+ sock.fd, keyfile, certfile, server_side, cert_reqs, ssl_version, -+ ca_certs, do_handshake_on_connect and six.PY2, *args, **kw) - - # the superclass initializer trashes the methods so we remove - # the local-object versions of them and let the actual class -@@ -323,7 +354,10 @@ def connect(self, addr): - except NameError: - self._sslobj = sslobj - else: -- self._sslobj = SSLObject(sslobj, owner=self) -+ if sys.version_info < (3, 7): -+ self._sslobj = SSLObject(sslobj, owner=self) -+ else: -+ self._sslobj = sslobj - - if self.do_handshake_on_connect: - self.do_handshake() -diff --git a/tests/debug_test.py b/tests/debug_test.py -index 8299dede..82b3a834 100644 ---- a/tests/debug_test.py -+++ b/tests/debug_test.py -@@ -29,6 +29,11 @@ def test_unspew(self): - assert self.tracer is None - - def test_line(self): -+ if sys.version_info >= (3, 7): -+ frame_str = "f== (3, 7): -+ frame_str = "f=