code: def get_url_title(url):
      r
      parsed_url = try_parse_url(url)
      if parsed_url is None:
          return None
      try:
          r = requests.get(parsed_url.geturl(), stream=False, allow_redirects=True, timeout=5)
          tree = parse_html(r.content)
          title = tree.findtext('.//title')
          return title
      except ConnectionError:
          logging.error('Unable to connect to internet to retrieve URL {}'.format(parsed_url.geturl()))
          logging.error(format_exc())
      except (InvalidURL, InvalidSchema, InvalidHeader, MissingSchema):
          logging.warn('Unable to retrieve URL {}'.format(parsed_url.geturl()))
          logging.error(format_exc())
docs: r""" Request HTML for the page at the URL indicated and return it's <title> property
  
      >>> get_url_title('mozilla.com').strip()
      'Internet for people, not profit\n    — Mozilla'