Is HTTPSConnection thread-safe?
Joe Wong
joewong at mango.cc
Fri Aug 20 02:40:27 EDT 2004
Hi,
I have a small program using HTTPSConnection to issue a POST on the server. When multiple threads of the same program is running, I got the error:
Exception in thread Thread-3:
Traceback (most recent call last):
File "C:\PYTHON23\lib\threading.py", line 436, in __bootstrap
self.run()
File "C:\PYTHON23\lib\threading.py", line 416, in run
self.__target(*self.__args, **self.__kwargs)
File "mcstest.py", line 27, in thread_func
conn.request("POST", CGI_PATH, params, headers)
File "c:\python23\lib\httplib.py", line 718, in request
self._send_request(method, url, body, headers)
File "c:\python23\lib\httplib.py", line 739, in _send_request
self.endheaders()
File "c:\python23\lib\httplib.py", line 712, in endheaders
self._send_output()
File "c:\python23\lib\httplib.py", line 597, in _send_output
self.send(msg)
File "c:\python23\lib\httplib.py", line 564, in send
self.connect()
File "c:\python23\lib\httplib.py", line 985, in connect
ssl = socket.ssl(sock, self.key_file, self.cert_file)
File "C:\Python23\lib\socket.py", line 73, in ssl
return _realssl(sock, keyfile, certfile)
sslerror: SSL_CTX_new error
in random order. Is there any fix / patches for this?
Regards,
- Joe
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-list/attachments/20040820/2fcbae9b/attachment.html>
More information about the Python-list
mailing list