Merge pull request #38 from dreammis/cli

fix tencent
This commit is contained in:
Alleria
2024-07-18 18:03:54 +08:00
committed by GitHub
+3 -3
View File
@@ -258,9 +258,9 @@ class TencentVideo(object):
await page.locator('div.form-content:visible').click() # 下拉菜单
await page.locator(
f'div.form-content:visible ul.weui-desktop-dropdown__list li.weui-desktop-dropdown__list-ele:has-text("{self.category}")').first.click()
await asyncio.sleep(1)
if await page.locator('button:has-text("声明原创"):visible').count():
await page.locator('button:has-text("声明原创"):visible').click()
await page.wait_for_timeout(1000)
if await page.locator('button:has-text("声明原创"):visible').count():
await page.locator('button:has-text("声明原创"):visible').click()
async def main(self):
async with async_playwright() as playwright: