def parse_host(self): proto, rest = urllib.splittype(self.get_host()) host, rest = urllib.splithost(rest) host, port = urllib.splitport(host) return host