import re class UrlCollector: @staticmethod def collect_urls(data: str) -> list: try: return re.findall(r'(https?://[^\s]+)', data) except Exception as e: print(e) return []