Date: Sunday, September 16, 2018 @ 18:36:40 Author: eschwartz Revision: 382222
archrelease: copy trunk to community-any Added: apache-libcloud/repos/community-any/PKGBUILD (from rev 382221, apache-libcloud/trunk/PKGBUILD) apache-libcloud/repos/community-any/py3.7.diff (from rev 382221, apache-libcloud/trunk/py3.7.diff) Deleted: apache-libcloud/repos/community-any/PKGBUILD apache-libcloud/repos/community-any/py3.7.diff ------------+ PKGBUILD | 125 +++++++++++++++++---------------- py3.7.diff | 218 +++++++++++++++++++++++++++++------------------------------ 2 files changed, 172 insertions(+), 171 deletions(-) Deleted: PKGBUILD =================================================================== --- PKGBUILD 2018-09-16 18:36:26 UTC (rev 382221) +++ PKGBUILD 2018-09-16 18:36:40 UTC (rev 382222) @@ -1,62 +0,0 @@ -# $Id$ -# Maintainer: Felix Yan <felixonm...@archlinux.org> -# Contributor: Daniel Wallace <danielwallace at gtmanfred dot com> -# Contributor: Lex Black <autumn-wind at web dot de> -# Contributor: Alasdair Haswell <ali at arhaswell dot co dot uk> - -pkgbase=apache-libcloud -pkgname=('python-apache-libcloud' 'python2-apache-libcloud') -pkgver=2.3.0 -pkgrel=2 -pkgdesc="Apache Libcloud is a standard Python library that abstracts away differences among multiple cloud provider APIs" -arch=('any') -url="https://libcloud.apache.org" -license=('Apache') -makedepends=('python-setuptools' 'python2-setuptools' 'python-requests' 'python2-requests') -checkdepends=('python-mock' 'python2-mock' 'python-pytest-runner' 'python2-pytest-runner' 'openssh' - 'python-requests-mock' 'python2-requests-mock') -source=("https://pypi.io/packages/source/a/apache-libcloud/apache-libcloud-${pkgver}.tar.gz" - py3.7.diff) -sha512sums=('3c77b0261a9386af7b215f354126d0f3189209eeab3cac8e02eabddcb36ccc979159e148854bf0118ba2d8b9fa5bf57f493b144b860b1809c9aeff9efb0161a5' - '080da5aab7ca75c0041dab927526921cb4ebcbb9fdd4a8bf35baca214a378f962c3a9ba7ea55b262ffb4ff2d02b84fddee3483cdaa7c869d386cc24e2834cd71') - -prepare() { - patch -d apache-libcloud-$pkgver -p1 < py3.7.diff - cp -a apache-libcloud-$pkgver{,-py2} -} - -build() { - cd "$srcdir/apache-libcloud-$pkgver" - python setup.py build - - cd "$srcdir/apache-libcloud-$pkgver-py2" - python2 setup.py build -} - -check() { - cd "$srcdir/apache-libcloud-$pkgver" - cp libcloud/test/secrets.py-dist libcloud/test/secrets.py - python setup.py test - rm libcloud/test/secrets.py - - cd "$srcdir/apache-libcloud-$pkgver-py2" - cp libcloud/test/secrets.py-dist libcloud/test/secrets.py - python2 setup.py test - rm libcloud/test/secrets.py -} - -package_python-apache-libcloud() { - depends=('python-requests') - - cd apache-libcloud-$pkgver - python setup.py install --root="$pkgdir" -} - -package_python2-apache-libcloud() { - depends=('python2-requests') - replaces=('apache-libcloud') - conflicts=('apache-libcloud') - - cd apache-libcloud-$pkgver-py2 - python2 setup.py install --root="$pkgdir" -} Copied: apache-libcloud/repos/community-any/PKGBUILD (from rev 382221, apache-libcloud/trunk/PKGBUILD) =================================================================== --- PKGBUILD (rev 0) +++ PKGBUILD 2018-09-16 18:36:40 UTC (rev 382222) @@ -0,0 +1,63 @@ +# Maintainer: Felix Yan <felixonm...@archlinux.org> +# Contributor: Daniel Wallace <danielwallace at gtmanfred dot com> +# Contributor: Lex Black <autumn-wind at web dot de> +# Contributor: Alasdair Haswell <ali at arhaswell dot co dot uk> + +pkgbase=apache-libcloud +pkgname=('python-apache-libcloud' 'python2-apache-libcloud') +pkgver=2.3.0 +pkgrel=3 +pkgdesc="A standard Python library that abstracts away differences among multiple cloud provider APIs" +arch=('any') +url="https://libcloud.apache.org" +license=('Apache') +makedepends=('python-setuptools' 'python2-setuptools' 'python-requests' 'python2-requests') +checkdepends=('python-mock' 'python2-mock' 'python-pytest-runner' 'python2-pytest-runner' 'openssh' + 'python-requests-mock' 'python2-requests-mock') +source=("https://pypi.io/packages/source/a/apache-libcloud/apache-libcloud-${pkgver}.tar.gz"{,.asc} + py3.7.diff) +sha512sums=('3c77b0261a9386af7b215f354126d0f3189209eeab3cac8e02eabddcb36ccc979159e148854bf0118ba2d8b9fa5bf57f493b144b860b1809c9aeff9efb0161a5' + 'SKIP' + '080da5aab7ca75c0041dab927526921cb4ebcbb9fdd4a8bf35baca214a378f962c3a9ba7ea55b262ffb4ff2d02b84fddee3483cdaa7c869d386cc24e2834cd71') +validpgpkeys=('3ACBB4086C01F7376628088CAB4A19AE1CE85744') # Anthony Shaw <anthonys...@apache.org> + +prepare() { + patch -d apache-libcloud-$pkgver -p1 < py3.7.diff + cp -a apache-libcloud-$pkgver{,-py2} +} + +build() { + cd "$srcdir/apache-libcloud-$pkgver" + python setup.py build + + cd "$srcdir/apache-libcloud-$pkgver-py2" + python2 setup.py build +} + +check() { + cd "$srcdir/apache-libcloud-$pkgver" + cp libcloud/test/secrets.py-dist libcloud/test/secrets.py + python setup.py test + rm libcloud/test/secrets.py + + cd "$srcdir/apache-libcloud-$pkgver-py2" + cp libcloud/test/secrets.py-dist libcloud/test/secrets.py + python2 setup.py test + rm libcloud/test/secrets.py +} + +package_python-apache-libcloud() { + depends=('python-requests') + + cd apache-libcloud-$pkgver + python setup.py install --root="$pkgdir" +} + +package_python2-apache-libcloud() { + depends=('python2-requests') + replaces=('apache-libcloud') + conflicts=('apache-libcloud') + + cd apache-libcloud-$pkgver-py2 + python2 setup.py install --root="$pkgdir" +} Deleted: py3.7.diff =================================================================== --- py3.7.diff 2018-09-16 18:36:26 UTC (rev 382221) +++ py3.7.diff 2018-09-16 18:36:40 UTC (rev 382222) @@ -1,109 +0,0 @@ -diff -u -r apache-libcloud-2.3.0/libcloud/common/dimensiondata.py apache-libcloud-2.3.0-py3.7/libcloud/common/dimensiondata.py ---- apache-libcloud-2.3.0/libcloud/common/dimensiondata.py 2017-04-11 00:03:27.000000000 +0200 -+++ apache-libcloud-2.3.0-py3.7/libcloud/common/dimensiondata.py 2018-07-29 17:14:21.030942695 +0200 -@@ -526,7 +526,7 @@ - method).object - yield resp - if len(resp) <= 0: -- raise StopIteration -+ return - - pcount = resp.get('pageCount') # pylint: disable=no-member - psize = resp.get('pageSize') # pylint: disable=no-member -diff -u -r apache-libcloud-2.3.0/libcloud/compute/drivers/azure.py apache-libcloud-2.3.0-py3.7/libcloud/compute/drivers/azure.py ---- apache-libcloud-2.3.0/libcloud/compute/drivers/azure.py 2017-04-24 04:18:37.000000000 +0200 -+++ apache-libcloud-2.3.0-py3.7/libcloud/compute/drivers/azure.py 2018-07-29 17:14:21.034276037 +0200 -@@ -1435,7 +1435,7 @@ - - return response - -- def _perform_post(self, path, body, response_type=None, async=False): -+ def _perform_post(self, path, body, response_type=None, is_async=False): - request = AzureHTTPRequest() - request.method = 'POST' - request.host = AZURE_SERVICE_MANAGEMENT_HOST -@@ -1447,7 +1447,7 @@ - - return response - -- def _perform_put(self, path, body, response_type=None, async=False): -+ def _perform_put(self, path, body, response_type=None, is_async=False): - request = AzureHTTPRequest() - request.method = 'PUT' - request.host = AZURE_SERVICE_MANAGEMENT_HOST -@@ -1459,7 +1459,7 @@ - - return response - -- def _perform_delete(self, path, async=False): -+ def _perform_delete(self, path, is_async=False): - request = AzureHTTPRequest() - request.method = 'DELETE' - request.host = AZURE_SERVICE_MANAGEMENT_HOST -@@ -1470,7 +1470,7 @@ - - self.raise_for_response(response, 202) - -- if async: -+ if is_async: - return self._parse_response_for_async_op(response) - - def _perform_request(self, request): -diff -u -r apache-libcloud-2.3.0/libcloud/storage/drivers/dummy.py apache-libcloud-2.3.0-py3.7/libcloud/storage/drivers/dummy.py ---- apache-libcloud-2.3.0/libcloud/storage/drivers/dummy.py 2017-04-11 00:03:27.000000000 +0200 -+++ apache-libcloud-2.3.0-py3.7/libcloud/storage/drivers/dummy.py 2018-07-29 17:14:21.034276037 +0200 -@@ -44,8 +44,6 @@ - yield self._get_chunk(self._chunk_len) - i += 1 - -- raise StopIteration -- - def _get_chunk(self, chunk_len): - chunk = [str(x) for x in random.randint(97, 120)] - return chunk -diff -u -r apache-libcloud-2.3.0/libcloud/utils/py3.py apache-libcloud-2.3.0-py3.7/libcloud/utils/py3.py ---- apache-libcloud-2.3.0/libcloud/utils/py3.py 2018-02-02 08:53:42.000000000 +0100 -+++ apache-libcloud-2.3.0-py3.7/libcloud/utils/py3.py 2018-07-29 17:15:20.421118700 +0200 -@@ -42,6 +42,7 @@ - PY2 = False - PY27 = False - PY3 = False -+PY37 = False - - if sys.version_info >= (2, 0) and sys.version_info < (3, 0): - PY2 = True -@@ -52,6 +53,9 @@ - if sys.version_info >= (3, 0): - PY3 = True - -+if sys.version_info >= (3, 7): -+ PY37 = True -+ - if PY2_pre_279: - try: - from backports.ssl_match_hostname import match_hostname, CertificateError # NOQA -@@ -71,7 +75,7 @@ - import urllib.parse as urlparse - import xmlrpc.client as xmlrpclib - -- from urllib.parse import quote as urlquote -+ from urllib.parse import quote as _urlquote - from urllib.parse import unquote as urlunquote - from urllib.parse import urlencode as urlencode - from os.path import relpath -@@ -124,6 +128,15 @@ - def tostring(node): - return ET.tostring(node, encoding='unicode') - -+ if PY37: -+ def urlquote(s, safe='/'): -+ res = _urlquote(s, safe) -+ if '~' not in safe: -+ res = res.replace('~', '%7E') -+ return res -+ else: -+ urlquote = _urlquote -+ - def hexadigits(s): - # s needs to be a byte string. - return [format(x, "x") for x in s] Copied: apache-libcloud/repos/community-any/py3.7.diff (from rev 382221, apache-libcloud/trunk/py3.7.diff) =================================================================== --- py3.7.diff (rev 0) +++ py3.7.diff 2018-09-16 18:36:40 UTC (rev 382222) @@ -0,0 +1,109 @@ +diff -u -r apache-libcloud-2.3.0/libcloud/common/dimensiondata.py apache-libcloud-2.3.0-py3.7/libcloud/common/dimensiondata.py +--- apache-libcloud-2.3.0/libcloud/common/dimensiondata.py 2017-04-11 00:03:27.000000000 +0200 ++++ apache-libcloud-2.3.0-py3.7/libcloud/common/dimensiondata.py 2018-07-29 17:14:21.030942695 +0200 +@@ -526,7 +526,7 @@ + method).object + yield resp + if len(resp) <= 0: +- raise StopIteration ++ return + + pcount = resp.get('pageCount') # pylint: disable=no-member + psize = resp.get('pageSize') # pylint: disable=no-member +diff -u -r apache-libcloud-2.3.0/libcloud/compute/drivers/azure.py apache-libcloud-2.3.0-py3.7/libcloud/compute/drivers/azure.py +--- apache-libcloud-2.3.0/libcloud/compute/drivers/azure.py 2017-04-24 04:18:37.000000000 +0200 ++++ apache-libcloud-2.3.0-py3.7/libcloud/compute/drivers/azure.py 2018-07-29 17:14:21.034276037 +0200 +@@ -1435,7 +1435,7 @@ + + return response + +- def _perform_post(self, path, body, response_type=None, async=False): ++ def _perform_post(self, path, body, response_type=None, is_async=False): + request = AzureHTTPRequest() + request.method = 'POST' + request.host = AZURE_SERVICE_MANAGEMENT_HOST +@@ -1447,7 +1447,7 @@ + + return response + +- def _perform_put(self, path, body, response_type=None, async=False): ++ def _perform_put(self, path, body, response_type=None, is_async=False): + request = AzureHTTPRequest() + request.method = 'PUT' + request.host = AZURE_SERVICE_MANAGEMENT_HOST +@@ -1459,7 +1459,7 @@ + + return response + +- def _perform_delete(self, path, async=False): ++ def _perform_delete(self, path, is_async=False): + request = AzureHTTPRequest() + request.method = 'DELETE' + request.host = AZURE_SERVICE_MANAGEMENT_HOST +@@ -1470,7 +1470,7 @@ + + self.raise_for_response(response, 202) + +- if async: ++ if is_async: + return self._parse_response_for_async_op(response) + + def _perform_request(self, request): +diff -u -r apache-libcloud-2.3.0/libcloud/storage/drivers/dummy.py apache-libcloud-2.3.0-py3.7/libcloud/storage/drivers/dummy.py +--- apache-libcloud-2.3.0/libcloud/storage/drivers/dummy.py 2017-04-11 00:03:27.000000000 +0200 ++++ apache-libcloud-2.3.0-py3.7/libcloud/storage/drivers/dummy.py 2018-07-29 17:14:21.034276037 +0200 +@@ -44,8 +44,6 @@ + yield self._get_chunk(self._chunk_len) + i += 1 + +- raise StopIteration +- + def _get_chunk(self, chunk_len): + chunk = [str(x) for x in random.randint(97, 120)] + return chunk +diff -u -r apache-libcloud-2.3.0/libcloud/utils/py3.py apache-libcloud-2.3.0-py3.7/libcloud/utils/py3.py +--- apache-libcloud-2.3.0/libcloud/utils/py3.py 2018-02-02 08:53:42.000000000 +0100 ++++ apache-libcloud-2.3.0-py3.7/libcloud/utils/py3.py 2018-07-29 17:15:20.421118700 +0200 +@@ -42,6 +42,7 @@ + PY2 = False + PY27 = False + PY3 = False ++PY37 = False + + if sys.version_info >= (2, 0) and sys.version_info < (3, 0): + PY2 = True +@@ -52,6 +53,9 @@ + if sys.version_info >= (3, 0): + PY3 = True + ++if sys.version_info >= (3, 7): ++ PY37 = True ++ + if PY2_pre_279: + try: + from backports.ssl_match_hostname import match_hostname, CertificateError # NOQA +@@ -71,7 +75,7 @@ + import urllib.parse as urlparse + import xmlrpc.client as xmlrpclib + +- from urllib.parse import quote as urlquote ++ from urllib.parse import quote as _urlquote + from urllib.parse import unquote as urlunquote + from urllib.parse import urlencode as urlencode + from os.path import relpath +@@ -124,6 +128,15 @@ + def tostring(node): + return ET.tostring(node, encoding='unicode') + ++ if PY37: ++ def urlquote(s, safe='/'): ++ res = _urlquote(s, safe) ++ if '~' not in safe: ++ res = res.replace('~', '%7E') ++ return res ++ else: ++ urlquote = _urlquote ++ + def hexadigits(s): + # s needs to be a byte string. + return [format(x, "x") for x in s]