import urllib
from urllib import request
a = urllib.request.Request(url)
b = urllib.request.urlopen(a)