kartagis / pysimplesoap

Automatically exported from code.google.com/p/pysimplesoap
0 stars 0 forks source link

Make compatible with older Python (2.4) #14

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
To run with older Python, just apply the following trivial patch:

diff -d -u -r a/pysimplesoap/simplexml.py b/pysimplesoap/simplexml.py
--- a/pysimplesoap/simplexml.py 2010-10-28 02:51:19.000000000 +0200
+++ b/pysimplesoap/simplexml.py 2010-10-29 06:33:58.000000000 +0200
@@ -34,7 +34,7 @@
 bool_u = lambda s: {'0':False, 'false': False, '1': True, 'true': True}[s]

 # aliases:
-class Alias():
+class Alias:
     def __init__(self, py_type, xml_type):
         self.py_type, self.xml_type = py_type, xml_type
     def __call__(self, value):
diff -d -u -r a/pysimplesoap/client.py b/pysimplesoap/client.py
--- a/pysimplesoap/client.py    2010-10-28 02:51:19.000000000 +0200
+++ b/pysimplesoap/client.py    2010-10-29 06:34:32.000000000 +0200
@@ -23,7 +23,7 @@
     Http = httplib2.Http
 except ImportError:
     import urllib2
-    class Http(): # wrapper to use when httplib2 not available
+    class Http: # wrapper to use when httplib2 not available
         def request(self, url, method, body, headers):
             f = urllib2.urlopen(urllib2.Request(url, body, headers))
             return f.info(), f.read()

Original issue reported on code.google.com by holoma...@gmail.com on 28 Oct 2010 at 3:32

GoogleCodeExporter commented 8 years ago
#12

Original comment by reingart@gmail.com on 23 Nov 2010 at 11:35