{"action":"opened","issue":{"url":"https://api.github.com/repos/nfarina/homebridge/issues/640","repository_url":"https://api.github.com/repos/nfarina/homebridge","labels_url":"https://api.github.com/repos/nfarina/homebridge/issues/640/labels{/name}","comments_url":"https://api.github.com/repos/nfarina/homebridge/issues/640/comments","events_url":"https://api.github.com/repos/nfarina/homebridge/issues/640/events","html_url":"https://github.com/nfarina/homebridge/issues/640","id":156103736,"number":640,"title":"Having duplicate accessory names causes error ","user":{"login":"wind-rider","id":3463496,"avatar_url":"https://avatars.githubusercontent.com/u/3463496?v=3","gravatar_id":"","url":"https://api.github.com/users/wind-rider","html_url":"https://github.com/wind-rider","followers_url":"https://api.github.com/users/wind-rider/followers","following_url":"https://api.github.com/users/wind-rider/following{/other_user}","gists_url":"https://api.github.com/users/wind-rider/gists{/gist_id}","starred_url":"https://api.github.com/users/wind-rider/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/wind-rider/subscriptions","organizations_url":"https://api.github.com/users/wind-rider/orgs","repos_url":"https://api.github.com/users/wind-rider/repos","events_url":"https://api.github.com/users/wind-rider/events{/privacy}","received_events_url":"https://api.github.com/users/wind-rider/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2016-05-21T14:08:55Z","updated_at":"2016-05-21T14:08:55Z","closed_at":null,"body":"What I did:\r\n- Installed homebridge & hue plugin\r\n- Set up bridge ip in config.json, registered username in config.json\r\n- Paired with phone\r\n- Changed lamp names I named two lamps the same (\"Ceiling\") since they are in different rooms -> I wanted to say something like \"hey Siri, turn on the ceiling lamp in the bedroom\" instead of naming the lamps \"ceiling bedroom\" and \"ceiling hall\".\r\n\r\nResult: homebridge+hue plugin crashes after a restart\r\n\r\nWorkaround: renaming one of the \"ceiling\" lamps to \"ceiling bedroom\" so that the names are not duplicate anymore helped\r\n\r\nCauses: UUID is generated based upon the accessory name in https://github.com/KhaosT/HAP-NodeJS/blob/master/lib/util/uuid.js\r\nPossible solutions: \r\n- the \"name\" should be a concatenation of accessory name and room name to make them unique per room (fix in nfarina/homebridge)\r\n- this UUID shouldn't be linked to the name but to the lamp ID (lamp zigbee address) so that the UUID is unique (fix in homebridge-philipshue)\r\n- the UUID should be not based on a hash which makes it predictable (fix in HAP-NodeJS)\r\n\r\nLog:\r\n````\r\n[2016-05-14 20:18:01] Loaded plugin: homebridge-philipshue\r\n[2016-05-14 20:18:01] Registering platform 'homebridge-philipshue.PhilipsHue'\r\n[2016-05-14 20:18:01] ---\r\n[2016-05-14 20:18:01] Loaded config.json with 0 accessories and 1 platforms.\r\n[2016-05-14 20:18:01] ---\r\n[2016-05-14 20:18:01] Loading 1 platforms...\r\n[2016-05-14 20:18:01] [Philips Hue] Initializing PhilipsHue platform...\r\n[2016-05-14 20:18:01] [Philips Hue] PhilipsHue Platform Plugin Version 0.0.2\r\n[2016-05-14 20:18:01] [Philips Hue] Fetching Philips Hue lights...\r\n[2016-05-14 20:18:01] [Philips Hue] Initializing platform accessory 'Ceiling'...\r\n[2016-05-14 20:18:01] [Philips Hue] Initializing platform accessory 'Ceiling'...\r\n/usr/local/lib/node_modules/homebridge-philipshue/node_modules/q/q.js:126\r\n                    throw e;\r\n                    ^\r\n\r\nError: Cannot add a bridged Accessory with the same UUID as another bridged Accessory: 88c675f0-a405-4b4e-b2e6-1ad5e94d45c1\r\n    at Bridge.Accessory.addBridgedAccessory (/usr/local/lib/node_modules/homebridge/node_modules/hap-nodejs/lib/Accessory.js:219:13)\r\n    at Server.<anonymous> (/usr/local/lib/node_modules/homebridge/lib/server.js:346:24)\r\n    at /usr/local/lib/node_modules/homebridge/node_modules/hap-nodejs/lib/util/once.js:15:19\r\n    at /usr/local/lib/node_modules/homebridge-philipshue/index.js:140:9\r\n    at resolveValue (/usr/local/lib/node_modules/homebridge-philipshue/node_modules/node-hue-api/hue-api/utils.js:34:13)\r\n    at _fulfilled (/usr/local/lib/node_modules/homebridge-philipshue/node_modules/q/q.js:787:54)\r\n    at self.promiseDispatch.done (/usr/local/lib/node_modules/homebridge-philipshue/node_modules/q/q.js:816:30)\r\n    at Promise.promise.promiseDispatch (/usr/l\r\n````"}}
{"actor":{"display_login":"wind-rider"}}