From 85d9fba1a5190a8449b09a8884940765990382cf Mon Sep 17 00:00:00 2001 From: Ralph Bean Date: Wed, 5 Nov 2014 10:30:35 -0500 Subject: [PATCH] Latest upstream, 2.4.3 for #1136283 --- ...-requests-remove-nested-bundling-dep.patch | 16 ++++---- python-requests-system-cert-bundle.patch | 39 ++++++++++--------- python-requests.spec | 7 +++- 3 files changed, 32 insertions(+), 30 deletions(-) diff --git a/python-requests-remove-nested-bundling-dep.patch b/python-requests-remove-nested-bundling-dep.patch index eb536bd..d915a4e 100644 --- a/python-requests-remove-nested-bundling-dep.patch +++ b/python-requests-remove-nested-bundling-dep.patch @@ -1,31 +1,29 @@ -From e74bf477e53f9089e6d763d676333c9d84ab71e0 Mon Sep 17 00:00:00 2001 +From 8c2259d4ab03ef982738aaf863068a1015cadf3d Mon Sep 17 00:00:00 2001 From: Ralph Bean -Date: Wed, 5 Nov 2014 09:38:42 -0500 -Subject: [PATCH] Remove nested budnling dep. +Date: Wed, 5 Nov 2014 10:23:44 -0500 +Subject: [PATCH] Remove nested bundling dep. --- requests/compat.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/requests/compat.py b/requests/compat.py -index bdf10d6..29cce93 100644 +index be5a1ed..70ea4e8 100644 --- a/requests/compat.py +++ b/requests/compat.py -@@ -89,9 +89,13 @@ if is_py2: +@@ -91,7 +91,11 @@ if is_py2: import cookielib from Cookie import Morsel from StringIO import StringIO - from .packages.urllib3.packages.ordered_dict import OrderedDict - from httplib import IncompleteRead - ++ + try: + from collections import OrderedDict # py2.7 + except: + from ordereddict import OrderedDict # py2.6 and lower (el6, etc.) -+ + builtin_str = str bytes = str - str = unicode -- 1.9.3 diff --git a/python-requests-system-cert-bundle.patch b/python-requests-system-cert-bundle.patch index 8e467bd..e76b741 100644 --- a/python-requests-system-cert-bundle.patch +++ b/python-requests-system-cert-bundle.patch @@ -1,37 +1,38 @@ -From ad98b45e959dc7325c294c26d94e68901700c407 Mon Sep 17 00:00:00 2001 +From a49b39fbfe01791880c6e7179f6efdad03e8ce58 Mon Sep 17 00:00:00 2001 From: Ralph Bean -Date: Mon, 1 Jul 2013 14:50:34 -0400 -Subject: [PATCH 1/3] system cert bundle +Date: Wed, 5 Nov 2014 10:15:17 -0500 +Subject: [PATCH] system cert bundle --- - requests/certs.py | 10 +++++----- - 1 file changed, 5 insertions(+), 5 deletions(-) + requests/certs.py | 9 +++++---- + 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/requests/certs.py b/requests/certs.py -index bc00826..9b78e3b 100644 +index 07e6475..2c7ca96 100644 --- a/requests/certs.py +++ b/requests/certs.py -@@ -10,15 +10,15 @@ This module returns the preferred default CA certificate bundle. +@@ -10,16 +10,17 @@ This module returns the preferred default CA certificate bundle. 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. --""" - --import os.path ++ +We return "/etc/pki/tls/certs/ca-bundle.crt" provided by the ca-certificates +package. -+""" + """ +-import os.path - - def where(): -- """Return the preferred certificate bundle.""" -- # vendored bundle inside Requests -- return os.path.join(os.path.dirname(__file__), 'cacert.pem') -+ """ Don't use the certs bundled with requests, use ca-certificates. """ -+ return "/etc/pki/tls/certs/ca-bundle.crt" + try: + from certifi import where + except ImportError: + def where(): +- """Return the preferred certificate bundle.""" +- # vendored bundle inside Requests +- return os.path.join(os.path.dirname(__file__), 'cacert.pem') ++ """ Don't use the certs bundled with requests, use ca-certificates. """ ++ return "/etc/pki/tls/certs/ca-bundle.crt" if __name__ == '__main__': print(where()) -- -1.8.3.1 +1.9.3 diff --git a/python-requests.spec b/python-requests.spec index 43b99a5..e374e86 100644 --- a/python-requests.spec +++ b/python-requests.spec @@ -5,8 +5,8 @@ %endif Name: python-requests -Version: 2.3.0 -Release: 4%{?dist} +Version: 2.4.3 +Release: 1%{?dist} Summary: HTTP library, written in Python, for human beings License: ASL 2.0 @@ -130,6 +130,9 @@ ln -s ../../urllib3 %{buildroot}/%{python_sitelib}/requests/packages/urllib3 %endif %changelog +* Wed Nov 05 2014 Ralph Bean - 2.4.3-1 +- Latest upstream, 2.4.3 for #1136283 + * Wed Nov 05 2014 Ralph Bean - 2.3.0-4 - Re-do unbundling by symlinking system libs into the requests/packages/ dir.