SmartThingsDevelopers / SampleDrivers

We are taking events that would have happened on the SmartThings Cloud and moving them to your SmartThings Hub. This repository contains sample SmartThings Edge Drivers to get you started
53 stars 64 forks source link

Bugfix/async sockets only #20

Closed FreeMasen closed 3 years ago

FreeMasen commented 3 years ago

This fixes 2 bugs

  1. Discovery will never end due to making a luasocket socket call from inside of a cosock thread, updating the modules to be imported via cosock.asyncify will make all of the references to socket work as expected.
  2. Devices added to the driver will not come online until either the driver restarts or some external source emits an event. By using the same logic on init as on added this should bring the device online in the mobile app for both cases.
elbe0046 commented 3 years ago

Is the addition of thingsim/rpcclient/thingsim intentional, and if so what does it accomplish?

FreeMasen commented 3 years ago

Is the addition of thingsim/rpcclient/thingsim intentional, and if so what does it accomplish?

Good catch, this was added in error and has now been removed