undetected-chromedriver icon indicating copy to clipboard operation
undetected-chromedriver copied to clipboard

is there a way to load json cookies in nodriver? like in uc

Open rex1de opened this issue 10 months ago • 2 comments

is there a way to load json cookies in nodriver? like in uc

rex1de avatar Apr 21 '24 14:04 rex1de

yes, but there is a bug in the code that you need to fix in order for the cookies to work, you can see the issue: https://github.com/ultrafunkamsterdam/undetected-chromedriver/issues/1816

await browser.cookies.set_all(cookies)

is how you set the cookies

cookies = []
c = CookieParam(name='n',value='v',path='/',domain='google.com')
cookies.append(c)

cookies aren't JSON, you need to pass in the above list of CookieParam class

bluemangofunk avatar Apr 23 '24 18:04 bluemangofunk

cookies aren't JSON, you need to pass in the above list of CookieParam class

What is CookieParam? Thanks.

Metug avatar Jun 15 '24 19:06 Metug