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
{{ message }}
Repository navigation
Proxy get handler is used when evaluating the proxy #16483
There are some properties that are requested during REPL evaluation of an Object. You can filter them out:
'use strict';constutil=require('util');consto1={ready: false,};setTimeout(()=>{o1.ready=true;},1000000000);consthandler={get(target,propKey,receiver){constfilter=['inspect',util.inspect.custom,Symbol.iterator];if(!filter.includes(propKey)){if(target.ready===false){thrownewError('not ready');}else{return'ready';}}},};constproxy=newProxy(o1,handler);proxy;// does not raise 'not ready'
Activity
[-]Proxy getter raises on evaluation of proxy[/-][+]Proxy get handler is used when evaluating the proxy[/+]bnoordhuis commentedon Oct 25, 2017
I think missing from your description is that it happens in the REPL?
vsemozhetbyt commentedon Oct 25, 2017
There are some properties that are requested during REPL evaluation of an Object. You can filter them out:
repl: show proxies as Proxy objects
bnoordhuis commentedon Oct 25, 2017
#16485 - possible solution.
kuanee commentedon Oct 25, 2017
yup, encountered this in repl. Thanks alot!
repl: show proxies as Proxy objects