title: python unhashable type - posting xml data
body: <p>First, I'm not a python programmer. I'm an old C dog that's learned new Java and PHP tricks, but python looks like a pretty cool language. </p>
  
  <p>I'm getting an error that I can't quite follow. The error follows the code below.</p>
  
  <pre><code>import httplib, urllib
  url = "pdb-services-beta.nipr.com"
  xml = '&lt;?xml version="1.0"?&gt;&lt;!DOCTYPE SCB_Request SYSTEM "http://www.nipr.com/html/SCB_XML_Request.dtd"&gt;&lt;SCB_Request Request_Type="Create_Report"&gt;&lt;SCB_Login_Data CustomerID="someuser" Passwd="somepass" /&gt;&lt;SCB_Create_Report_Request Title=""&gt;&lt;Producer_List&gt;&lt;NIPR_Num_List_XML&gt;&lt;NIPR_Num NIPR_Num="8980608" /&gt;&lt;NIPR_Num NIPR_Num="7597855" /&gt;&lt;NIPR_Num NIPR_Num="10166016" /&gt;&lt;/NIPR_Num_List_XML&gt;&lt;/Producer_List&gt;&lt;/SCB_Create_Report_Request&gt;&lt;/SCB_Request&gt;'
  
  params = {}
  params['xmldata'] = xml
  
  headers = {}
  headers['Content-type'] = 'text/xml'
  headers['Accept'] = '*/*'
  headers['Content-Length'] = "%d" % len(xml)
  
  connection = httplib.HTTPSConnection(url)
  connection.set_debuglevel(1)
  connection.request("POST", "/pdb-xml-reports/scb_xmlclient.cgi", params, headers)
  
  response = connection.getresponse()
  print response.status, response.reason
  data = response.read()
  print data
  connection.close
  </code></pre>
  
  <p>Here's the error:</p>
  
  <pre>
  Traceback (most recent call last):   
   File "C:\Python27\tutorial.py", line 14, in  connection.request("POST", "/pdb-xml-reports/scb_xmlclient.cgi", params, headers)   
   File "C:\Python27\lib\httplib.py", line 958, in request self._send_request(method, url, body, headers)   
   File "C:\Python27\lib\httplib.py", line 992, in _send_request self.endheaders(body)
   File "C:\Python27\lib\httplib.py", line 954, in endheaders self._send_output(message_body)
   File "C:\Python27\lib\httplib.py", line 818, in _send_output self.send(message_body)
   File "C:\Python27\lib\httplib.py", line 790, in send self.sock.sendall(data)
   File "C:\Python27\lib\ssl.py", line 229, in sendall v = self.send(data[count:]) 
  TypeError: unhashable type
  </pre>
  
  <p>My log file says that the xmldata parameter is empty. </p>
  
  <p>Any ideas?</p>