It can be reproduced by commenting/uncommenting the append in the following code:
#!/usr/bin/python
# -*- coding: utf-8 -*-
import urllib
import urllib2
url = 'https://www.test.com/test.php'
params = { 'name': 'Luke', 'location': 'Tatooine' }
pList = []
for paramKey, paramValue in params.items():
pList.append(urllib.quote_plus(unicode('%s=%s' % (paramKey, paramValue))))
#pList.append('%s=%s' % (paramKey, urllib.quote_plus(unicode(paramValue))))
post_params = '&'.join(pList)
req = urllib2.Request(url, data=post_params)
f = urllib2.urlopen(req)
print f.read()