From 81ffef7dde57a345a434fff6179823216fb4b185cbd39bcd17845172e06a4bf6 Mon Sep 17 00:00:00 2001 From: Dirk Mueller Date: Wed, 21 Oct 2015 08:00:58 +0000 Subject: [PATCH 1/5] - fix requires OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-requests?expand=0&rev=77 --- python-requests.changes | 5 +++++ python-requests.spec | 6 +++--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/python-requests.changes b/python-requests.changes index 3a3c8d8..1b1ab07 100644 --- a/python-requests.changes +++ b/python-requests.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Wed Oct 21 08:00:52 UTC 2015 - dmueller@suse.com + +- fix requires + ------------------------------------------------------------------- Wed Oct 14 19:24:43 UTC 2015 - sor.alexei@meowr.ru diff --git a/python-requests.spec b/python-requests.spec index 3bf3208..fd3df91 100644 --- a/python-requests.spec +++ b/python-requests.spec @@ -33,9 +33,9 @@ BuildRequires: python-devel BuildRequires: python-py BuildRequires: python-setuptools Requires: python -Requires: python-chardet -Requires: python-py -Requires: python-urllib3 +Requires: python-ndg-httpsclient +Requires: python-pyOpenSSL +Requires: python-pyasn1 %if 0%{?suse_version} <= 1110 %{!?python_sitelib: %global python_sitelib %(python -c "from distutils.sysconfig import get_python_lib; print get_python_lib()")} BuildRoot: %{_tmppath}/%{name}-%{version}-build From abe5af4ccd55c2aa9373f01f807bdd62d3639b9b7724526996f8146efe7c4b6c Mon Sep 17 00:00:00 2001 From: Dirk Mueller Date: Wed, 21 Oct 2015 16:30:25 +0000 Subject: [PATCH 2/5] OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-requests?expand=0&rev=78 --- python-requests.spec | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/python-requests.spec b/python-requests.spec index fd3df91..e5e33ee 100644 --- a/python-requests.spec +++ b/python-requests.spec @@ -33,7 +33,8 @@ BuildRequires: python-devel BuildRequires: python-py BuildRequires: python-setuptools Requires: python -Requires: python-ndg-httpsclient +# really needed? +#Requires: python-ndg-httpsclient Requires: python-pyOpenSSL Requires: python-pyasn1 %if 0%{?suse_version} <= 1110 From 6ea8cd990e8c589ea19058229223574af904bab4ea4c4a78a6cd794b2048e23e Mon Sep 17 00:00:00 2001 From: Dirk Mueller Date: Wed, 21 Oct 2015 20:51:25 +0000 Subject: [PATCH 3/5] - remove requests-do-not-use-bundle.patch (bsc#947357) OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-requests?expand=0&rev=79 --- python-requests.changes | 5 ++ python-requests.spec | 3 - requests-do-not-use-bundle.patch | 111 ------------------------------- 3 files changed, 5 insertions(+), 114 deletions(-) delete mode 100644 requests-do-not-use-bundle.patch diff --git a/python-requests.changes b/python-requests.changes index 1b1ab07..3e0979d 100644 --- a/python-requests.changes +++ b/python-requests.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Wed Oct 21 20:49:30 UTC 2015 - dmueller@suse.com + +- remove requests-do-not-use-bundle.patch (bsc#947357) + ------------------------------------------------------------------- Wed Oct 21 08:00:52 UTC 2015 - dmueller@suse.com diff --git a/python-requests.spec b/python-requests.spec index e5e33ee..9d7b75a 100644 --- a/python-requests.spec +++ b/python-requests.spec @@ -26,8 +26,6 @@ Url: http://python-requests.org Source: http://pypi.python.org/packages/source/r/requests/requests-%{version}.tar.gz # PATCH-FIX-OPENSUSE no-default-cacert.patch -- completely ignore the internal CA bundle Patch0: no-default-cacert.patch -# PATCH-FIX-OPENSUSE requests-do-not-use-bundle.patch --use system libraries instead of bundled ones -Patch1: requests-do-not-use-bundle.patch BuildRequires: python BuildRequires: python-devel BuildRequires: python-py @@ -72,7 +70,6 @@ Features: # For rpmlint warning: remove shebang from python library: sed -i '/^#!/d' ./requests/certs.py %patch0 -p1 -%patch1 -p1 rm ./requests/cacert.pem %build diff --git a/requests-do-not-use-bundle.patch b/requests-do-not-use-bundle.patch deleted file mode 100644 index fb5c5ed..0000000 --- a/requests-do-not-use-bundle.patch +++ /dev/null @@ -1,111 +0,0 @@ ---- a/requests/adapters.py -+++ b/requests/adapters.py -@@ -11,24 +11,24 @@ and maintain connections. - import socket - - from .models import Response --from .packages.urllib3.poolmanager import PoolManager, proxy_from_url --from .packages.urllib3.response import HTTPResponse --from .packages.urllib3.util import Timeout as TimeoutSauce --from .packages.urllib3.util.retry import Retry -+from urllib3.poolmanager import PoolManager, proxy_from_url -+from urllib3.response import HTTPResponse -+from urllib3.util import Timeout as TimeoutSauce -+from urllib3.util.retry import Retry - from .compat import urlparse, basestring - from .utils import (DEFAULT_CA_BUNDLE_PATH, get_encoding_from_headers, - prepend_scheme_if_needed, get_auth_from_url, urldefragauth, - select_proxy) - from .structures import CaseInsensitiveDict --from .packages.urllib3.exceptions import ClosedPoolError --from .packages.urllib3.exceptions import ConnectTimeoutError --from .packages.urllib3.exceptions import HTTPError as _HTTPError --from .packages.urllib3.exceptions import MaxRetryError --from .packages.urllib3.exceptions import ProxyError as _ProxyError --from .packages.urllib3.exceptions import ProtocolError --from .packages.urllib3.exceptions import ReadTimeoutError --from .packages.urllib3.exceptions import SSLError as _SSLError --from .packages.urllib3.exceptions import ResponseError -+from urllib3.exceptions import ClosedPoolError -+from urllib3.exceptions import ConnectTimeoutError -+from urllib3.exceptions import HTTPError as _HTTPError -+from urllib3.exceptions import MaxRetryError -+from urllib3.exceptions import ProxyError as _ProxyError -+from urllib3.exceptions import ProtocolError -+from urllib3.exceptions import ReadTimeoutError -+from urllib3.exceptions import SSLError as _SSLError -+from urllib3.exceptions import ResponseError - from .cookies import extract_cookies_to_jar - from .exceptions import (ConnectionError, ConnectTimeout, ReadTimeout, SSLError, - ProxyError, RetryError) ---- a/requests/compat.py -+++ b/requests/compat.py -@@ -4,8 +4,7 @@ - pythoncompat - """ - --from .packages import chardet -- -+import chardet - import sys - - # ------- -@@ -39,7 +38,7 @@ if is_py2: - import cookielib - from Cookie import Morsel - from StringIO import StringIO -- from .packages.urllib3.packages.ordered_dict import OrderedDict -+ from urllib3.packages.ordered_dict import OrderedDict - - builtin_str = str - bytes = str ---- a/requests/exceptions.py -+++ b/requests/exceptions.py -@@ -7,7 +7,7 @@ requests.exceptions - This module contains the set of Requests' exceptions. - - """ --from .packages.urllib3.exceptions import HTTPError as BaseHTTPError -+from urllib3.exceptions import HTTPError as BaseHTTPError - - - class RequestException(IOError): ---- a/requests/__init__.py -+++ b/requests/__init__.py -@@ -50,7 +50,7 @@ __copyright__ = 'Copyright 2015 Kenneth - - # Attempt to enable urllib3's SNI support, if possible - try: -- from .packages.urllib3.contrib import pyopenssl -+ from urllib3.contrib import pyopenssl - pyopenssl.inject_into_urllib3() - except ImportError: - pass ---- a/requests/models.py -+++ b/requests/models.py -@@ -16,10 +16,10 @@ from .structures import CaseInsensitiveD - - from .auth import HTTPBasicAuth - from .cookies import cookiejar_from_dict, get_cookie_header, _copy_cookie_jar --from .packages.urllib3.fields import RequestField --from .packages.urllib3.filepost import encode_multipart_formdata --from .packages.urllib3.util import parse_url --from .packages.urllib3.exceptions import ( -+from urllib3.fields import RequestField -+from urllib3.filepost import encode_multipart_formdata -+from urllib3.util import parse_url -+from urllib3.exceptions import ( - DecodeError, ReadTimeoutError, ProtocolError, LocationParseError) - from .exceptions import ( - HTTPError, MissingSchema, InvalidURL, ChunkedEncodingError, ---- a/requests/sessions.py -+++ b/requests/sessions.py -@@ -21,7 +21,7 @@ from .hooks import default_hooks, dispat - from .utils import to_key_val_list, default_headers, to_native_string - from .exceptions import ( - TooManyRedirects, InvalidSchema, ChunkedEncodingError, ContentDecodingError) --from .packages.urllib3._collections import RecentlyUsedContainer -+from urllib3._collections import RecentlyUsedContainer - from .structures import CaseInsensitiveDict - - from .adapters import HTTPAdapter From 6fd6cd6487273485e65b8f7b9bfc2add7d658a19df88a081f54a3ffd794c5bf0 Mon Sep 17 00:00:00 2001 From: Dirk Mueller Date: Wed, 21 Oct 2015 21:04:56 +0000 Subject: [PATCH 4/5] OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-requests?expand=0&rev=80 --- python-requests.spec | 1 - 1 file changed, 1 deletion(-) diff --git a/python-requests.spec b/python-requests.spec index 9d7b75a..ba7a22b 100644 --- a/python-requests.spec +++ b/python-requests.spec @@ -78,7 +78,6 @@ python setup.py build %install python setup.py install \ --root=%{buildroot} --prefix=%{_prefix} -rm -rf %{buildroot}%{python_sitelib}/requests/packages/ %check python setup.py test From 78a8f66a4b56cd109c6a21c05d4cee0e3652b4a9b52d0ffa33822d1f60a3d9b4 Mon Sep 17 00:00:00 2001 From: Dirk Mueller Date: Wed, 21 Oct 2015 21:09:14 +0000 Subject: [PATCH 5/5] - update to 2.8.1: - Update certificate bundle to match ``certifi`` 2015.9.6.2's weak certificate bundle. - Fix a bug in 2.8.0 where requests would raise ``ConnectTimeout`` instead of ``ConnectionError`` - When using the PreparedRequest flow, requests will now correctly respect the ``json`` parameter. Broken in 2.8.0. - When using the PreparedRequest flow, requests will now correctly handle a Unicode-string method name on Python 2. Broken in 2.8.0. OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-requests?expand=0&rev=81 --- python-requests.changes | 13 +++++++++++++ python-requests.spec | 2 +- requests-2.8.0.tar.gz | 3 --- requests-2.8.1.tar.gz | 3 +++ 4 files changed, 17 insertions(+), 4 deletions(-) delete mode 100644 requests-2.8.0.tar.gz create mode 100644 requests-2.8.1.tar.gz diff --git a/python-requests.changes b/python-requests.changes index 3e0979d..fb88a5e 100644 --- a/python-requests.changes +++ b/python-requests.changes @@ -1,3 +1,16 @@ +------------------------------------------------------------------- +Wed Oct 21 21:08:29 UTC 2015 - dmueller@suse.com + +- update to 2.8.1: + - Update certificate bundle to match ``certifi`` 2015.9.6.2's weak certificate + bundle. + - Fix a bug in 2.8.0 where requests would raise ``ConnectTimeout`` instead of + ``ConnectionError`` + - When using the PreparedRequest flow, requests will now correctly respect the + ``json`` parameter. Broken in 2.8.0. + - When using the PreparedRequest flow, requests will now correctly handle a + Unicode-string method name on Python 2. Broken in 2.8.0. + ------------------------------------------------------------------- Wed Oct 21 20:49:30 UTC 2015 - dmueller@suse.com diff --git a/python-requests.spec b/python-requests.spec index ba7a22b..fd510f8 100644 --- a/python-requests.spec +++ b/python-requests.spec @@ -17,7 +17,7 @@ Name: python-requests -Version: 2.8.0 +Version: 2.8.1 Release: 0 Summary: Awesome Python HTTP Library That's Actually Usable License: Apache-2.0 diff --git a/requests-2.8.0.tar.gz b/requests-2.8.0.tar.gz deleted file mode 100644 index 7269afa..0000000 --- a/requests-2.8.0.tar.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:b2f003589b60924909c0acde472590c5ea83906986a7a25b6f7929eb20923b7b -size 457879 diff --git a/requests-2.8.1.tar.gz b/requests-2.8.1.tar.gz new file mode 100644 index 0000000..6af30b9 --- /dev/null +++ b/requests-2.8.1.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:84fe8d5bf4dcdcc49002446c47a146d17ac10facf00d9086659064ac43b6c25b +size 480803