Zacknetic / HomebridgeMagicHome-DynamicPlatform

Homebridge Plugin for MagicHome LED controllers and light bulbs
Apache License 2.0
61 stars 11 forks source link

[BUG] Blacklist not working as expected #79

Closed highlandery closed 3 years ago

highlandery commented 3 years ago

Describe the bug

Every 30 seconds an error appears in the log indicating a blacklisted device did not respond. The network includes a LimitlessLed/MiLight WiFi Receiver Bridge which appears to be falsely identified as a MagicHome light. Other MagicHome devices are identified and operate correctly.

Expected behavior

Blacklisted MAC addresses should be excluded from discovery or not display error messages.

Host Hardware

Homebridge and MagicHome Versions

Error Log

[1/9/2021, 2:46:06 PM] [homebridge-magichome-dynamic-platform] Warning! Discovered device did not respond to query. This is usually due to an unresponsive device.
Please restart homebridge. If the problem persists, ensure the device works in the "Magichome Pro" app.
File an issue on github with an uploaded log. {
  ipAddress: '192.168.1.23',
  uniqueId: 'F0FE6BC2873C',
  modelNumber: 'HF-LPB100'
}

Config

        {
            "pruning": {
                "pruneMissingCachedAccessories": true,
                "restartsBeforeMissingAccessoriesPruned": 3,
                "pruneAllAccessoriesNextRestart": false
            },
            "whiteEffects": {
                "simultaniousDevicesColorWhite": true,
                "colorWhiteThreshold": 10,
                "colorWhiteThresholdSimultaniousDevices": 50,
                "colorOffThresholdSimultaniousDevices": 5
            },
            "deviceManagement": {
                "blacklistOrWhitelist": "blacklist",
                "blacklistedUniqueIDs": [
                    "F0FE6BC2873C"
                ]
            },
            "advancedOptions": {
                "namesWithMacAddress": false
            },
            "platform": "homebridge-magichome-dynamic-platform"
        },
Zacknetic commented 3 years ago

Hey, thanks for bringing this to my attention.

It looks like the check for blacklisted devices doesn't occur on later scans. I take a look at this when I get a chance and incorporate it into the next minor update.

As for the logs, we have a feature in the works right now that will allow users to select the verbosity of MagicHome logs. Whichever fix comes first will solve your issue.

Until then, I'm afraid your logs are going to get a little full.

highlandery commented 3 years ago

Great. Not a huge issue, just thought it was probably an easy fix and worth reporting so I don’t have to look at a sea of red logs.

Thanks for all the work, putting together some docs, config UI settings etc. the plug-in works great and easy to setup.

Zacknetic commented 3 years ago

83 Should solve your issue soon. Thanks to @tom-23.

tom-23 commented 3 years ago

@highlandery should be addressed in beta.6. Let me know if you're still having issues!

Zacknetic commented 3 years ago

Closing this due to lack of activity.