Comments (4)
Trying to debug this, I cloned and built the master branch of the zigbee-adapter repo into the add-ons folder and managed to pair and use a Zigbee smart plug without any issues. When I swap the add-on out for the 0.21.1 packaged and released version it stops working.
If I manually build the released 0.21.1 tag it keeps working.
I've not figured out what's going on yet. I have noticed the version of the gateway-addon package listed as a devDependency in the Zigbee add-on is older (1.0.0) than the one shipped with the gateway (1.2.0-alpha.1), but it should ideally be backwards compatible.
from gateway.
Notably, if I npm prune --production
on the 0.21.1 checkout after building (one of the steps carried out by the packaging script) to remove the devDependencies, it seems to stop working.
This suggests to me that during development the adapter is using its own gateway-addon 1.0.0 module, but once packaged it's traversing up the tree and using the gateway's central gateway-addon 1.2.0-alpha.1 module, and not working properly with that version.
This is further supported by the fact that the Z-wave add-on also lists gateway-addon 1.0.0 as a devDependency (and is broken), but the virtual-things-adapter doesn't (and is working fine). I guess that's why we tell people never to add it as a dependency for an add-on!
Next steps:
- Upgrade the devDependency (or remove it if possible)
- Test the add-on with both gateway 1.2 and gateway 1.1 (to make sure it's backwards compatible)
from gateway.
Update: I've tried upgrading the gateway-addon dependency of the zigbee-adapter to the same version used in gateway 1.2.0-alpha.1, but so far that alone doesn't seem to fix the problem WebThingsIO/zigbee-adapter#333
More debugging required.
from gateway.
I think I've figured out what's going on, at least for the Zigbee add-on, and I should have realised earlier.
The Zigbee adapter is deleting all properties from Thing Descriptions that don't have a truthy visible
member.
I forgot we removed support for the visible
member on master but re-introduced it on the 1.1 branch (for this reason). See #3038 for a full explanation.
Ideally we should fix this in individual add-ons rather than keeping this deprecated feature around for another release, but unfortunately it doesn't like the deprecation warning we added actually gets printed to the console so add-on developers may not have noticed it.
This may require some research to find out how many add-ons use the visible feature.
from gateway.
Related Issues (20)
- Confirm deletion of user account
- Confirm removal of add-on HOT 2
- Consider warning users that tunnel can't be configured after first time setup
- Error on startup with docker-compose HOT 2
- Things or "No devices yet" message do not appear on first boot
- Back button on Thing detail view not working
- RPI3+ 1.2.0-alpha.1 - Missing refreshes in 'Things' view ? HOT 1
- WebThings Gateway 1.2 Alpha testing feedback HOT 6
- MaxListenersExceededWarning: Possible EventEmitter memory leak detected.
- Existing Things have both links and forms after upgrade
- Set `synchronous` to `false` in action affordances in Thing Descriptions
- Epic: Upgrade to Node.js 20
- Epic: OAuth 2.0 Compliance
- Epic: W3C WoT Thing Description 1.1 Compliance
- Epic: W3C WoT Profile 1.0 Compliance
- Epic: W3C WoT Discovery 1.0 Compliance
- Ubuntu Core based OS image
- Snap Package HOT 1
- Epic: Upgrade Python
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 gateway.