Fixing a bug with reading response bytes in playwright/camoufox when network_idle is used
PlayWright doesn't provide a way to get the response in bytes after all wait ends like `page.content()` so that's more efficient to do anyway
This commit is contained in:
@@ -114,7 +114,7 @@ class CamoufoxEngine:
|
||||
response = Response(
|
||||
url=res.url,
|
||||
text=page.content(),
|
||||
body=res.body(),
|
||||
body=page.content().encode('utf-8'),
|
||||
status=res.status,
|
||||
reason=res.status_text,
|
||||
encoding=encoding,
|
||||
|
||||
@@ -224,7 +224,7 @@ class PlaywrightEngine:
|
||||
response = Response(
|
||||
url=res.url,
|
||||
text=page.content(),
|
||||
body=res.body(),
|
||||
body=page.content().encode('utf-8'),
|
||||
status=res.status,
|
||||
reason=res.status_text,
|
||||
encoding=encoding,
|
||||
|
||||
Reference in New Issue
Block a user