checking if a connect using ServerProxy fails

sashan mabus at operamail.com
Sat Oct 25 23:57:51 EDT 2003


Hi

How do you test if a connect fails. I'm doing this at the moment:
print 'Connect'
       try:
           self.sp = ServerProxy('http://localhost:5001')
       except Fault, f:
           print 'fail'

but it doesn't fail. I don't have anything listening on port 5001.





More information about the Python-list mailing list