def __get_url(url):
log.info("<STR_LIT>", url)<EOL>result = {SUCCESS: False, MESSAGE: None}<EOL>try:<EOL><INDENT>r = requests.get(url)<EOL>result[STATUS_CODE] = r.status_code<EOL>result[HEADERS] = r.headers<EOL>result[CONTENT] = r.text<EOL>if (<NUM_LIT:200> == r.status_code):<EOL><INDENT>result[SUCCESS] = True<EOL><DEDENT>else:<EOL><INDENT>result[MESSAGE] = "<STR_LIT>" % (r.status_code)<EOL><DEDENT>return result<EOL><DEDENT>except requests.RequestException as ose:<EOL><INDENT>result[MESSAGE] = '<STR_LIT>' % ose<EOL>log.error(result[MESSAGE])<EOL><DEDENT>return result<EOL>
Load data from url and return result.