forked from pool/python-pycurl
Accepting request 571200 from devel:languages:python
OBS-URL: https://build.opensuse.org/request/show/571200 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/python-pycurl?expand=0&rev=19
This commit is contained in:
63
pycurl-libssh.patch
Normal file
63
pycurl-libssh.patch
Normal file
@@ -0,0 +1,63 @@
|
||||
Index: pycurl-7.43.0.1/tests/ssh_key_cb_test.py
|
||||
===================================================================
|
||||
--- pycurl-7.43.0.1.orig/tests/ssh_key_cb_test.py 2017-12-03 20:03:17.000000000 +0100
|
||||
+++ pycurl-7.43.0.1/tests/ssh_key_cb_test.py 2018-01-30 16:56:42.499858079 +0100
|
||||
@@ -30,8 +30,11 @@ class SshKeyCbTest(unittest.TestCase):
|
||||
def keyfunction(known_key, found_key, match):
|
||||
return pycurl.KHSTAT_FINE
|
||||
|
||||
- self.curl.setopt(pycurl.SSH_KNOWNHOSTS, '.known_hosts')
|
||||
- self.curl.setopt(pycurl.SSH_KEYFUNCTION, keyfunction)
|
||||
+ try:
|
||||
+ self.curl.setopt(pycurl.SSH_KNOWNHOSTS, '.known_hosts')
|
||||
+ self.curl.setopt(pycurl.SSH_KEYFUNCTION, keyfunction)
|
||||
+ except pycurl.error as e:
|
||||
+ self.assertEqual(pycurl.E_UNKNOWN_OPTION, e.args[0])
|
||||
|
||||
try:
|
||||
self.curl.perform()
|
||||
@@ -44,8 +47,11 @@ class SshKeyCbTest(unittest.TestCase):
|
||||
def keyfunction(known_key, found_key, match):
|
||||
return pycurl.KHSTAT_REJECT
|
||||
|
||||
- self.curl.setopt(pycurl.SSH_KNOWNHOSTS, '.known_hosts')
|
||||
- self.curl.setopt(pycurl.SSH_KEYFUNCTION, keyfunction)
|
||||
+ try:
|
||||
+ self.curl.setopt(pycurl.SSH_KNOWNHOSTS, '.known_hosts')
|
||||
+ self.curl.setopt(pycurl.SSH_KEYFUNCTION, keyfunction)
|
||||
+ except pycurl.error as e:
|
||||
+ self.assertEqual(pycurl.E_UNKNOWN_OPTION, e.args[0])
|
||||
|
||||
try:
|
||||
self.curl.perform()
|
||||
@@ -58,8 +64,11 @@ class SshKeyCbTest(unittest.TestCase):
|
||||
def keyfunction(known_key, found_key, match):
|
||||
return 'bogus'
|
||||
|
||||
- self.curl.setopt(pycurl.SSH_KNOWNHOSTS, '.known_hosts')
|
||||
- self.curl.setopt(pycurl.SSH_KEYFUNCTION, keyfunction)
|
||||
+ try:
|
||||
+ self.curl.setopt(pycurl.SSH_KNOWNHOSTS, '.known_hosts')
|
||||
+ self.curl.setopt(pycurl.SSH_KEYFUNCTION, keyfunction)
|
||||
+ except pycurl.error as e:
|
||||
+ self.assertEqual(pycurl.E_UNKNOWN_OPTION, e.args[0])
|
||||
|
||||
try:
|
||||
self.curl.perform()
|
||||
@@ -77,8 +86,14 @@ class SshKeyCbUnsetTest(unittest.TestCas
|
||||
|
||||
@util.min_libcurl(7, 19, 6)
|
||||
def test_keyfunction_none(self):
|
||||
- self.curl.setopt(pycurl.SSH_KEYFUNCTION, None)
|
||||
+ try:
|
||||
+ self.curl.setopt(pycurl.SSH_KEYFUNCTION, None)
|
||||
+ except pycurl.error as e:
|
||||
+ self.assertEqual(pycurl.E_UNKNOWN_OPTION, e.args[0])
|
||||
|
||||
@util.min_libcurl(7, 19, 6)
|
||||
def test_keyfunction_unset(self):
|
||||
- self.curl.unsetopt(pycurl.SSH_KEYFUNCTION)
|
||||
+ try:
|
||||
+ self.curl.unsetopt(pycurl.SSH_KEYFUNCTION)
|
||||
+ except pycurl.error as e:
|
||||
+ self.assertEqual(pycurl.E_UNKNOWN_OPTION, e.args[0])
|
@@ -1,3 +1,11 @@
|
||||
-------------------------------------------------------------------
|
||||
Tue Jan 30 16:01:27 UTC 2018 - vcizek@suse.com
|
||||
|
||||
- Since version 7.58.0, curl may be compiled with libssh instead of
|
||||
libssh2 which differ in supported functionality (bsc#1078329)
|
||||
* add pycurl-libssh.patch
|
||||
- update license
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Fri Dec 8 18:06:28 UTC 2017 - arun@gmx.de
|
||||
|
||||
|
@@ -1,7 +1,7 @@
|
||||
#
|
||||
# spec file for package python-pycurl
|
||||
#
|
||||
# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
|
||||
# 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
|
||||
@@ -22,12 +22,14 @@ Name: python-pycurl
|
||||
Version: 7.43.0.1
|
||||
Release: 0
|
||||
Summary: PycURL -- cURL library module
|
||||
License: LGPL-2.1+ and MIT
|
||||
License: LGPL-2.1+ AND MIT
|
||||
Group: Development/Languages/Python
|
||||
Url: http://pycurl.sourceforge.net/
|
||||
Source: https://files.pythonhosted.org/packages/source/p/pycurl/pycurl-%{version}.tar.gz
|
||||
# PATCH-FIX-OPENSUSE increase_test_timeout.diff -- Increase the timeout in a test so it doesn't fail when obs is overloaded
|
||||
Patch0: increase_test_timeout.diff
|
||||
# PATCH-FIX-UPSTREAM handle difference between libssh and libssh2
|
||||
Patch1: pycurl-libssh.patch
|
||||
BuildRequires: %{python_module bottle}
|
||||
BuildRequires: %{python_module devel}
|
||||
BuildRequires: %{python_module flaky}
|
||||
@@ -61,6 +63,7 @@ This package contains documentation and examples.
|
||||
%prep
|
||||
%setup -q -n pycurl-%{version}
|
||||
%patch0 -p1
|
||||
%patch1 -p1
|
||||
|
||||
%build
|
||||
export CFLAGS="%{optflags}"
|
||||
|
Reference in New Issue
Block a user