Comments (7)
I should have mentioned that after restarting homebridge, the accessories seem to all show up in HomeKit, so I'm not sure if there is any long term adverse consequences aside from the crash itself.
from homebridge-alarmdecoder-platform.
Well that trace gives me something to go by. Just to confirm, you actually do have a zone 5 right? I’ll look into it tonight and see if that might get some clues as to the cause of the crash.
from homebridge-alarmdecoder-platform.
Yep, I've got a zone 5 - it's a contact sensor.
I tried again with a different installation to see if it was specific to that sensor or whether it was just crashing on whatever sensor is first getting the "identify" event. This homebridge installation is through HOOBS on a raspberry pi, whereas the trace above is from a vanilla home bridge installation on my Mac.
It still crashes when adding the hub to HomeKit after the plugin was install, but it is a different sensor (zone 6 - a motion sensor).
Interestingly, the trace looks a different this time -- the crash still relates to that callback function, but it isn't actually crashing in the plugin code:
5/7/2020, 9:16:49 AM [Alarm System] 6 Kitchen Motion Identify!!!
5/7/2020, 9:16:49 AM Error: This callback function has already been called by someone else; it can only be called one time.
at /usr/local/lib/node_modules/@hoobs/hoobs/node_modules/hap-nodejs/dist/lib/util/once.js:11:19
at Accessory.<anonymous> (/usr/local/lib/node_modules/@hoobs/hoobs/bridge/platform.js:57:13)
at Accessory.emit (events.js:310:20)
at Accessory.EventEmitter.emit (/usr/local/lib/node_modules/@hoobs/hoobs/node_modules/hap-nodejs/dist/lib/EventEmitter.js:59:38)
at Accessory._this._identificationRequest (/usr/local/lib/node_modules/@hoobs/hoobs/node_modules/hap-nodejs/dist/lib/Accessory.js:148:23)
at Identify.<anonymous> (/usr/local/lib/node_modules/@hoobs/hoobs/node_modules/hap-nodejs/dist/lib/Accessory.js:1081:23)
at Identify.emit (events.js:310:20)
at Identify.EventEmitter.emit (/usr/local/lib/node_modules/@hoobs/hoobs/node_modules/hap-nodejs/dist/lib/EventEmitter.js:59:38)
at Identify.Characteristic._this.setValue (/usr/local/lib/node_modules/@hoobs/hoobs/node_modules/hap-nodejs/dist/lib/Characteristic.js:349:23)
at /usr/local/lib/node_modules/@hoobs/hoobs/node_modules/hap-nodejs/dist/lib/Accessory.js:940:36
5/7/2020, 9:16:49 AM Got SIGTERM, shutting down Bridge...
It seems from this error that maybe the plugin is calling a callback function that it isn't supposed to?
I poked around the homebridge code and saw some references (e.g., PlatformAccessory.ts @ 85) that mention backwards compatibility regarding how the callback is handled, so maybe something in the underlying homebridge model changed since this plugin was first written?
from homebridge-alarmdecoder-platform.
Also, I confirmed the crash only seems to happen if the hub is added to HomeKit after this plugin has already been installed and configured. If install the plugin on a homebridge installation that has already been added to HomeKit, the accessories show up seemingly without issue.
It seems like the difference is that when you adding a hub that already has accessories set up, the Home app puts up a set of screens to walk through configuring each accessory, which triggers the "identify" event that causes the crash:
If you install and configure the plugin after the hub has already been added, it doesn't show those setup screens and instead just dumps all of the accessories in the Default Room and so doesn't trigger the crash. Opening each accessory up manually to configure (e.g., assign to room, change name, etc.) doesn't seem to send out those identify events and so doesn't seem to trigger the crash.
from homebridge-alarmdecoder-platform.
One quick clarification -- it looks like those setup screens are not specific to the Home app. I tried adding the hub with the plugins using the Eve app, and it pulled up the same interface (and caused the same crash).
from homebridge-alarmdecoder-platform.
it seems identify isn't really even used anymore and the function signature is incorrect. Definitely broke during the push to 1.0 for HomeKit. I don't have a way to test anymore but can you clone the 'fix16' branch and see if that fixes things?
from homebridge-alarmdecoder-platform.
Yep, that seems to fix it, at least on my development installation. Now when adding the hub, it logs an "Identify!!!" message for each discovered accessory but no longer crashes.
Thanks!
from homebridge-alarmdecoder-platform.
Related Issues (20)
- Fix for issue 5 broke sending for ademco/honeywell boards HOT 2
- Port Same? HOT 1
- Bad Request',) line 1144. HOT 1
- Bad Request inside of Webapp with Webhook setup as outlined HOT 4
- Sporadic "no response" in HomeKit HOT 7
- "No Response" from Alarm System accessory when system is armed HOT 17
- Notification issue HOT 2
- Duplicate Zones after resyncing panel HOT 1
- I'm missing something.... HOT 2
- adding custom buttons? HOT 7
- useSwitches for any arbitrary commands HOT 1
- Can’t Arm “Night” HOT 8
- Plugin causing system to crash HOT 2
- Parse Error: Expected HTTP/ HOT 1
- Errors detected with interlogix integration HOT 1
- Excessive logging in Homebridge HOT 3
- Repository Release is showing 2.x HOT 1
- Plug-in is slowing down Homebridge
- Npm and Git repos are out of sync HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from homebridge-alarmdecoder-platform.