Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SyntaxError: init() not yet called #211

Closed
bgeveritt opened this issue Jan 7, 2024 · 2 comments
Closed

SyntaxError: init() not yet called #211

bgeveritt opened this issue Jan 7, 2024 · 2 comments
Labels

Comments

@bgeveritt
Copy link

I'm trying to add three Sonos products (1 Play:1 speaker, 1 Playbase, and 1 amp.) The Play:1 speaker is added successfully, but I get the following error on the other two. I should note that the two failing products WERE in HomeKit previously, but I removed them. The Play:1 speaker was never added to HomeKit before installing this plugin, and it works fine.

[1/7/2024, 4:49:54 PM] [Sonos] RINCON_347E5C0F60F301400 [192.168.50.125]: request 1: GET /xml/device_description.xml
[1/7/2024, 4:49:54 PM] [Sonos] warning: RINCON_347E5C0F60F301400 [192.168.50.125]: request 1: connect ETIMEDOUT 192.168.50.125:1400
[1/7/2024, 4:49:54 PM] [Sonos] RINCON_B8E93749402401400 [192.168.50.51]: request 1: GET /xml/device_description.xml
[1/7/2024, 4:49:54 PM] [Sonos] warning: RINCON_B8E93749402401400 [192.168.50.51]: request 1: connect ETIMEDOUT 192.168.50.51:1400
[1/7/2024, 4:49:54 PM] [Sonos] found 1 households
[1/7/2024, 4:49:54 PM] [Sonos] Sonos_rKWiXdyaYIji4AHic1mQ23CT3E: RINCON_B8E937525C8401400 [192.168.50.21]: associated S2 zoneplayer
[1/7/2024, 4:49:54 PM] [Sonos] Sonos_rKWiXdyaYIji4AHic1mQ23CT3E: found 3 S2 zone players in 3 zones
[1/7/2024, 4:49:54 PM] [Sonos] ├─ Den
[1/7/2024, 4:49:54 PM] [Sonos] error: RINCON_347E5C0F60F301400: [192.168.50.125]: SyntaxError: init() not yet called
    at ZpClient.checkInit (C:\Users\Bailey\AppData\Roaming\npm\node_modules\homebridge-zp\lib\ZpClient.js:421:13)
    at ZpClient.get audioIn [as audioIn] (C:\Users\Bailey\AppData\Roaming\npm\node_modules\homebridge-zp\lib\ZpClient.js:568:10)
    at ZpPlatform.logTopology (C:\Users\Bailey\AppData\Roaming\npm\node_modules\homebridge-zp\lib\ZpPlatform.js:445:28)
    at processTicksAndRejections (node:internal/process/task_queues:95:5)
[1/7/2024, 4:49:54 PM] [Sonos] ├─ Kitchen
[1/7/2024, 4:49:54 PM] [Sonos] │  └─ RINCON_B8E937525C8401400 [Kitchen]: Sonos Play:1 (S1) (master)
[1/7/2024, 4:49:54 PM] [Sonos] └─ Living Room
[1/7/2024, 4:49:54 PM] [Sonos] error: RINCON_B8E93749402401400: [192.168.50.51]: SyntaxError: init() not yet called
    at ZpClient.checkInit (C:\Users\Bailey\AppData\Roaming\npm\node_modules\homebridge-zp\lib\ZpClient.js:421:13)
    at ZpClient.get audioIn [as audioIn] (C:\Users\Bailey\AppData\Roaming\npm\node_modules\homebridge-zp\lib\ZpClient.js:568:10)
    at ZpPlatform.logTopology (C:\Users\Bailey\AppData\Roaming\npm\node_modules\homebridge-zp\lib\ZpPlatform.js:445:28)
    at processTicksAndRejections (node:internal/process/task_queues:95:5)
[1/7/2024, 4:49:54 PM] [Sonos] error: RINCON_347E5C0F60F301400: [192.168.50.125]: SyntaxError: init() not yet called
    at ZpClient.checkInit (C:\Users\Bailey\AppData\Roaming\npm\node_modules\homebridge-zp\lib\ZpClient.js:421:13)
    at ZpClient.get modelName [as modelName] (C:\Users\Bailey\AppData\Roaming\npm\node_modules\homebridge-zp\lib\ZpClient.js:719:10)
    at ZpPlatform.logTopology (C:\Users\Bailey\AppData\Roaming\npm\node_modules\homebridge-zp\lib\ZpPlatform.js:463:30)
    at processTicksAndRejections (node:internal/process/task_queues:95:5)
[1/7/2024, 4:49:54 PM] [Sonos] error: RINCON_B8E93749402401400: [192.168.50.51]: SyntaxError: init() not yet called
    at ZpClient.checkInit (C:\Users\Bailey\AppData\Roaming\npm\node_modules\homebridge-zp\lib\ZpClient.js:421:13)
    at ZpClient.get modelName [as modelName] (C:\Users\Bailey\AppData\Roaming\npm\node_modules\homebridge-zp\lib\ZpClient.js:719:10)
    at ZpPlatform.logTopology (C:\Users\Bailey\AppData\Roaming\npm\node_modules\homebridge-zp\lib\ZpPlatform.js:463:30)
    at processTicksAndRejections (node:internal/process/task_queues:95:5)

Debug Files

@ebaauw ebaauw added the bug label Jan 8, 2024
@bgeveritt
Copy link
Author

Very odd, randomly started to work last night:

[1/9/2024, 10:45:05 PM] [Sonos] found 1 households
[1/9/2024, 10:45:05 PM] [Sonos] error: SyntaxError: RINCON_347E5C0F60F301400 not in Sonos_rKWiXdyaYIji4AHic1mQ23CT3E
    at ZpHousehold.setAssociated (C:\Users\Bailey\AppData\Roaming\npm\node_modules\homebridge-zp\lib\ZpHousehold.js:28:13)
    at ZpPlatform.logTopology (C:\Users\Bailey\AppData\Roaming\npm\node_modules\homebridge-zp\lib\ZpPlatform.js:404:27)
    at ZpPlatform.createZpClient (C:\Users\Bailey\AppData\Roaming\npm\node_modules\homebridge-zp\lib\ZpPlatform.js:341:12)
    at processTicksAndRejections (node:internal/process/task_queues:95:5)
    at ZpPlatform.handleMdnsMessage (C:\Users\Bailey\AppData\Roaming\npm\node_modules\homebridge-zp\lib\ZpPlatform.js:187:24)
[1/9/2024, 10:45:05 PM] [Sonos] Sonos_rKWiXdyaYIji4AHic1mQ23CT3E: found 3 S2 zone players in 3 zones
[1/9/2024, 10:45:05 PM] [Sonos] ├─ Kitchen
[1/9/2024, 10:45:05 PM] [Sonos] │  └─ RINCON_B8E937525C8401400 [Kitchen]: Sonos Play:1 (S1) (master)
[1/9/2024, 10:45:05 PM] [Sonos] ├─ Living Room
[1/9/2024, 10:45:05 PM] [Sonos] │  └─ RINCON_B8E93749402401400 [Living Room]: Sonos Playbase (S11) (master, airPlay, tvIn)
[1/9/2024, 10:45:05 PM] [Sonos] └─ Sonos
[1/9/2024, 10:45:05 PM] [Sonos]    └─ RINCON_347E5C0F60F301400 [Sonos]: Sonos Amp (S16) (master, airPlay, audioIn, tvIn)

@ebaauw
Copy link
Owner

ebaauw commented Jan 10, 2024

Homebridge ZP doesn’t always handle correctly disappearing and re-appearing speakers, see also #190. It looks like it doesn’t recover from the timeouts getting the description XML files from these two speakers. Does the problem persist after restarting Homebridge ZP?

@ebaauw ebaauw closed this as completed Feb 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants