You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Feature] Allow downloads with default context when connectOverCDP is used #12543
When I used connect_over_CDP to generate a browser object, I used the browser's original context, but this context could not be used to pass a value to the accept_downloads parameter, so the file could not be downloaded
When I used connect_over_CDP to generate a browser object, I used the browser's original context, but this context could not be used to pass a value to the accept_downloads parameter, so the file could not be downloaded
------------------ 原始邮件 ------------------
发件人: "microsoft/playwright" ***@***.***>;
发送时间: 2022年3月7日(星期一) 晚上6:58
***@***.***>;
***@***.******@***.***>;
主题: Re: [microsoft/playwright] [Question]使用connect_over_cdp创建的browser的默认context如何设置accept_downloads属性 (Issue #12543)
browser = playwright.chromium.connect_over_cdp( endpoint_url=f"http://localhost:9002/", ) context = browser.new_context(accept_downloads=True) page = context.new_context()
does this work for you?
Please formulate your issue in english, otherwise we can't support you.
—
Reply to this email directly, view it on GitHub, or unsubscribe.
Triage notifications on the go with GitHub Mobile for iOS or Android.
You are receiving this because you authored the thread.Message ID: ***@***.***>
Which version are you using? Playwright by default now accepts downloads, so it should just work fine when you use the default context.
I have used the latest version 1.19, but it still does not work. Python version 3.8.5, win10, the code is as follows:
changed the title [-][Question]使用connect_over_cdp创建的browser的默认context如何设置accept_downloads属性[/-][+][Feature] Allow downloads with default context when connectOverCDP is used[/+]on Mar 12, 2022
+1 for this. I have a similar scenario where I have to do performance test by uploading/downloading of files by attaching Playwright to an existing browser instance to replicate user behavior. Currently I am getting error asking to make accept_downloads as True for download to work.
But there is no such param in connect_over_cdp
Activity
mxschmitt commentedon Mar 7, 2022
does this work for you?
Please formulate your issue in english, otherwise we can't support you.
lvyaoyu commentedon Mar 7, 2022
When I used connect_over_CDP to generate a browser object, I used the browser's original context, but this context could not be used to pass a value to the accept_downloads parameter, so the file could not be downloaded
lvyaoyu commentedon Mar 7, 2022
mxschmitt commentedon Mar 7, 2022
Which version are you using? Playwright by default now accepts downloads, so it should just work fine when you use the default context.
lvyaoyu commentedon Mar 8, 2022
[-][Question]使用connect_over_cdp创建的browser的默认context如何设置accept_downloads属性[/-][+][Feature] Allow downloads with default context when connectOverCDP is used[/+]rai-gaurav commentedon Mar 18, 2022
+1 for this. I have a similar scenario where I have to do performance test by uploading/downloading of files by attaching Playwright to an existing browser instance to replicate user behavior. Currently I am getting error asking to make
accept_downloadsas True for download to work.But there is no such param in
connect_over_cdpfix(connectOverCDP): preserve browser-default downloads in the defaul…