hoobs-org / HOOBS

Build your Smart Home with HOOBS. Connect over 2,000 Accessories to your favorite Ecosystem.
https://hoobs.org
GNU General Public License v3.0
552 stars 51 forks source link

Node Alarm Dot Com: Update or Uninstall Plugin Failed #527

Closed Sinandgrin closed 4 years ago

Sinandgrin commented 4 years ago

Description I need to update my Node Alarm Dot Com plugin to version 1.4.3 to restore access to my alarm devices but I am having errors when I try to update via the UI or Uninstall via the UI.

Hoobs UI detects that there is a newer version and when I press the Update button it begins to work and tells me that the update completed successfully but the plugin is still showing as outdated and there is no change.

I tried to uninstall the plugin and get an error that stated the uninstall failed.

Please let me know what other information I can provide to help troubleshoot before I go the manual route to try and resolve this issue.

Version Hoobs 3.1.22

Did you upgrade Please let us know if you upgraded from a previous version.

Pervious version If you upgraded, please let us know your previous version.

Did you orginally upgrade to HOOBS 3 from HOOBS 2.1.1? Did you perform an upgrade from HOOBS 2.1.1? Some things are different.

What device are you using? Please let us know the device you are running HOOBS on.

If this is a custom install, what's your operating system? NA

List your plugins Camera FFMPEG Homeseer4 Node Alarm Dot Com <- One with issue here

Post your config This can be found in the interface, Configuration -> Advanced or you can get it via SSH cat ~/.hoobs/etc/config.json

{
    "server": {
        "port": 8080,
        "origin": "*",
        "autostart": 0,
        "home_setup_id": "XXXXX",
        "polling_seconds": 5
    },
    "client": {
        "default_route": "status",
        "inactive_logoff": 30,
        "theme": "hoobs-light",
        "locale": "en",
        "temp_units": "fahrenheit",
        "country_code": "US",
        "postal_code": "XXXXX"
    },
    "bridge": {
        "name": "HOOBS",
        "port": 51826,
        "pin": "XXXXX",
        "username": "XXXXX"
    },
    "description": "",
    "ports": {},
    "accessories": [],
    "platforms": [
        {
            "platform": "Alarmdotcom",
            "name": "Security System",
            "username": "XXXXX",
            "password": "XXXXX",
            "armingModes": {
                "away": {
                    "noEntryDelay": false,
                    "silentArming": false
                },
                "night": {
                    "noEntryDelay": false,
                    "silentArming": false
                },
                "stay": {
                    "noEntryDelay": false,
                    "silentArming": false
                }
            },
            "plugin_map": {
                "plugin_name": "homebridge-node-alarm-dot-com"
            }
        },
        {
            "platform": "Camera-ffmpeg",
            "plugin_map": {
                "plugin_name": "homebridge-camera-ffmpeg"
            },
            "name": "Camera ffmpeg",
            "cameras": [
                {
                    "name": "XXXXX",
                    "videoConfig": {
                        "source": "XXXXX",
                        "stillImageSource": "XXXXX",
                        "maxStreams": 2,
                        "maxWidth": 1280,
                        "maxHeight": 720,
                        "maxFPS": 10,
                        "vcodec": "h264_omx",
                        "debug": true
                    }
                },
                {
                    "name": "XXXXX",
                    "videoConfig": {
                        "source": "XXXXX",
                        "stillImageSource": "XXXXX",
                        "maxStreams": 2,
                        "maxWidth": 1280,
                        "maxHeight": 720,
                        "maxFPS": 10,
                        "vcodec": "h264_omx",
                        "debug": true
                    }
                },
                {
                    "name": "XXXXX",
                    "videoConfig": {
                        "source": "XXXXX",
                        "stillImageSource": "XXXXX",
                        "maxStreams": 2,
                        "maxWidth": 1280,
                        "maxHeight": 720,
                        "maxFPS": 10,
                        "vcodec": "h264_omx",
                        "debug": true
                    }
                },
                {
                    "name": "XXXXX",
                    "videoConfig": {
                        "source": "XXXXX",
                        "stillImageSource": "XXXXX",
                        "maxStreams": 2,
                        "maxWidth": 1280,
                        "maxHeight": 720,
                        "maxFPS": 10,
                        "vcodec": "h264_omx",
                        "debug": true
                    }
                },
                {
                    "name": "XXXXX",
                    "videoConfig": {
                        "source": "XXXXX",
                        "stillImageSource": "XXXXX",
                        "maxStreams": 2,
                        "maxWidth": 1280,
                        "maxHeight": 720,
                        "maxFPS": 10,
                        "vcodec": "h264_omx",
                        "debug": true
                    }
                }
            ]
        },
        {
            "platform": "HomeSeer",
            "name": "HomeSeer",
            "host": "XXXXX",
            "ASCIIport": XXXXX,
            "login": "XXXXX",
            "password": "XXXXX",
            "accessories": [
                {
                    "type": "Lightbulb",
                    "name": "XXXXX",
                    "ref": 129,
                    "onValue": 100
                },
                {
                    "type": "Switch",
                    "name": "XXXXX",
                    "ref": 73,
                    "onValue": 100
                }
            ],
            "plugin_map": {
                "plugin_name": "homebridge-homeseer4"
            }
        }
    ]
}

Post your log You can get the log from the intercafe. This is in the Log section.

[3/21/2020, 12:34:34 PM] HOOBS listening on port XXXXX.
[Homebridge] [3/21/2020, 12:34:35 PM] Loaded config.json with 0 accessories and 3 platforms.
[Homebridge] [3/21/2020, 12:34:39 PM] Loaded plugin: "homebridge-camera-ffmpeg"
[Homebridge] [3/21/2020, 12:34:39 PM] Registering platform "homebridge-camera-ffmpeg.Camera-ffmpeg"
[Homebridge] [3/21/2020, 12:34:41 PM] Loaded plugin: "homebridge-homeseer4"
[Homebridge] homebridge API version: 2.4
[Homebridge] [3/21/2020, 12:34:41 PM] Registering platform "homebridge-HomeSeerPlatform.HomeSeer"
[Homebridge] [3/21/2020, 12:34:41 PM] Loaded plugin: "homebridge-node-alarm-dot-com"
[Homebridge] [3/21/2020, 12:34:41 PM] Registering platform "homebridge-node-alarm-dot-com.Alarmdotcom"
[Homebridge] [3/21/2020, 12:34:41 PM] Loading 3 platforms...
[Homebridge] [3/21/2020, 12:34:41 PM] [Security System] Initializing Alarmdotcom platform...
[Homebridge] [3/21/2020, 12:34:41 PM] [Camera ffmpeg] Initializing Camera-ffmpeg platform...
[Homebridge] [3/21/2020, 12:34:41 PM] [HomeSeer] Initializing HomeSeer platform...
[Homebridge] [3/21/2020, 12:34:41 PM] [HomeSeer] Start
[Homebridge] [3/21/2020, 12:34:41 PM] Loading 0 accessories...
[Homebridge] [3/21/2020, 12:34:41 PM] Load homebridge-HomeSeerPlatform.HomeSeer
XXXXX
[Homebridge] [3/21/2020, 12:34:41 PM] API launched
XXXXX
[Homebridge] [3/21/2020, 12:34:42 PM] [Security System] UNHANDLED ERROR: Error: GET null failed: GET null failed: The "url" argument must be of type string. Received type object
    at /home/hoobs/.hoobs/node_modules/node-alarm-dot-com/index.js:114:17
    at processTicksAndRejections (internal/process/task_queues.js:94:5)
[Homebridge] [3/21/2020, 12:34:42 PM] [HomeSeer] End
[Homebridge] Creating HomeKit devices from HomeSeer data.
[Homebridge] [3/21/2020, 12:34:42 PM] [HomeSeer] Checking Configuration Data
XXXXX
[Homebridge] [3/21/2020, 12:34:42 PM] [HomeSeer] Successfully connected to ASCII Control Interface of HomeSeer.
[Homebridge] [3/21/2020, 12:34:42 PM] [HomeSeer] Sent Authorization Data
[Homebridge] [3/21/2020, 12:34:44 PM] [HomeSeer] Successfully authorized Telnet port
[Homebridge] [3/21/2020, 12:35:50 PM] [Security System] Error: GET null failed: GET null failed: The "url" argument must be of type string. Received type object
    at /home/hoobs/.hoobs/node_modules/node-alarm-dot-com/index.js:114:17
    at processTicksAndRejections (internal/process/task_queues.js:94:5)
XXXXX
[Homebridge] [3/21/2020, 12:36:50 PM] [Security System] Error: GET null failed: GET null failed: The "url" argument must be of type string. Received type object
    at /home/hoobs/.hoobs/node_modules/node-alarm-dot-com/index.js:114:17
    at processTicksAndRejections (internal/process/task_queues.js:94:5)
XXXXX
[Homebridge] [3/21/2020, 12:37:50 PM] [Security System] Error: GET null failed: GET null failed: The "url" argument must be of type string. Received type object
    at /home/hoobs/.hoobs/node_modules/node-alarm-dot-com/index.js:114:17
    at processTicksAndRejections (internal/process/task_queues.js:94:5)
[Homebridge] [3/21/2020, 12:38:26 PM] Got SIGINT, shutting down service...
npm
 ERR! code EEXIST
npm ERR! path /home/hoobs/.hoobs/node_modules/.bin/nodeADC
npm
ERR! Refusing to delete /home/hoobs/.hoobs/node_modules/.bin/nodeADC: is outside /home/hoobs/.hoobs/node_modules/node-alarm-dot-com and not a link
npm ERR! File exists: /home/hoobs/.hoobs/node_modules/.bin/nodeADC
npm ERR! Remove the existing file and try again, or run npm
npm
 ERR! with --force to overwrite files recklessly.
npm ERR! A complete log of this run can be found in:
npm ERR!     /home/hoobs/.npm/_logs/2020-03-21T16_38_43_362Z-debug.log
XXXXX
[Homebridge] [3/21/2020, 12:47:16 PM] Got SIGINT, shutting down service...
npm
 ERR! code EEXIST
npm ERR! path /home/hoobs/.hoobs/node_modules/.bin/nodeADC
npm
 ERR! Refusing to delete /home/hoobs/.hoobs/node_modules/.bin/nodeADC: is outside /home/hoobs/.hoobs/node_modules/node-alarm-dot-com and not a link
npm ERR! File exists: /home/hoobs/.hoobs/node_modules/.bin/nodeADC
npm ERR! Remove the existing file and try again, or run npm
npm ERR! with --force to overwrite files recklessly.
npm ERR! A complete log of this run can be found in:
npm ERR!     /home/hoobs/.npm/_logs/2020-03-21T16_47_30_424Z-debug.log

Additional context Add any other context about the problem here.

mkellsy commented 4 years ago

Please post the logs. It has details for the errors. Also please use issue templates, it asks all the necessary questions to get us enough information to diagnose the issue.

Sinandgrin commented 4 years ago

Thank you mkellsy sorry for missing the template part. I updated my original post to include the template and it's content.

mkellsy commented 4 years ago

Awesome! We will take a look.

mkellsy commented 4 years ago

I looked over your logs and it looks like the issue is in the alarm dot com plugin code. This is either a problem with the code or you maybe are missing a "url" in your config.

I would review the config with the plugin's docs, or you may need to report a bug to the plugin developer.

Sinandgrin commented 4 years ago

Alright, I was able to resolve the issue myself by going through the terminal to manually remove the file that was not being allowed to be removed, "ERR! Refusing to delete /home/hoobs/.hoobs/node_modules/.bin/nodeADC: is outside /home/hoobs/.hoobs/node_modules/node-alarm-dot-com and not a link"

I then ran the update action through the UI and it completed successfully.

mkellsy commented 4 years ago

Thanks for that. That is actually a known NPM issue. I added this case to that issue for them.

Sinandgrin commented 4 years ago

Thanks for that. That is actually a known NPM issue. I added this case to that issue for them.

Ok thanks.