Skip to content

util: prevent proxy traps being triggered by .inspect()

This prevents any proxy traps from being called while inspecting proxy objects. That guarantees a side-effect free way of inspecting proxies.

That aligns the behavior to the one in chrome. Firefox always inspects the proxy as if showProxy would be set to true and thus has no side-effects either.

Refs: https://github.com/nodejs/node/issues/25212 Refs: https://github.com/nodejs/node/issues/24765 Fixes: https://github.com/nodejs/node/issues/10731 Fixes: https://github.com/nodejs/node/issues/26231

Checklist
  • make -j4 test (UNIX), or vcbuild test (Windows) passes
  • tests and/or benchmarks are included
  • documentation is changed or added
  • commit message follows commit guidelines

Merge request reports

Loading