Date: Thursday, December 17, 2020 @ 09:19:52 Author: felixonmars Revision: 404430
archrelease: copy trunk to extra-any Added: python-requests/repos/extra-any/PKGBUILD (from rev 404429, python-requests/trunk/PKGBUILD) python-requests/repos/extra-any/certs.patch (from rev 404429, python-requests/trunk/certs.patch) Deleted: python-requests/repos/extra-any/PKGBUILD python-requests/repos/extra-any/certs.patch -------------+ PKGBUILD | 126 +++++++++++++++++++++++++++++----------------------------- certs.patch | 28 ++++++------ 2 files changed, 77 insertions(+), 77 deletions(-) Deleted: PKGBUILD =================================================================== --- PKGBUILD 2020-12-17 09:19:25 UTC (rev 404429) +++ PKGBUILD 2020-12-17 09:19:52 UTC (rev 404430) @@ -1,63 +0,0 @@ -# Maintainer: Felix Yan <felixonm...@archlinux.org> -# Contributor: Massimiliano Torromeo <massimiliano.torro...@gmail.com> - -pkgbase=python-requests -pkgname=('python-requests' 'python2-requests') -pkgver=2.25.0 -pkgrel=1 -pkgdesc="Python HTTP for Humans" -arch=('any') -url="http://python-requests.org" -license=('Apache') -makedepends=('python-setuptools' 'python2-setuptools' 'python-chardet' 'python2-chardet' - 'python-urllib3' 'python2-urllib3' 'python-idna' 'python2-idna') -checkdepends=('python-pytest-httpbin' 'python-pytest-mock' 'python-pysocks' 'python-pyopenssl') -source=("$pkgbase-$pkgver.tar.gz::https://github.com/psf/requests/archive/v$pkgver.tar.gz" - certs.patch) -sha512sums=('f60d8dbbc7aaebaedc7647ab2cec1fffd01547ea3340b91d9c7fea51fde4cb932aaf81e3b8aac9f4be11243e4fc44c8266a69db5f52c4eb2afb1b7714c150b95' - '424a3bb01b23409284f6c9cd2bc22d92df31b85cfd96e1d1b16b5d68adeca670dfed4fff7977d8b10980102b0f780eacc465431021fcd661f3a17168a02a39a3') - -prepare() { - cd "$srcdir"/requests-$pkgver - sed -e '/certifi/d' \ - -e "s/,<.*'/'/" \ - -i setup.py - patch -p1 -i "$srcdir"/certs.patch - - cd "$srcdir" - cp -a requests-$pkgver{,-py2} - find requests-$pkgver-py2 -name \*.py -exec sed -r 's|^#!(.*)python$|#!\1python2|' -i {} + -} - -build() { - cd "$srcdir"/requests-$pkgver - python setup.py build - - cd "$srcdir"/requests-$pkgver-py2 - python2 setup.py build -} - -check() { - # Seems to be a problem about pytest-httpbin - - cd requests-$pkgver - pytest tests --deselect tests/test_requests.py::TestRequests::test_https_warnings -} - -package_python-requests() { - depends=('python-urllib3' 'python-chardet' 'python-idna') - optdepends=('python-pysocks: SOCKS proxy support') - - cd "$srcdir"/requests-$pkgver - python setup.py install --skip-build -O1 --root="$pkgdir" -} - -package_python2-requests() { - depends=('python2-urllib3' 'python2-chardet' 'python2-idna') - optdepends=('python2-ndg-httpsclient: HTTPS requests with SNI support' - 'python2-grequests: asynchronous requests with gevent' - 'python2-pysocks: SOCKS proxy support') - - cd "$srcdir"/requests-$pkgver-py2 - python2 setup.py install --skip-build -O1 --root="$pkgdir" -} Copied: python-requests/repos/extra-any/PKGBUILD (from rev 404429, python-requests/trunk/PKGBUILD) =================================================================== --- PKGBUILD (rev 0) +++ PKGBUILD 2020-12-17 09:19:52 UTC (rev 404430) @@ -0,0 +1,63 @@ +# Maintainer: Felix Yan <felixonm...@archlinux.org> +# Contributor: Massimiliano Torromeo <massimiliano.torro...@gmail.com> + +pkgbase=python-requests +pkgname=('python-requests' 'python2-requests') +pkgver=2.25.1 +pkgrel=1 +pkgdesc="Python HTTP for Humans" +arch=('any') +url="http://python-requests.org" +license=('Apache') +makedepends=('python-setuptools' 'python2-setuptools' 'python-chardet' 'python2-chardet' + 'python-urllib3' 'python2-urllib3' 'python-idna' 'python2-idna') +checkdepends=('python-pytest-httpbin' 'python-pytest-mock' 'python-pysocks' 'python-pyopenssl') +source=("$pkgbase-$pkgver.tar.gz::https://github.com/psf/requests/archive/v$pkgver.tar.gz" + certs.patch) +sha512sums=('e4fc90b229925a2b580e5cd85c39e8b0fe8006e1e49d247efc38616120ffdab319fc200424eeb4fb7175114daf1b6f98ba5c2f4baa00ce17fdc79e880df60ad8' + '424a3bb01b23409284f6c9cd2bc22d92df31b85cfd96e1d1b16b5d68adeca670dfed4fff7977d8b10980102b0f780eacc465431021fcd661f3a17168a02a39a3') + +prepare() { + cd "$srcdir"/requests-$pkgver + sed -e '/certifi/d' \ + -e "s/,<.*'/'/" \ + -i setup.py + patch -p1 -i "$srcdir"/certs.patch + + cd "$srcdir" + cp -a requests-$pkgver{,-py2} + find requests-$pkgver-py2 -name \*.py -exec sed -r 's|^#!(.*)python$|#!\1python2|' -i {} + +} + +build() { + cd "$srcdir"/requests-$pkgver + python setup.py build + + cd "$srcdir"/requests-$pkgver-py2 + python2 setup.py build +} + +check() { + # Seems to be a problem about pytest-httpbin + + cd requests-$pkgver + pytest tests --deselect tests/test_requests.py::TestRequests::test_https_warnings +} + +package_python-requests() { + depends=('python-urllib3' 'python-chardet' 'python-idna') + optdepends=('python-pysocks: SOCKS proxy support') + + cd "$srcdir"/requests-$pkgver + python setup.py install --skip-build -O1 --root="$pkgdir" +} + +package_python2-requests() { + depends=('python2-urllib3' 'python2-chardet' 'python2-idna') + optdepends=('python2-ndg-httpsclient: HTTPS requests with SNI support' + 'python2-grequests: asynchronous requests with gevent' + 'python2-pysocks: SOCKS proxy support') + + cd "$srcdir"/requests-$pkgver-py2 + python2 setup.py install --skip-build -O1 --root="$pkgdir" +} Deleted: certs.patch =================================================================== --- certs.patch 2020-12-17 09:19:25 UTC (rev 404429) +++ certs.patch 2020-12-17 09:19:52 UTC (rev 404430) @@ -1,14 +0,0 @@ -diff --git a/requests/certs.py b/requests/certs.py -index d1a378d7..4e0bffd4 100644 ---- a/requests/certs.py -+++ b/requests/certs.py -@@ -12,7 +12,8 @@ If you are packaging Requests, e.g., for a Linux distribution or a managed - environment, you can change the definition of where() to return a separately - packaged CA bundle. - """ --from certifi import where -+def where(): -+ return "/etc/ssl/certs/ca-certificates.crt" - - if __name__ == '__main__': - print(where()) Copied: python-requests/repos/extra-any/certs.patch (from rev 404429, python-requests/trunk/certs.patch) =================================================================== --- certs.patch (rev 0) +++ certs.patch 2020-12-17 09:19:52 UTC (rev 404430) @@ -0,0 +1,14 @@ +diff --git a/requests/certs.py b/requests/certs.py +index d1a378d7..4e0bffd4 100644 +--- a/requests/certs.py ++++ b/requests/certs.py +@@ -12,7 +12,8 @@ If you are packaging Requests, e.g., for a Linux distribution or a managed + environment, you can change the definition of where() to return a separately + packaged CA bundle. + """ +-from certifi import where ++def where(): ++ return "/etc/ssl/certs/ca-certificates.crt" + + if __name__ == '__main__': + print(where())