deal with urllib.error.HTTPError