Skip to content

fix(mcp): save string evaluation results to file as is - #44298

Open
Lazizbek Ergashev (lazerg) wants to merge 2 commits into
microsoft:mainfrom
lazerg:fix-44295
Open

Lazizbek Ergashev (lazerg) wants to merge 2 commits into
microsoft:mainfrom
lazerg:fix-44295

Conversation

@lazerg

@lazerg Lazizbek Ergashev (lazerg) commented Nov 22, 2026 •

Copy link
Copy Markdown
Contributor

When browser_evaluate gets a filename, a string result was still passed through JSON.stringify, so eval "document.body.outerHTML" --filename=page.html saved a quoted JSON string with \n escapes. String results are now written to the file as is. Output without filename, and non-string results, stay the same.

Fixes #44295

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[MCP]: browser_evaluate with filename saves a string result JSON-encoded on one line

1 participant