# # spec file for package python-httplib2 # # Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed # upon. The license for this file, and modifications and additions to the # file, is the same license as for the pristine package itself (unless the # license for the pristine package is not an Open Source License, in which # case the license is the MIT License). An "Open Source License" is a # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. # Please submit bugfixes or comments via http://bugs.opensuse.org/ # # Tests require network connection %bcond_with tests %{?!python_module:%define python_module() python-%{**} python3-%{**}} Name: python-httplib2 Version: 0.10.3 Release: 3.2 Url: https://github.com/httplib2/httplib2 Summary: A Python HTTP client library License: MIT AND Apache-2.0 AND (MPL-1.1 OR GPL-2.0+ OR LGPL-2.1+) Group: Development/Libraries/Python Source: https://files.pythonhosted.org/packages/source/h/httplib2/httplib2-%{version}.tar.gz # PATCH-FIX-OPENSUSE: Don't ship private copy of Mozilla NSS certs, use system certs instead (bnc#761162) Patch0: httplib2-use-system-certs.patch BuildRequires: %{python_module setuptools} BuildRequires: python-rpm-macros %if %{with tests} # Test requirements (for ssl module): BuildRequires: python BuildRequires: python3 %endif Requires: ca-certificates BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildArch: noarch %python_subpackages %description A comprehensive HTTP client library that supports many features left out of other HTTP libraries. %prep %setup -q -n httplib2-%{version} %patch0 -p1 %build %python_build %install %python_install %if %{with tests} %check %if %have_python2 python2 python2/httplib2test.py %endif %if %have_python2 python3 python3/httplib2test.py %endif %endif %files %{python_files} %defattr(-,root,root) %{python_sitelib}/httplib2-%{version}-py*.egg-info %{python_sitelib}/httplib2 %changelog * Fri Feb 23 2018 snica@suse.com - update httplib2-use-system-certs.patch: handle the case when validation is disabled correctly. The 'check_hostname' context attribute has to be set first, othewise a "ValueError: Cannot set verify_mode to CERT_NONE when check_hostname is enabled." exception is raised. * Wed Jan 10 2018 dmueller@suse.com - update httplib2-use-system-certs.patch: handle the case with ssl_version being None correctly * Tue Jan 9 2018 dmueller@suse.com - update httplib2-use-system-certs.patch: Also use ssl.create_default_context in the python2 case so that the system wide certificates are loaded as trusted again. * Wed Apr 19 2017 toddrme2178@gmail.com - Source url must be https. * Wed Apr 19 2017 toddrme2178@gmail.com - Spec file cleanups * Wed Apr 12 2017 toddrme2178@gmail.com - Update to 0.10.3 * Fix certificate validation on Python<=2.7.8 without ssl.CertificateError - Update to 0.10.2 * Just a reupload of 0.10.1, which was broken for Python3 because wheel distribution doesn't play well with our 2/3 split code base. - Update to 0.10.1 * Remove VeriSign Class 3 CA from trusted certs * Add IdenTrust DST Root CA X3 * Support for specifying the SSL protocol version (Python v2) * On App Engine use urlfetch's default deadline if None is passed. * Fix TypeError on AppEngine “__init__() got an unexpected keyword argument 'ssl_version’” * Send SNI data for SSL connections on Python 2.7.9+ * Verify the server hostname if certificate validation is enabled * Add proxy_headers argument to ProxyInfo constructor * Make disable_ssl_certificate_validation work with Python 3.5. * Fix socket error handling - Remove httplib2-bnc-818100.patch, merged upstream. * Wed Oct 12 2016 rjschwei@suse.com - Project moved from code.google.com to GitHub, fix the url accordingly * Wed Apr 27 2016 jmatejek@suse.com - attempt to build multi-python * Wed Mar 2 2016 jmatejek@suse.com - update and cleanup of httplib2-use-system-certs.patch, so that the passthrough is clean for python2 and so that it does the right thing in python3 * Thu Dec 3 2015 rjschwei@suse.com - Update to version 0.9.2: * Fix incorrect ResponseNotReady exceptions, retry on transient errors. * Tue Dec 1 2015 rjschwei@suse.com - Include 0.9.1 in SLE 12 (FATE#319904, bsc#954690) * Wed May 6 2015 benoit.monin@gmx.fr - update to version 0.9.1: * fix #296: There was a problem with headers when a binary string is passed (like b'Authorization'). * fix #276: Default to doing DNS resolution through a proxy server if present. * Mon Sep 15 2014 tbechtold@suse.com - update to version 0.9 * Release 0.9. The heartbleed release. * Add an updated cacerts.txt file and fix some tests. Turns out nginx doesn't support etags on gzip'd content. * Merge pull request #259 from snarfed/master * use socket.getdefaulttimeout() on App Engine as well as off, take 2 * Merge pull request #258 from snarfed/master * use socket.getdefaulttimeout() on App Engine as well as off * Update README.md * whitespace fix * Remove redundant README * Remove unused files. * Update README.md * Merge ../httplib2.current * Update README.md * Last fixed for markdown. * Update README.md * Markdown fixes. * Moving README over to README.md * Pass method by name, not positionally. Fixes issue #252. Reviewed in https://codereview.appspot.com/7987046/. * Fix handling of BadStatusLine. Fixes issue #250. Review in https://codereview.appspot.com/7529045/. * Clean up tags * Added tag 0.8 for changeset 427a4ff7b7e4 * Wed Mar 5 2014 rschweikert@suse.com - Modify httplib2-use-system-certs.patch to not depend on a generated bundle. OpenSSL has everything built in to do the cert verification, we do not need to pass a cert bundle file * Thu Feb 13 2014 rschweikert@suse.com - Include in SLE 12 (FATE #316168) * Sat Nov 30 2013 rschweikert@suse.com - SUSE internal build service does not recognize %%0{sles_version} use a different version inidcator to depend on openssl-certs vs ca-certificates * Thu Aug 15 2013 speilicke@suse.com - Drop pre_checkin.sh * Thu May 2 2013 speilicke@suse.com - Add httplib2-bnc-818100.patch (bnc#818100): Fix for subsequent request SSL certificate validation * Fri Mar 22 2013 speilicke@suse.com - Update to version 0.8: + Improved App Engine behavior * Fri Jan 11 2013 p.drouand@gmail.com - Drop unneeded python-pyOpenSSL Requires * Fri Jan 11 2013 p.drouand@gmail.com - Initial python3 support * Fri Jan 11 2013 p.drouand@gmail.com - Update to 0.7.7 version: * More fixes for App Engine, now less likely to swallow important exceptions. * Adding proxy_info_from_* methods to Python3. Reviewed in https://codereview.appspot.com/6588078/. * Added GeoTrust cert * Make httplib2.Http() instances pickleable. Reviewed in https://codereview.appspot.com/6506074/ * The following issues have been fixed: - 229 python3 httplib2 clobbers multiple headers of same key - 230 Expose meaningful exception for App Engine URLFetch ResponseTooLargeError - 231 Expose App Engine URLFetch DeadlineExceededError for debugging purposes * Sat Oct 6 2012 os-dev@jacraig.com - Update to 0.7.6: * Fix app engine * On Python App Engine 2.7 a body can be passed in that is actually a stream. Do a full read of the contents of that stream before proceeding. - Update URL to one given in setup.py; also where the old one redirects to. * Sun Sep 9 2012 os-dev@jacraig.com - Update to 0.7.5, no changelog provided. * Mon Jul 23 2012 saschpe@suse.de - Require openssl-certs on SLE instead of ca-certificates * Tue Jul 17 2012 saschpe@suse.de - Add missing runtime requirement on python-pyOpenSSL to gain access to 'ssl' module * Mon Jul 9 2012 cfarrell@suse.com - license update: MIT and Apache-2.0 and (MPL-1.1 or GPL-2.0+ or LGPL-2.1+) __init__.py contains code derived from a Google owned Apache project. cacerts.txt is Mozilla triple-licensed. * Wed Jun 20 2012 saschpe@suse.de - Don't ship private copy of Mozilla NSS certs, use system certs instead (bnc#761162) * Tue Jun 5 2012 cstender@opensuse.org - update to version 0.7.4 * See CHANGELOG for all changes and fixes * Thu Dec 22 2011 cstender@suse.com - updated to version 0.7.2 * Mon Jul 11 2011 cstender@suse.de - updated to version 0.7.1 * See CHANGELOG for all changes and fixes * Mon Apr 19 2010 dmueller@suse.de - update to version 0.6.0: * include python 3 support/compatibility * Thu Aug 13 2009 cstender@novell.com - build as noarch * Tue Aug 4 2009 cstender@novell.com - updated to version 0.5.0 * Fixed the following bugs: [#12] - Cache-Control: only-if-cached incorrectly does request if item not in cache [#39] - Deprecation warnings in Python 2.6 [#54] - Http.request fails accesing Google account via http proxy [#56] - Block on response.read() for HEAD requests. [#57] - Timeout ignore for Python 2.6 [#58] - Fixed parsing of Cache-Control: header to make it more robust * Tue Sep 9 2008 cstender@suse.de - updated package to version 0.4.0 o added support for proxies if the Socksipy module is installed o fixed bug with some HEAD responses having content-length set to zero incorrectly o fixed most except's to catch a specific exception o added 'connection_type' parameter to Http.request() o the default for 'force_exception_to_status_code' was changed to False * Sat Oct 21 2006 dgollub@suse.de - initial version of python-httplib2 (0.2.0)