{"action":"closed","issue":{"url":"https://api.github.com/repos/joyent/node/issues/7539","labels_url":"https://api.github.com/repos/joyent/node/issues/7539/labels{/name}","comments_url":"https://api.github.com/repos/joyent/node/issues/7539/comments","events_url":"https://api.github.com/repos/joyent/node/issues/7539/events","html_url":"https://github.com/joyent/node/issues/7539","id":32616037,"number":7539,"title":"util: inspect() throws TypeError on proxy objects","user":{"login":"bnoordhuis","id":275871,"avatar_url":"https://avatars.githubusercontent.com/u/275871?v=3","gravatar_id":"","url":"https://api.github.com/users/bnoordhuis","html_url":"https://github.com/bnoordhuis","followers_url":"https://api.github.com/users/bnoordhuis/followers","following_url":"https://api.github.com/users/bnoordhuis/following{/other_user}","gists_url":"https://api.github.com/users/bnoordhuis/gists{/gist_id}","starred_url":"https://api.github.com/users/bnoordhuis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bnoordhuis/subscriptions","organizations_url":"https://api.github.com/users/bnoordhuis/orgs","repos_url":"https://api.github.com/users/bnoordhuis/repos","events_url":"https://api.github.com/users/bnoordhuis/events{/privacy}","received_events_url":"https://api.github.com/users/bnoordhuis/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/joyent/node/labels/util","name":"util","color":"e10c02"}],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2014-05-01T13:54:44Z","updated_at":"2015-06-03T17:50:30Z","closed_at":"2015-06-03T17:50:30Z","body":"```\r\n$ out/Debug/node --harmony -p 'Proxy.create({}, {})'\r\nutil.js:216\r\n      isFunction(value.inspect) &&\r\n                      ^\r\nTypeError: undefined is not a function\r\n    at formatValue (util.js:216:23)\r\n    at inspect (util.js:147:10)\r\n    at Console.exports.format (util.js:27:20)\r\n    at Console.log (console.js:53:34)\r\n    at evalScript (node.js:429:38)\r\n    at startup (node.js:85:7)\r\n    at node.js:807:3\r\n```\r\n\r\nIt also doesn't like certain kinds of 'magical' objects:\r\n\r\n```\r\n$ out/Debug/node --expose_debug_as=D -p D.builtins\r\nutil.js:235\r\n  var keys = Object.keys(value);\r\n                    ^\r\nTypeError: Object.keys called on non-object\r\n    at Function.keys (native)\r\n    at formatValue (util.js:235:21)\r\n    at formatProperty (util.js:450:15)\r\n    at util.js:360:14\r\n    at Array.map (native)\r\n    at formatValue (util.js:359:19)\r\n    at inspect (util.js:147:10)\r\n    at Console.exports.format (util.js:27:20)\r\n    at Console.log (console.js:53:34)\r\n    at evalScript (node.js:429:38)\r\n```\r\n\r\nMaybe it's because D.builtins is a recursive structure but util.format() is supposed to handle those, right?\r\n\r\nVerified with today's master, commit 26a1b71."}}