replace urllib2 with requests