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
connect_over_cdp always download file to tmp folder #2105
Most of the time, I operate automatically, but often I need to manually download the results. At such times, the downloaded files end up being stored in a hard-to-find location.
the file always download to tmp folder like :
C:\Users\ADMINI~1\AppData\Local\Temp\2\playwright-artifacts-k8550A\c78a1a06-9d11-4eab-a4ed-d02323dff07e
hope some one can improve this .or is there any ways to set default download path when using cdp connection.
like pw.chromium.launch use downloads_path param to set default download place.
browser=pw.chromium.launch(downloads_path='c:/')
Activity
mxschmitt commentedon Oct 9, 2023
This path is not intended to be consumed, thats why the file names are also UUIDs. We have a Download API, with which you can get the location, save it to a different location and delete the file. See here: https://playwright.dev/python/docs/downloads
You can also subscribe to the download event:
Would that work for you?
hackerpayne commentedon Oct 9, 2023
Thanks for this code。this code works fine.
but i think add a param like downloads_path would be more convenient.
Anyway thanks very much .
fix(connectOverCDP): preserve browser-default downloads in the defaul…