import traceback
import threading
from Queue import Queue
-import xmlrpclib
import SocketServer
import BaseHTTPServer
import SimpleXMLRPCServer
from sfa.util.cache import Cache
from sfa.trust.certificate import Certificate
from sfa.trust.trustedroots import TrustedRoots
+from sfa.util.py23 import xmlrpc_client
# don't hard code an api class anymore here
from sfa.generic import Generic
remote_addr = (remote_ip, remote_port) = self.connection.getpeername()
self.api.remote_addr = remote_addr
response = self.api.handle(remote_addr, request, self.server.method_map)
- except Exception, fault:
+ except Exception as fault:
# This should only happen if the module is buggy
# internal error, report as HTTP server error
logger.log_exc("server.do_POST")
# can't use format_exc() as it is not available in jython yet
# (even in trunk).
type, value, tb = sys.exc_info()
- raise xmlrpclib.Fault(1,''.join(traceback.format_exception(type, value, tb)))
+ raise xmlrpc_client.Fault(1,''.join(traceback.format_exception(type, value, tb)))
# override this one from the python 2.7 code
# originally defined in class TCPServer