when the url is not ok, urllib2 will raise a ValueError