{"action":"created","issue":{"url":"https://api.github.com/repos/cytoscape/cytoscape.js-cose-bilkent/issues/18","repository_url":"https://api.github.com/repos/cytoscape/cytoscape.js-cose-bilkent","labels_url":"https://api.github.com/repos/cytoscape/cytoscape.js-cose-bilkent/issues/18/labels{/name}","comments_url":"https://api.github.com/repos/cytoscape/cytoscape.js-cose-bilkent/issues/18/comments","events_url":"https://api.github.com/repos/cytoscape/cytoscape.js-cose-bilkent/issues/18/events","html_url":"https://github.com/cytoscape/cytoscape.js-cose-bilkent/issues/18","id":161383161,"number":18,"title":"TypeError when running layout","user":{"login":"EyMaddis","id":1409100,"avatar_url":"https://avatars.githubusercontent.com/u/1409100?v=3","gravatar_id":"","url":"https://api.github.com/users/EyMaddis","html_url":"https://github.com/EyMaddis","followers_url":"https://api.github.com/users/EyMaddis/followers","following_url":"https://api.github.com/users/EyMaddis/following{/other_user}","gists_url":"https://api.github.com/users/EyMaddis/gists{/gist_id}","starred_url":"https://api.github.com/users/EyMaddis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/EyMaddis/subscriptions","organizations_url":"https://api.github.com/users/EyMaddis/orgs","repos_url":"https://api.github.com/users/EyMaddis/repos","events_url":"https://api.github.com/users/EyMaddis/events{/privacy}","received_events_url":"https://api.github.com/users/EyMaddis/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/cytoscape/cytoscape.js-cose-bilkent/labels/bug","name":"bug","color":"fc2929"}],"state":"open","locked":false,"assignee":{"login":"metincansiper","id":6534865,"avatar_url":"https://avatars.githubusercontent.com/u/6534865?v=3","gravatar_id":"","url":"https://api.github.com/users/metincansiper","html_url":"https://github.com/metincansiper","followers_url":"https://api.github.com/users/metincansiper/followers","following_url":"https://api.github.com/users/metincansiper/following{/other_user}","gists_url":"https://api.github.com/users/metincansiper/gists{/gist_id}","starred_url":"https://api.github.com/users/metincansiper/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/metincansiper/subscriptions","organizations_url":"https://api.github.com/users/metincansiper/orgs","repos_url":"https://api.github.com/users/metincansiper/repos","events_url":"https://api.github.com/users/metincansiper/events{/privacy}","received_events_url":"https://api.github.com/users/metincansiper/received_events","type":"User","site_admin":false},"milestone":null,"comments":6,"created_at":"2016-06-21T09:02:42Z","updated_at":"2016-06-23T13:08:35Z","closed_at":null,"body":"Hi,\r\nI get the following error when applying the layout.\r\n\r\nCytoscape version: 2.7.2\r\ncose-bilkent version: 1.3.6\r\n\r\n`index.js:622 Uncaught TypeError: Cannot read property 'data' of undefined`\r\n\r\nThe `node` object in the following line is undefined:\r\nhttps://github.com/cytoscape/cytoscape.js-cose-bilkent/blob/19747ec08b6c37b1fbcffa8a88d19dfae13da6fb/src/Layout/index.js#L621\r\n\r\n\r\nThe following graph was used:\r\n\r\n\r\n```json \r\n{\r\n    \"nodes\": [\r\n        {\r\n            \"data\": {\r\n                \"id\": \"test-system123-nodeGroup-1\",\r\n                \"name\": \"CoCoMe\",\r\n                \"systemId\": \"system123\",\r\n                \"type\": \"nodeGroup\",\r\n                \"label\": \"CoCoMe\"\r\n            }\r\n        },\r\n        {\r\n            \"data\": {\r\n                \"id\": \"test-system123-node-2\",\r\n                \"name\": \"Logicnode\",\r\n                \"ip\": \"10.0.0.2\",\r\n                \"hostname\": \"host2\",\r\n                \"nodeGroupId\": \"test-system123-nodeGroup-1\",\r\n                \"systemId\": \"system123\",\r\n                \"type\": \"node\",\r\n                \"label\": \"Logicnode\",\r\n                \"parent\": \"test-system123-nodeGroup-1\"\r\n            }\r\n        },\r\n        {\r\n            \"data\": {\r\n                \"id\": \"test-system123-node-3\",\r\n                \"name\": \"Adapter\",\r\n                \"ip\": \"10.0.0.2\",\r\n                \"hostname\": \"host3\",\r\n                \"nodeGroupId\": \"test-system123-nodeGroup-1\",\r\n                \"systemId\": \"system123\",\r\n                \"type\": \"node\",\r\n                \"label\": \"Adapter\",\r\n                \"parent\": \"test-system123-nodeGroup-1\"\r\n            }\r\n        },\r\n        {\r\n            \"data\": {\r\n                \"id\": \"test-system123-node-4\",\r\n                \"name\": \"Database\",\r\n                \"ip\": \"10.0.0.2\",\r\n                \"hostname\": \"host4\",\r\n                \"nodeGroupId\": \"test-system123-nodeGroup-1\",\r\n                \"systemId\": \"system123\",\r\n                \"type\": \"node\",\r\n                \"label\": \"Database\",\r\n                \"parent\": \"test-system123-nodeGroup-1\"\r\n            }\r\n        },\r\n        {\r\n            \"data\": {\r\n                \"id\": \"test-system123-node-1\",\r\n                \"name\": \"WebNode\",\r\n                \"ip\": \"10.0.0.1\",\r\n                \"hostname\": \"test hostname\",\r\n                \"nodeGroupId\": \"test-system123-nodeGroup-1\",\r\n                \"systemId\": \"system123\",\r\n                \"type\": \"node\",\r\n                \"label\": \"WebNode\",\r\n                \"parent\": \"test-system123-nodeGroup-1\"\r\n            }\r\n        },\r\n        {\r\n            \"data\": {\r\n                \"id\": \"test-system123-serviceInstance-4\",\r\n                \"name\": \"Inventory\",\r\n                \"nodeId\": \"test-system123-node-2\",\r\n                \"serviceId\": \"test-system123-service-4\",\r\n                \"systemId\": \"system123\",\r\n                \"type\": \"serviceInstance\",\r\n                \"label\": \"Inventory\",\r\n                \"parent\": \"test-system123-node-2\"\r\n            }\r\n        },\r\n        {\r\n            \"data\": {\r\n                \"id\": \"test-system123-serviceInstance-5\",\r\n                \"name\": \"Data\",\r\n                \"nodeId\": \"test-system123-node-3\",\r\n                \"serviceId\": \"test-system123-service-5\",\r\n                \"systemId\": \"system123\",\r\n                \"type\": \"serviceInstance\",\r\n                \"label\": \"Data\",\r\n                \"parent\": \"test-system123-node-3\"\r\n            }\r\n        },\r\n        {\r\n            \"data\": {\r\n                \"id\": \"test-system123-serviceInstance-6\",\r\n                \"name\": \"PostgreSQL\",\r\n                \"nodeId\": \"test-system123-node-4\",\r\n                \"serviceId\": \"test-system123-service-6\",\r\n                \"systemId\": \"system123\",\r\n                \"type\": \"serviceInstance\",\r\n                \"label\": \"PostgreSQL\",\r\n                \"parent\": \"test-system123-node-4\"\r\n            }\r\n        },\r\n        {\r\n            \"data\": {\r\n                \"id\": \"test-system123-serviceInstance-1\",\r\n                \"name\": \"FrontEnd\",\r\n                \"nodeId\": \"test-system123-node-1\",\r\n                \"serviceId\": \"test-system123-service-1\",\r\n                \"systemId\": \"system123\",\r\n                \"type\": \"serviceInstance\",\r\n                \"label\": \"FrontEnd\",\r\n                \"parent\": \"test-system123-node-1\"\r\n            }\r\n        },\r\n        {\r\n            \"data\": {\r\n                \"id\": \"test-system123-serviceInstance-2\",\r\n                \"name\": \"WebService\",\r\n                \"nodeId\": \"test-system123-node-2\",\r\n                \"serviceId\": \"test-system123-service-2\",\r\n                \"systemId\": \"system123\",\r\n                \"type\": \"serviceInstance\",\r\n                \"label\": \"WebService\",\r\n                \"parent\": \"test-system123-node-2\"\r\n            }\r\n        },\r\n        {\r\n            \"data\": {\r\n                \"id\": \"test-system123-serviceInstance-3\",\r\n                \"name\": \"CashDesk\",\r\n                \"nodeId\": \"test-system123-node-2\",\r\n                \"serviceId\": \"test-system123-service-3\",\r\n                \"systemId\": \"system123\",\r\n                \"type\": \"serviceInstance\",\r\n                \"label\": \"CashDesk\",\r\n                \"parent\": \"test-system123-node-2\"\r\n            }\r\n        }\r\n    ],\r\n    \"edges\": [\r\n        {\r\n            \"data\": {\r\n                \"id\": \"test-system123-communicationInstance-1\",\r\n                \"sourceId\": \"test-system123-serviceInstance-1\",\r\n                \"targetId\": \"test-system123-serviceInstance-2\",\r\n                \"communicationId\": null,\r\n                \"systemId\": \"system123\",\r\n                \"type\": \"communicationInstance\",\r\n                \"source\": \"test-system123-serviceInstance-1\",\r\n                \"target\": \"test-system123-serviceInstance-2\"\r\n            }\r\n        },\r\n        {\r\n            \"data\": {\r\n                \"id\": \"test-system123-communicationInstance-2\",\r\n                \"sourceId\": \"test-system123-serviceInstance-2\",\r\n                \"targetId\": \"test-system123-serviceInstance-3\",\r\n                \"communicationId\": null,\r\n                \"systemId\": \"system123\",\r\n                \"type\": \"communicationInstance\",\r\n                \"source\": \"test-system123-serviceInstance-2\",\r\n                \"target\": \"test-system123-serviceInstance-3\"\r\n            }\r\n        },\r\n        {\r\n            \"data\": {\r\n                \"id\": \"test-system123-communicationInstance-3\",\r\n                \"sourceId\": \"test-system123-serviceInstance-3\",\r\n                \"targetId\": \"test-system123-serviceInstance-4\",\r\n                \"communicationId\": null,\r\n                \"systemId\": \"system123\",\r\n                \"type\": \"communicationInstance\",\r\n                \"source\": \"test-system123-serviceInstance-3\",\r\n                \"target\": \"test-system123-serviceInstance-4\"\r\n            }\r\n        },\r\n        {\r\n            \"data\": {\r\n                \"id\": \"test-system123-communicationInstance-4\",\r\n                \"sourceId\": \"test-system123-serviceInstance-3\",\r\n                \"targetId\": \"test-system123-serviceInstance-5\",\r\n                \"communicationId\": null,\r\n                \"systemId\": \"system123\",\r\n                \"type\": \"communicationInstance\",\r\n                \"source\": \"test-system123-serviceInstance-3\",\r\n                \"target\": \"test-system123-serviceInstance-5\"\r\n            }\r\n        },\r\n        {\r\n            \"data\": {\r\n                \"id\": \"test-system123-communicationInstance-5\",\r\n                \"sourceId\": \"test-system123-serviceInstance-4\",\r\n                \"targetId\": \"test-system123-serviceInstance-5\",\r\n                \"communicationId\": null,\r\n                \"systemId\": \"system123\",\r\n                \"type\": \"communicationInstance\",\r\n                \"source\": \"test-system123-serviceInstance-4\",\r\n                \"target\": \"test-system123-serviceInstance-5\"\r\n            }\r\n        },\r\n        {\r\n            \"data\": {\r\n                \"id\": \"test-system123-communicationInstance-6\",\r\n                \"sourceId\": \"test-system123-serviceInstance-5\",\r\n                \"targetId\": \"test-system123-serviceInstance-6\",\r\n                \"communicationId\": null,\r\n                \"systemId\": \"system123\",\r\n                \"type\": \"communicationInstance\",\r\n                \"source\": \"test-system123-serviceInstance-5\",\r\n                \"target\": \"test-system123-serviceInstance-6\"\r\n            }\r\n        }\r\n    ]\r\n}\r\n```\r\n\r\nI would appreciate help.\r\nThanks"},"comment":{"url":"https://api.github.com/repos/cytoscape/cytoscape.js-cose-bilkent/issues/comments/228044208","html_url":"https://github.com/cytoscape/cytoscape.js-cose-bilkent/issues/18#issuecomment-228044208","issue_url":"https://api.github.com/repos/cytoscape/cytoscape.js-cose-bilkent/issues/18","id":228044208,"user":{"login":"EyMaddis","id":1409100,"avatar_url":"https://avatars.githubusercontent.com/u/1409100?v=3","gravatar_id":"","url":"https://api.github.com/users/EyMaddis","html_url":"https://github.com/EyMaddis","followers_url":"https://api.github.com/users/EyMaddis/followers","following_url":"https://api.github.com/users/EyMaddis/following{/other_user}","gists_url":"https://api.github.com/users/EyMaddis/gists{/gist_id}","starred_url":"https://api.github.com/users/EyMaddis/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/EyMaddis/subscriptions","organizations_url":"https://api.github.com/users/EyMaddis/orgs","repos_url":"https://api.github.com/users/EyMaddis/repos","events_url":"https://api.github.com/users/EyMaddis/events{/privacy}","received_events_url":"https://api.github.com/users/EyMaddis/received_events","type":"User","site_admin":false},"created_at":"2016-06-23T13:08:35Z","updated_at":"2016-06-23T13:08:35Z","body":"After further investigation, I noticed that the problem lies with native `prototype` extensions.\r\nThe demo from @metincansiper breaks with `Array.prototype.test='test!'`.\r\nI managed to disable such extensions, I no longer get the exception, but now it seems that cytoscape itself breaks (maybe I did not disable all extensions) and nothing gets rendered without any exceptions.\r\n\r\nThe weird part is that I can use every other layout algorithm (e.g. `cose` and even `cola`) and it renders just fine."}}
{"actor":{"display_login":"EyMaddis"}}