def main(): # Bridge the gap between sync and async future = asyncio.Task(crawl_async(argv[1], int(argv[2]))) loop = asyncio.get_event_loop() loop.run_until_complete(future) loop.close() result = future.result() print_crawl(result)
def main(): result = crawl_parallel(argv[1], int(argv[2])) print_crawl(result)