-
-
Notifications
You must be signed in to change notification settings - Fork 31.9k
[v12.x] backport #27685 #29011
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Closed
Closed
[v12.x] backport #27685 #29011
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This adds a reference anchor to circular structures when using `util.inspect`. That way it's possible to identify with what object the circular reference corresponds too. PR-URL: nodejs#27685 Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com> Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Anto Aravinth <anto.aravinth.cse@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Jeremiah Senkpiel <fishrock123@rocketmail.com>
This patch makes sure no breaking changes from the referenced semver-major PR are backported. Refs: nodejs#27685
gengjiawen
requested changes
Aug 8, 2019
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Test failed with:
=== release test-util-inspect ===
Path: parallel/test-util-inspect
--- stderr ---
assert.js:89
throw new AssertionError(obj);
^
AssertionError [ERR_ASSERTION]: Expected values to be strictly equal:
+ actual - expected
+ '{ a: [ [Circular] ], b: { inner: [Circular], obj: [Circular] } }'
- '{\n a: [ [Circular] ],\n b: { inner: [Circular], obj: [Circular] }\n}'
at Object.<anonymous> (/home/travis/build/nodejs/node/test/parallel/test-util-inspect.js:1061:10)
at Module._compile (internal/modules/cjs/loader.js:868:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:879:10)
at Module.load (internal/modules/cjs/loader.js:731:32)
at Function.Module._load (internal/modules/cjs/loader.js:644:12)
at Function.Module.runMain (internal/modules/cjs/loader.js:931:10)
at internal/main/run_main_module.js:17:11 {
generatedMessage: true,
code: 'ERR_ASSERTION',
actual: '{ a: [ [Circular] ], b: { inner: [Circular], obj: [Circular] } }',
expected: '{\n a: [ [Circular] ],\n b: { inner: [Circular], obj: [Circular] }\n}',
operator: 'strictEqual'
}
Command: out/Release/node --expose-internals /home/travis/build/nodejs/node/test/parallel/test-util-inspect.js
@nodejs/releasers PTAL It's not super important but I would like to land this backport soon. |
addaleax
approved these changes
Sep 24, 2019
Lint failure in CI explained in #29695 (comment). Two commits need to be removed from v12.x-staging, probably. |
gengjiawen
approved these changes
Sep 25, 2019
Landed on staging ced89ad |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This backports #27685 (a semver-major PR) with a compatibility patch on top.
The main code change works similar to a no-op.
@nodejs/util @nodejs/releasers PTAL
Checklist
make -j4 test
(UNIX), orvcbuild test
(Windows) passes