URL = "MY HTTP REQUEST URL"
XML = "<port>0</port>"
parameter = urllib.urlencode({'XML': XML})
response = urllib.urlopen(URL, parameter)
print response.read()
IOError: ('http protocol error', 0, 'got a bad status line', None)
I am trying to send XML to a server and get back XML. Is there any way to fix / ignore this exception?
I know that the status line is empty which is raising this error.