Use requests library to resolve SSL errors. (#1450)

This commit is contained in:
Robin Huang
2025-01-14 14:20:45 -08:00
committed by GitHub
parent 5e5867528d
commit f63205f86c
2 changed files with 7 additions and 3 deletions

View File

@@ -16,7 +16,11 @@ if aria2 is not None:
aria2 = aria2p.API(aria2p.Client(host=host, port=port, secret=secret))
def basic_download_url(url, dest_folder, filename):
def basic_download_url(url, dest_folder: str, filename: str):
'''
Download file from url to dest_folder with filename
using requests library.
'''
import requests
# Ensure the destination folder exists
@@ -111,4 +115,4 @@ def download_url_with_agent(url, save_path):
return False
print("Installation was successful.")
return True
return True