(url: str)
| 141 | |
| 142 | |
| 143 | def parse_hostname(url: str) -> str: |
| 144 | hostname = parse.urlsplit(url).hostname |
| 145 | if hostname is not None: |
| 146 | return hostname |
| 147 | |
| 148 | raise Exception('unable to parse hostname from URL') |
| 149 | |
| 150 | |
| 151 | def parse_links(html: str) -> list[str]: |