[issue39875] urllib.request.urlopen sends POST data as query string

henrik242 report at bugs.python.org
Fri Mar 6 09:25:57 EST 2020


henrik242 <henrik at synth.no> added the comment:

The following gives the same failing result too :(

>>> import urllib.request
>>> data = '<add><doc><field name="key">KEY__9927.1</field><field name="value">{"result":0,"jobId":"9459695","jobNumber":"9927.1"}</field></doc></add>'
>>> url = 'http://solr.example.no:12699/solr/my_coll/update?commit=true'
>>> res = urllib.request.urlopen(url, data.encode('utf-8'))

I guess I'll have to whip out Wireshark and see what's going on.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue39875>
_______________________________________


More information about the Python-bugs-list mailing list