TreehouseFalcon / homebridge-kwikset-halo

An easy to use Homebridge plugin for Kwikset Halo locks
Apache License 2.0
7 stars 2 forks source link

Plugin doesn't load: Cannot find module 'ip' #22

Open zilvernet opened 1 month ago

zilvernet commented 1 month ago

Describe The Bug: Plugin version v0.3.3 fails to load

To Reproduce:

Expected behavior:

Logs:

Show the Homebridge logs here, remove any sensitive information.

[5/15/2024, 9:30:30 PM] ====================
[5/15/2024, 9:30:30 PM] ERROR LOADING PLUGIN homebridge-kwikset-halo:
[5/15/2024, 9:30:30 PM] Error: Cannot find module 'ip'
Require stack:
- /homebridge/node_modules/homebridge-kwikset-halo/dist/kwikset.js
- /homebridge/node_modules/homebridge-kwikset-halo/dist/lock.js
- /homebridge/node_modules/homebridge-kwikset-halo/dist/platform.js
- /homebridge/node_modules/homebridge-kwikset-halo/dist/index.js
- /homebridge/node_modules/homebridge/lib/plugin.js
- /homebridge/node_modules/homebridge/lib/pluginManager.js
- /homebridge/node_modules/homebridge/lib/api.js
- /homebridge/node_modules/homebridge/lib/server.js
- /homebridge/node_modules/homebridge/lib/cli.js
- /homebridge/node_modules/homebridge/bin/homebridge
    at Function.Module._resolveFilename (node:internal/modules/cjs/loader:1143:15)
    at Function.Module._load (node:internal/modules/cjs/loader:984:27)
    at Module.require (node:internal/modules/cjs/loader:1231:19)
    at require (node:internal/modules/helpers:179:18)
    at Object.<anonymous> (/homebridge/node_modules/homebridge-kwikset-halo/src/kwikset.ts:13:1)
    at Module._compile (node:internal/modules/cjs/loader:1369:14)
    at Object.Module._extensions..js (node:internal/modules/cjs/loader:1427:10)
    at Module.load (node:internal/modules/cjs/loader:1206:32)
    at Function.Module._load (node:internal/modules/cjs/loader:1022:12)
    at Module.require (node:internal/modules/cjs/loader:1231:19)

Plugin Config:

Show your Homebridge config.json here, remove any sensitive information.
{
    "bridge": {
        "name": "Homebridge ****",
        "username": "***********",
        "port": 51445,
        "pin": "*********",
        "advertiser": "bonjour-hap"
    },
    "accessories": [],
    "platforms": [
        {
            "name": "Config",
            "port": 8581,
            "auth": "form",
            "theme": "auto",
            "tempUnits": "f",
            "lang": "auto",
            "platform": "config"
        },
        {
            "email": "****@gmail.com",
            "password": "************",
            "homeName": "*******",
            "mfaPort": 47278,
            "platform": "homebridge-kwikset-halo"
        }
    ]
}

Screenshots:

Environment:

moralesaugusto commented 1 month ago

It was fixed by just running: hb-service add ip

prysyazhny commented 3 weeks ago

It was fixed by just running: hb-service add ip

When I run this command I get this error: ✖ Invalid plugin name.

nenntendo64 commented 2 weeks ago

It was fixed by just running: hb-service add ip

When I run this command I get this error: ✖ Invalid plugin name.

Try running with sudo, had this error and running sudo hb-service add ip fixed it

zilvernet commented 1 week ago

Hi,

Im running these commands on the homebridge ui terminal but are not working for me.

root@homebridge:/var/lib/homebridge $ hb-service add ip
✖ Invalid plugin name.

root@homebridge:/var/lib/homebridge $ sudo hb-service add ip
ERROR: sudo / root access is not allowed by the homebridge service account. You can use "su <username>" to swap to your local user account. 

Remember i'm running on a docker image. I just pulled the latest image (2024-06-20) but these commands are not working on my end.