tonesto7 / homebridge-smartthings

SmartThings Homebridge Plugin
384 stars 770 forks source link

Error with Smartthings-V2 #372

Open DOCNY opened 3 years ago

DOCNY commented 3 years ago

Verify the following before opening an trouble issue

Go over all the following points, and put an x in all the boxes that apply. If you're unsure about any of these, don't hesitate to ask. We're here to help!


About Your Setup

Expected Behavior

Tell us what you think should be happening Device cache is empty. No device added but do get status update from same devices. Previous version work normal. This code was previously working ok but something broke. Even a fresh install doesn't fix the problem.

Current Behavior

What happens instead of the expected behavior?

[10/2/2020, 9:29:08 PM] Homebridge v1.2.3 is running on port 51826. INFO: INFO: Your plugin version is up-to-date NOTICE: Sending Plugin Status to SmartThings | UpdateAvailable: false DEBUG: sendUpdateStatus Resp: {"status":"OK"} ERROR: getDevices Error: undefined | Message: timeout of 10000ms exceeded ALERT: Total Initialization Time: (10 seconds) NOTICE: Unknown Capabilities: [] INFO: SmartThings DeviceCache Size: (0) INFO: WebServer Initiated... INFO: Sending StartDirect Request to SmartThings | SendToLocalHub: (false) INFO: Direct Connect Active | Listening at 192.168.7.28:8000 DEBUG: sendStartDirect Resp: {"status":"OK"}

Steps to Reproduce (for bugs)

Provide a link to a live example, or an unambiguous set of steps to reproduce this bug. Include code to reproduce, if relevant

  1. No devices added

Context

How has this issue affected you? What are you trying to accomplish? Providing context helps us come up with a solution that is most useful in the real world** New devices were not adding so I deleted cache and persist and now no devices exist. I regenerated token but doesn't resolve. If I switch to the old version of the plugin, every device is added and works.

Please include a copy of any relevant log output to assist in tracking down the bug

DOCNY commented 3 years ago

So I did a bit of troubleshooting. It turns out that after a certain number of devices (~115 or so) it does not add more devices. What I did was I cleared cache and persist folders and because there were more than that number of devices, it wouldn't add any. Adding one at a time or multiple under that arbitrary number were added and would remain in cache. My work around for now is creatine two instances of the SmartApp and splitting the number of devices.