1>>> import urllib
2>>> f = { 'eventName' : 'myEvent', 'eventDescription' : 'cool event'}
3>>> urllib.urlencode(f)
4'eventName=myEvent&eventDescription=cool+event'
5
1#Python3
2import urllib
3print (urllib.parse.quote('gitlab/gith', safe=''))
4>>> gitlab%Fgith