# 等待下载按钮可见download_button = page.locator("[data-test-id='download-artifact']")download_button.wait_for(state="visible", timeout=200 * 1000)# 点击下载按钮with page.expect_download() as download_info:download_button.click()download = download_info.value# 等待下载完成path = download.save_as(google_services_json_path)print(f'File downloaded to {path}')