From e8208b06f11176638ba9c85bb9c21987b5b5ada1 Mon Sep 17 00:00:00 2001 From: work Date: Fri, 10 Apr 2026 15:15:39 +0800 Subject: [PATCH] =?UTF-8?q?=E5=88=A0=E9=99=A4=E5=85=A8=E9=83=A8=E4=BB=A3?= =?UTF-8?q?=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- spider/task.py | 40 ++++++++++++++++++++-------------------- 1 file changed, 20 insertions(+), 20 deletions(-) diff --git a/spider/task.py b/spider/task.py index 26d3b9b..3492037 100644 --- a/spider/task.py +++ b/spider/task.py @@ -330,11 +330,11 @@ def playwright_like(cookies, target_url): browser = playwright.chromium.launch( headless=False, args=['--start-maximized'], executable_path=path, - proxy={ - "server": "http://pr.oxylabs.io:7777", # 必填 - "username": f"customer-{username}-cc-{country}", - "password": password - } + # proxy={ + # "server": "http://pr.oxylabs.io:7777", # 必填 + # "username": f"customer-{username}-cc-{country}", + # "password": password + # } ) context = browser.new_context(no_viewport=True) @@ -610,11 +610,11 @@ def playwright_comment(cookies, target_url, content, image_key=None): browser = playwright.chromium.launch( headless=False, args=['--start-maximized'], executable_path=path, - proxy={ - "server": "http://pr.oxylabs.io:7777", # 必填 - "username": f"customer-{username}-cc-{country}", - "password": password - } + # proxy={ + # "server": "http://pr.oxylabs.io:7777", # 必填 + # "username": f"customer-{username}-cc-{country}", + # "password": password + # } ) context = browser.new_context(no_viewport=True) @@ -691,11 +691,11 @@ def playwright_get_user_profile(cookies, username=None): browser = playwright.chromium.launch( headless=const.HEADLESS, args=['--start-maximized'], executable_path=path, - proxy={ - "server": "http://pr.oxylabs.io:7777", # 必填 - "username": f"customer-{username}-cc-{country}", - "password": password - } + # proxy={ + # "server": "http://pr.oxylabs.io:7777", # 必填 + # "username": f"customer-{username}-cc-{country}", + # "password": password + # } ) context = browser.new_context(no_viewport=True) context.add_cookies(parse_cookies(cookies)) @@ -1101,11 +1101,11 @@ def playwright_m_login(username, password, code_2fa=None): browser = playwright.chromium.launch( headless=const.HEADLESS, args=['--start-maximized'], executable_path=path, - proxy={ - "server": "http://pr.oxylabs.io:7777", # 必填 - "username": f"customer-{username}-cc-{country}", - "password": password - } + # proxy={ + # "server": "http://pr.oxylabs.io:7777", # 必填 + # "username": f"customer-{username}-cc-{country}", + # "password": password + # } ) # random_user_agent = UserAgent().getBrowser(["Chrome Mobile iOS"]).get("useragent") random_user_agent = "Mozilla/5.0 (Linux; Android 12; Pixel 6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/101.0.4951.41 Mobile Safari/537.36"