This commit is contained in:
tursom 2024-09-26 17:36:25 +08:00
parent 04018cdaf4
commit 6d4266e0de

View File

@ -132,7 +132,7 @@ def flush_files():
def init_session():
global session
global session, cookies
session = aiohttp.ClientSession()
session.cookie_jar.update_cookies(cookies)
@ -169,6 +169,7 @@ log_files = {}
with open("cookie.txt", "r", encoding="utf-8") as f:
cookies = http.cookies.SimpleCookie()
cookies.load(f.read().strip())
cookies["SESSDATA"]["domain"] = "bilibili.com"
session: Optional[aiohttp.ClientSession] = None