You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Even if it is a flake, I am quite puzzled how util.inspect(testTimestamp) managed to format it as Thu Apr 13 2017 13:17:08 GMT+0000 (UTC). util.inspect should use the ISO form.
Do you have objections to pre-emptively adding a debug print to catch some more info if it flakes again?
It is definitely a flake in that case. It seems that we are retrieving the log entries from previous system-test run. That is, a node 4 run is fetching the entries from a preceding node 6/7 run.
The delay is already set to 90 seconds, should we increase it?
I suppose so :( Does any source code need to be touched to make sure the behavior of the new util.inspect() is passed to the API, even in Node v4 envs, or no big deal?
The contract we have is that we will format metadata attached to winston log entries using util.inspect. Whatever behaviour util.inspect has with a given node version is the behaviour we should follow. So, no, I don't think source code needs to be touched.
I can see your point, but I worry that will set them up for the same confusion we just had when they inevitably upgrade Node or simply try to write an app that handles consistently-formed data from a log that has writers from multiple environments. Assuming Logging's job is to take input, stringify it, and send it to the API, it seems like a bug that we would do that differently depending on what version of Node is running.
The "contract" part is a bit more weighted now that we have gone 1.0 with Logging. If you don't think we should guarantee a consistent API message across multiple Node versions (which we could call a bug fix, as opposed to a breaking change), then go ahead and bump the delay of the system test and we'll see if we get better results.
A better solution would be to make util.inspect optional (default: false) and let common-grpc do the serialization. This would be a semver major change, but we are still in the 0.x, so still doable.
That sounds good to me, and thank you for digging into this.
changed the title [-]logging-winston failed system test ("log should properly write log entries")[/-][+]logging-winston: use custom serialization[/+]on Apr 21, 2017
Activity
ofrobots commentedon Apr 20, 2017
Curious... seems to be passing for me.
stephenplusplus commentedon Apr 20, 2017
Alright, you can close this if you can't find anything flaky about the test, then if the problem shows up again on CI, we'll just re-open.
ofrobots commentedon Apr 20, 2017
Let me stare at the code for a bit.
ofrobots commentedon Apr 20, 2017
I am really puzzled by this. The test is:
Even if it is a flake, I am quite puzzled how
util.inspect(testTimestamp)managed to format it asThu Apr 13 2017 13:17:08 GMT+0000 (UTC).util.inspectshould use the ISO form.Do you have objections to pre-emptively adding a debug print to catch some more info if it flakes again?
stephenplusplus commentedon Apr 20, 2017
Looks like that's a new thing:
ofrobots commentedon Apr 20, 2017
Okay, it makes a lot more sense now.
It is definitely a flake in that case. It seems that we are retrieving the log entries from previous system-test run. That is, a node 4 run is fetching the entries from a preceding node 6/7 run.
The delay is already set to 90 seconds, should we increase it?
stephenplusplus commentedon Apr 20, 2017
I suppose so :( Does any source code need to be touched to make sure the behavior of the new util.inspect() is passed to the API, even in Node v4 envs, or no big deal?
ofrobots commentedon Apr 20, 2017
The contract we have is that we will format
metadataattached to winston log entries usingutil.inspect. Whatever behaviourutil.inspecthas with a given node version is the behaviour we should follow. So, no, I don't think source code needs to be touched.stephenplusplus commentedon Apr 20, 2017
I can see your point, but I worry that will set them up for the same confusion we just had when they inevitably upgrade Node or simply try to write an app that handles consistently-formed data from a log that has writers from multiple environments. Assuming Logging's job is to take input, stringify it, and send it to the API, it seems like a bug that we would do that differently depending on what version of Node is running.
The "contract" part is a bit more weighted now that we have gone 1.0 with Logging. If you don't think we should guarantee a consistent API message across multiple Node versions (which we could call a bug fix, as opposed to a breaking change), then go ahead and bump the delay of the system test and we'll see if we get better results.
ofrobots commentedon Apr 20, 2017
logging-winstonshould followwinstonconventions. Winston also formats data usingutil.inspect: https://github.com/winstonjs/winston#logging-with-metadata.4 remaining items
ofrobots commentedon Apr 21, 2017
BTW, here's the change in Node that changed the behaviour of
util.inspect: nodejs/node#4314stephenplusplus commentedon Apr 21, 2017
That sounds good to me, and thank you for digging into this.
[-]logging-winston failed system test ("log should properly write log entries")[/-][+]logging-winston: use custom serialization[/+]ofrobots commentedon Apr 21, 2017
Thank you for being a good advocate for consistent behaviour for users :).
stephenplusplus commentedon Apr 21, 2017
🎖 Teamwork! 🏆
logging-winston: metadata serialization
logging-winston: metadata serialization
logging-winston: metadata serialization
logging-winston: metadata serialization
logging-winston: metadata serialization
feat: Enable tracing via OpenTelemetry. (#2218)