fix python 2.7 incompatibilities (rhbz 619276)

epel9
David Malcolm 15 years ago
parent 3d0ce81d77
commit 021dece5be

@ -2,13 +2,17 @@
Name: koji Name: koji
Version: 1.4.0 Version: 1.4.0
Release: 3%{?dist} Release: 4%{?dist}
License: LGPLv2 and GPLv2+ License: LGPLv2 and GPLv2+
# koji.ssl libs (from plague) are GPLv2+ # koji.ssl libs (from plague) are GPLv2+
Summary: Build system tools Summary: Build system tools
Group: Applications/System Group: Applications/System
URL: http://fedorahosted.org/koji URL: http://fedorahosted.org/koji
Patch0: fedora-config.patch Patch0: fedora-config.patch
# Fix python 2.7 incompatibilities (rbhz#619276)
Patch1: python27.patch
Source: https://fedorahosted.org/koji/attachment/wiki/KojiRelease/%{name}-%{version}.tar.bz2 Source: https://fedorahosted.org/koji/attachment/wiki/KojiRelease/%{name}-%{version}.tar.bz2
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildArch: noarch BuildArch: noarch
@ -103,6 +107,7 @@ koji-web is a web UI to the Koji system.
%prep %prep
%setup -q %setup -q
%patch0 -p1 -b .orig %patch0 -p1 -b .orig
%patch1 -p5
%build %build
@ -187,6 +192,9 @@ if [ $1 = 0 ]; then
fi fi
%changelog %changelog
* Tue Aug 3 2010 David Malcolm <dmalcolm@redhat.com> - 1.4.0-4
- fix python 2.7 incompatibilities (rhbz 619276)
* Wed Jul 21 2010 David Malcolm <dmalcolm@redhat.com> - 1.4.0-3 * Wed Jul 21 2010 David Malcolm <dmalcolm@redhat.com> - 1.4.0-3
- Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild - Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild

@ -0,0 +1,24 @@
diff -urN /usr/lib/python2.7/site-packages/koji/ssl/SSLConnection.py /usr/lib/python2.7/site-packages/koji-bak/ssl/SSLConnection.py
--- /usr/lib/python2.7/site-packages/koji/ssl/SSLConnection.py 2010-07-09 04:04:26.000000000 +0200
+++ /usr/lib/python2.7/site-packages/koji-bak/ssl/SSLConnection.py 2010-08-02 19:39:00.000000000 +0200
@@ -63,7 +63,7 @@
c, a = self.__dict__["conn"].accept()
return (SSLConnection(c), a)
- def makefile(self, mode, bufsize):
+ def makefile(self, mode='r', bufsize=-1):
"""
We need to use socket._fileobject Because SSL.Connection
doesn't have a 'dup'. Not exactly sure WHY this is, but
diff -urN /usr/lib/python2.7/site-packages/koji/ssl/XMLRPCServerProxy.py /usr/lib/python2.7/site-packages/koji-bak/ssl/XMLRPCServerProxy.py
--- /usr/lib/python2.7/site-packages/koji/ssl/XMLRPCServerProxy.py 2010-07-09 04:04:26.000000000 +0200
+++ /usr/lib/python2.7/site-packages/koji-bak/ssl/XMLRPCServerProxy.py 2010-08-02 19:35:04.000000000 +0200
@@ -41,7 +41,7 @@
# Yay for Python 2.2
pass
_host, _port = urllib.splitport(host)
- self._https = SSLCommon.PlgHTTPS(_host, (_port and int(_port) or 443), ssl_context=self.ssl_ctx, timeout=self._timeout)
+ self._https = SSLCommon.PlgHTTPSConnection(_host, (_port and int(_port) or 443), ssl_context=self.ssl_ctx, timeout=self._timeout)
return self._https
def close(self):
Loading…
Cancel
Save