dgreif / ring

Unofficial packages for Ring Doorbells, Cameras, Alarm System, and Smart Lighting
MIT License
1.18k stars 158 forks source link

Ring plugin does not appear to install correctly #1353

Closed mbsneider closed 8 months ago

mbsneider commented 8 months ago

Is there an existing issue for this?

Describe The Bug

I'm attempting to install the Ring plugin on a Mac running HomeBridge. I'm receiving this error and I'm unable to work around it. ERROR LOADING PLUGIN homebridge-ring: [11/5/2023, 8:44:34 AM] Error: Cannot find module '/usr/local/lib/node_modules/homebridge-ring/node_modules/@homebridge/camera-utils/lib/index.js'. Please verify that the package.json has a valid "main" entry at tryPackage (node:internal/modules/cjs/loader:438:19) at Function.Module._findPath (node:internal/modules/cjs/loader:680:18) at Function.Module._resolveFilename (node:internal/modules/cjs/loader:1063:27) at Function.Module._load (node:internal/modules/cjs/loader:922:27) at Module.require (node:internal/modules/cjs/loader:1143:19) at require (node:internal/modules/cjs/helpers:119:18) at Object. (/usr/local/lib/node_modules/homebridge-ring/node_modules/ring-client-api/lib/streaming/streaming-session.js:5:24) at Module._compile (node:internal/modules/cjs/loader:1256:14) at Object.Module._extensions..js (node:internal/modules/cjs/loader:1310:10) at Module.load (node:internal/modules/cjs/loader:1119:32)

Other plugins are working correctly. Any suggestins?

To Reproduce

Occurs each time I install the plugin or restart HomeBridge.

Expected behavior

Plugin doesn't run. Other plugins run without issue.

Relevant log output

No response

Screenshots

No response

Homebridge Ring Config

Just the default platform and token.

Additional context

No response

OS

MacOS 10.15

Node.js Version

v18.18.2

NPM Version

v9.8.1

Homebridge/HOOBs Version

homebridge-config-ui-x v4.52.1

Homebridge Ring Plugin Version

v12.0.1

Operating System

macOS

tsightler commented 8 months ago

I believe this is caused by upstream @homebridge/camera-utils package (the message pretty much says as much). They pushed a new version yesterday, but as far as I can see it's completely missing the actual /lib folder thus there really is no index.js in the package exactly as the error message says. I can reproduce the same issue on my Linux system when it install 2.2.1.

Temporary workaround would be to manually install 2.2.0 version of package by switching to the homebridge-ring directory and running:

npm install @homebridge/camera-utils@2.2.0

mbsneider commented 8 months ago

Awesome. Your workaround fixed it! I’m not using cameras anyway, so this helped perfectly.On Nov 5, 2023, at 10:26 AM, tsightler @.> wrote: I believe this is caused by upstream @homebridge/camera-utils package (the message pretty much says as much). They pushed a new version yesterday, but as far as I can see it's completely missing the actual /lib folder thus there really is no index.js in the package exactly as the error message says. I can reproduce the same issue on my Linux system when it install 2.2.1. Temporary workaround would be to manually install 2.2.0 version of package by switching to the homebridge-ring directory and running: npm install @@.

—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you authored the thread.Message ID: @.***>

donavanbecker commented 8 months ago

v2.2.4 resolves this.

image

tsightler commented 8 months ago

Closing as upstream issues has been corrected.