[arch-commits] Commit in python-websocket-client/trunk (2 files)
Felix Yan
felixonmars at archlinux.org
Sun Feb 24 23:16:08 UTC 2019
Date: Sunday, February 24, 2019 @ 23:16:07
Author: felixonmars
Revision: 435619
upgpkg: python-websocket-client 0.55.0-1
Modified:
python-websocket-client/trunk/PKGBUILD
Deleted:
python-websocket-client/trunk/retry-connect-on-EINTR.patch
------------------------------+
PKGBUILD | 13 ++-----
retry-connect-on-EINTR.patch | 68 -----------------------------------------
2 files changed, 4 insertions(+), 77 deletions(-)
Modified: PKGBUILD
===================================================================
--- PKGBUILD 2019-02-24 23:15:11 UTC (rev 435618)
+++ PKGBUILD 2019-02-24 23:16:07 UTC (rev 435619)
@@ -8,25 +8,20 @@
_pkgbase='websocket-client'
__pkgbase="${_pkgbase//-/_}"
pkgname=("python-${_pkgbase}" "python2-${_pkgbase}")
-pkgver=0.54.0
-pkgrel=2
+pkgver=0.55.0
+pkgrel=1
pkgdesc="WebSocket client library for Python"
arch=(any)
url="https://github.com/${_pkgbase}/${_pkgbase}"
license=('LGPL')
makedepends=('python-setuptools' 'python2-setuptools' 'python-six' 'python2-six')
-source=("https://pypi.io/packages/source/w/${_pkgbase}/${__pkgbase}-${pkgver}.tar.gz"
- 'retry-connect-on-EINTR.patch')
-sha512sums=('ba4dfb6b879ec88ca446f44a77b91bbace55faa1a276f493174f3dc5b96b4d400d43c886798666da98e331610f71b4629f894d97f4614acf8d64affe8370bfec'
- '51c1c84de6f6c7600aa4bbacb923908acd69b4ae2dc21e0861c9f3e14e339580b0b094991821c2b34277fb427d4cbbd2407360316b267a3e67354ca89725c50c')
+source=("https://pypi.io/packages/source/w/${_pkgbase}/${__pkgbase}-${pkgver}.tar.gz")
+sha512sums=('d8f47f9872df04da5dcef71f392cbe41e5744a4a3b2b9a92ccc457a0761aa5bbeab23a8199d5e57ac617402c5f28465b7990dd11dd56a5ce2afff191856715d0')
prepare() {
# Not sure why the conditions are not working :/
sed -i "s/'backports.ssl_match_hostname'//" "${srcdir}/${__pkgbase}-${pkgver}/setup.py"
- cd "${srcdir}/${__pkgbase}-${pkgver}"
- patch -p1 -N -l -i "${srcdir}/retry-connect-on-EINTR.patch"
-
cp -a "${srcdir}/${__pkgbase}-${pkgver}"{,-py2}
}
Deleted: retry-connect-on-EINTR.patch
===================================================================
--- retry-connect-on-EINTR.patch 2019-02-24 23:15:11 UTC (rev 435618)
+++ retry-connect-on-EINTR.patch 2019-02-24 23:16:07 UTC (rev 435619)
@@ -1,68 +0,0 @@
-From 9a146e32e153fa1e0111b216f32c4b0e35ec9c12 Mon Sep 17 00:00:00 2001
-From: Trygve Aaberge <trygveaa at gmail.com>
-Date: Tue, 19 Feb 2019 23:55:59 +0100
-Subject: [PATCH] Retry connect on "Interrupted system call"
-
-When connecting to a socket, EINTR ("Interrupted system call") may be
-raised if the application receives a signal at the same time. Prior to
-Python 3.5, applications has to handle this themselves by retrying the
-connection. For more details, see https://www.python.org/dev/peps/pep-0475/
-
-Fixes #527
----
- websocket/_http.py | 38 ++++++++++++++++++++++----------------
- 1 file changed, 22 insertions(+), 16 deletions(-)
-
-diff --git a/websocket/_http.py b/websocket/_http.py
-index e7f1e2e..dd982db 100644
---- a/websocket/_http.py
-+++ b/websocket/_http.py
-@@ -166,26 +166,32 @@ def _open_socket(addrinfo_list, sockopt, timeout):
- sock.setsockopt(*opts)
-
- address = addrinfo[4]
-- try:
-- sock.connect(address)
-- err = None
-- except ProxyConnectionError as error:
-- err = WebSocketProxyException(str(error))
-- err.remote_ip = str(address[0])
-- continue
-- except socket.error as error:
-- error.remote_ip = str(address[0])
-+ err = None
-+ while not err:
- try:
-- eConnRefused = (errno.ECONNREFUSED, errno.WSAECONNREFUSED)
-- except:
-- eConnRefused = (errno.ECONNREFUSED, )
-- if error.errno in eConnRefused:
-- err = error
-+ sock.connect(address)
-+ except ProxyConnectionError as error:
-+ err = WebSocketProxyException(str(error))
-+ err.remote_ip = str(address[0])
- continue
-+ except socket.error as error:
-+ error.remote_ip = str(address[0])
-+ try:
-+ eConnRefused = (errno.ECONNREFUSED, errno.WSAECONNREFUSED)
-+ except:
-+ eConnRefused = (errno.ECONNREFUSED, )
-+ if error.errno == errno.EINTR:
-+ continue
-+ elif error.errno in eConnRefused:
-+ err = error
-+ continue
-+ else:
-+ raise error
- else:
-- raise error
-+ break
- else:
-- break
-+ continue
-+ break
- else:
- raise err
-
More information about the arch-commits
mailing list