microsoft / ApplicationInsights-node.js

Microsoft Application Insights SDK for Node.js
MIT License
320 stars 138 forks source link

[Beta] Stringify objects when building a `LogRecord` #1206

Closed mderriey closed 9 months ago

mderriey commented 9 months ago

Related to #1169

After being invited by @JacksonWeber to open a PR in this comment, here it is.

The one change from the code snippet I posted in that issue is we're using Util.getInstance().stringify instead of JSON.stringify as I saw it's used a few lined below that code block.

mderriey commented 9 months ago

I couldn't npm install as I don't have Python installed, which is why I opened this as a draft for now.

Could you please approve the workflow that would run tests to make sure it's all green before I mark as ready to review?

Edit: I got it working on WSL and all tests passed locally, but a PR workflow would be nice 😉

JacksonWeber commented 9 months ago

@mderriey It looks like the workflow ran ok! And the PR looks good. Thank you for your contribution and approving!