fix(cdp): base64-encode non-UTF8 Network.getResponseBody payloads#1921
fix(cdp): base64-encode non-UTF8 Network.getResponseBody payloads#1921gilangjavier wants to merge 2 commits intolightpanda-io:mainfrom
Conversation
|
All contributors have signed the CLA ✍️ ✅ |
|
I have read the CLA Document and I hereby sign the CLA |
|
Hello @gilangjavier, I'm wondering if we could do that easier: always return a base64 encoded value, even for utf-8 responses. If we really want to keep utf-8 value non encoded, I guess we have to change And adapt the the captured response callback to save the data depending |
|
Thanks for the detailed suggestion. I updated the PR to use the simpler approach: Network.getResponseBody now always returns base64-encoded payloads with base64Encoded=true, including UTF-8 responses.\n\nI also updated the tests accordingly:\n- UTF-8 response now asserts aGVsbG8= with base64Encoded=true\n- binary response test remains covered\n\nPushed commit b5b012b to this branch. Please re-check when you have time. |
Summary
Fixes #1903.