{"action":"created","issue":{"url":"https://api.github.com/repos/json-schema-faker/json-schema-faker/issues/92","repository_url":"https://api.github.com/repos/json-schema-faker/json-schema-faker","labels_url":"https://api.github.com/repos/json-schema-faker/json-schema-faker/issues/92/labels{/name}","comments_url":"https://api.github.com/repos/json-schema-faker/json-schema-faker/issues/92/comments","events_url":"https://api.github.com/repos/json-schema-faker/json-schema-faker/issues/92/events","html_url":"https://github.com/json-schema-faker/json-schema-faker/issues/92","id":129916591,"number":92,"title":"Hangs with circular references ","user":{"login":"blikblum","id":3047126,"avatar_url":"https://avatars.githubusercontent.com/u/3047126?v=3","gravatar_id":"","url":"https://api.github.com/users/blikblum","html_url":"https://github.com/blikblum","followers_url":"https://api.github.com/users/blikblum/followers","following_url":"https://api.github.com/users/blikblum/following{/other_user}","gists_url":"https://api.github.com/users/blikblum/gists{/gist_id}","starred_url":"https://api.github.com/users/blikblum/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/blikblum/subscriptions","organizations_url":"https://api.github.com/users/blikblum/orgs","repos_url":"https://api.github.com/users/blikblum/repos","events_url":"https://api.github.com/users/blikblum/events{/privacy}","received_events_url":"https://api.github.com/users/blikblum/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":6,"created_at":"2016-01-30T00:08:40Z","updated_at":"2016-02-04T16:06:40Z","closed_at":null,"body":"When i try the following schema:  https://gist.github.com/blikblum/5c90d02a99b3f3b9c017#file-data-schema-json [changed to avoid the circular reference, see comment below for example]\r\n\r\nJSON Schema Faker becomes unresponsive, consuming all cpu time and is necessary to kill its process.\r\n\r\nThis occurs both with the online demo and using node 4.2.4\r\n\r\nTested with 0.2.8"},"comment":{"url":"https://api.github.com/repos/json-schema-faker/json-schema-faker/issues/comments/179919683","html_url":"https://github.com/json-schema-faker/json-schema-faker/issues/92#issuecomment-179919683","issue_url":"https://api.github.com/repos/json-schema-faker/json-schema-faker/issues/92","id":179919683,"user":{"login":"tauren","id":282084,"avatar_url":"https://avatars.githubusercontent.com/u/282084?v=3","gravatar_id":"","url":"https://api.github.com/users/tauren","html_url":"https://github.com/tauren","followers_url":"https://api.github.com/users/tauren/followers","following_url":"https://api.github.com/users/tauren/following{/other_user}","gists_url":"https://api.github.com/users/tauren/gists{/gist_id}","starred_url":"https://api.github.com/users/tauren/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tauren/subscriptions","organizations_url":"https://api.github.com/users/tauren/orgs","repos_url":"https://api.github.com/users/tauren/repos","events_url":"https://api.github.com/users/tauren/events{/privacy}","received_events_url":"https://api.github.com/users/tauren/received_events","type":"User","site_admin":false},"created_at":"2016-02-04T16:06:40Z","updated_at":"2016-02-04T16:06:40Z","body":"@pateketrueke Sounds great! However, I've been trying to use the `npm-scripts` branch with a circular schema that has been dereferenced with `json-schema-ref-parser` and I'm getting an error in `clone-obj.js`:\r\n\r\n```\r\nError: unable dereference circular structures\r\n    at module.exports (/Users/tmil11/stash/nidr/playbook-rulebook/node_modules/json-schema-faker/node_modules/deref/lib/util/clone-obj.js:7:11)\r\n    at copy (/Users/tmil11/stash/nidr/playbook-rulebook/node_modules/json-schema-faker/node_modules/deref/lib/util/clone-obj.js:19:19)\r\n    at /Users/tmil11/stash/nidr/playbook-rulebook/node_modules/json-schema-faker/node_modules/deref/lib/util/clone-obj.js:28:7\r\n    at Array.forEach (native)\r\n```\r\n\r\nThis may be due to my shemas, as I'm not convinced the `id` and `$ref` properties are setup up correctly. I'm working on figuring that out. \r\n\r\nPerhaps you could check `clone-obj.js` to see if there is something simple that might cause this as well?\r\n"}}