homebridge-harmonyhub icon indicating copy to clipboard operation
homebridge-harmonyhub copied to clipboard

Error: MAX_CLIENTS=6

Open mark82436 opened this issue 6 years ago • 27 comments

i have some errors with version homebridge-harmonyhub v0.3.0-alpha.2 homebridge crashes some times

my config are 3 hubs on the network homebridge 0.4.38

Logfile Uncaught exception error: { Error: MAX_CLIENTS=6 at Connection.onStanza (/usr/local/lib/node_modules/homebridge-harmonyhub/node_modules/node-xmpp-core/lib/Connection.js:355:17) at StreamParser.<anonymous> (/usr/local/lib/node_modules/homebridge-harmonyhub/node_modules/node-xmpp-core/lib/Connection.js:226:10) at emitOne (events.js:116:13) at StreamParser.emit (events.js:211:7) at SaxLtx.<anonymous> (/usr/local/lib/node_modules/homebridge-harmonyhub/node_modules/node-xmpp-core/lib/StreamParser.js:58:14) at emitOne (events.js:116:13) at SaxLtx.emit (events.js:211:7) at SaxLtx._handleTagOpening (/usr/local/lib/node_modules/homebridge-harmonyhub/node_modules/ltx/lib/parsers/ltx.js:31:18) at SaxLtx.write (/usr/local/lib/node_modules/homebridge-harmonyhub/node_modules/ltx/lib/parsers/ltx.js:105:26) at StreamParser.write (/usr/local/lib/node_modules/homebridge-harmonyhub/node_modules/node-xmpp-core/lib/StreamParser.js:123:17) at Connection.onData (/usr/local/lib/node_modules/homebridge-harmonyhub/node_modules/node-xmpp-core/lib/Connection.js:305:17) at emitOne (events.js:121:20) at Socket.emit (events.js:211:7) at addChunk (_stream_readable.js:263:12) at readableAddChunk (_stream_readable.js:250:11) at Socket.Readable.push (_stream_readable.js:208:10) at TCP.onread (net.js:594:20) stanza: Stanza { name: 'stream:error', parent: null, children: [ [Object], [Object] ], attrs: { 'xmlns:stream': 'http://etherx.jabber.org/streams' } } }

mark82436 avatar Mar 12 '18 13:03 mark82436

I have the same issue (but I have just 1 harmony hub)

mdpp avatar Mar 25 '18 12:03 mdpp

same Error --> 2 harmony hubs

m0rph2k avatar Apr 11 '18 12:04 m0rph2k

I have the same error, 2 hubs.

jabz10 avatar Apr 15 '18 01:04 jabz10

Same error (sporadic), 1 hub.

dado3212 avatar Apr 16 '18 04:04 dado3212

Same issue here. Happens after a few mins to an hour. The plugin is unusable unfortunately. 1 hub.

Squuiid avatar Apr 27 '18 09:04 Squuiid

Same error here with 2 hubs and a lot of crashes per day... seems that this problem will never be solved! :(

MikeDeltaHH avatar May 05 '18 07:05 MikeDeltaHH

The latest version of homebridge and the harmony plugin ran fine for weeks but recently it started crashing again with this error message. I only have 1 hub and am really wondering what's going on here. It seems there's not much response from the developer so I'm wondering whether or not to abandon the idea completely.

gvansteelant avatar May 07 '18 11:05 gvansteelant

having this issue as well

shaneakus avatar May 28 '18 15:05 shaneakus

Just installed homebridge-harmonyhub, and ran into this on the first day.

Error: MAX_CLIENTS=6                                                                                                                                                  
    at Connection.onStanza (/usr/local/lib/node_modules/homebridge-harmonyhub/node_modules/node-xmpp-core/lib/Connection.js:355:17)                                   
    at StreamParser.<anonymous> (/usr/local/lib/node_modules/homebridge-harmonyhub/node_modules/node-xmpp-core/lib/Connection.js:226:10)                              
    at StreamParser.emit (events.js:180:13)                                                                                                                           
    at SaxLtx.<anonymous> (/usr/local/lib/node_modules/homebridge-harmonyhub/node_modules/node-xmpp-core/lib/StreamParser.js:58:14)                                   
    at SaxLtx.emit (events.js:180:13)                                                                                                                                 
    at SaxLtx._handleTagOpening (/usr/local/lib/node_modules/homebridge-harmonyhub/node_modules/ltx/lib/parsers/ltx.js:31:18)                                         
    at SaxLtx.write (/usr/local/lib/node_modules/homebridge-harmonyhub/node_modules/ltx/lib/parsers/ltx.js:105:26)                                                    
    at StreamParser.write (/usr/local/lib/node_modules/homebridge-harmonyhub/node_modules/node-xmpp-core/lib/StreamParser.js:123:17)                                  
    at Connection.onData (/usr/local/lib/node_modules/homebridge-harmonyhub/node_modules/node-xmpp-core/lib/Connection.js:305:17)                                     
    at Socket.emit (events.js:185:15)                                                                                                                                 
    at addChunk (_stream_readable.js:269:12)                                                                                                                          
    at readableAddChunk (_stream_readable.js:256:11)                                                                                                                  
    at Socket.Readable.push (_stream_readable.js:213:10)                                                                                                              
    at TCP.onread (net.js:578:20)

CharlesWiltgen avatar Jun 05 '18 00:06 CharlesWiltgen

same error, one hub. at Connection.onStanza (/usr/local/lib/node_modules/homebridge-harmonyhub/node_modules/node-xmpp-core/lib/Connection.js:355:17) Error: MAX_CLIENTS=6

eshaka avatar Jun 10 '18 08:06 eshaka

Honestly, this project should be pulled. So many people are wasting their time on it. It does NOT work unfortunately.

Squuiid avatar Jun 10 '18 10:06 Squuiid

It does SOMETIMES work.

dado3212 avatar Jun 13 '18 00:06 dado3212

Having the same issue 2 hubs

filoor avatar Jun 14 '18 21:06 filoor

I think I may have a solution for you guys, see my comment here: https://github.com/KraigM/homebridge-harmonyhub/issues/137#issuecomment-414474654

oetelaar24 avatar Aug 20 '18 21:08 oetelaar24

As my error starts off slightly differently I've added below. I've removed the plugin for now. I might create a special Homebridge instance so that only that instance is affected by the failures.

/usr/lib/node_modules/homebridge-harmonyhub/node_modules/node-xmpp-core/lib/Connection.js:355 var error = new Error('' + getAllText(stanza)) ^ Error: MAX_CLIENTS=6 at Connection.onStanza (/usr/lib/node_modules/homebridge-harmonyhub/node_modules/node-xmpp-core/lib/Connection.js:355:17)

lespatots avatar Sep 26 '18 07:09 lespatots

Folks, Harmony hub is no longer needed with the release of Apple Siri shortcuts. I now control my Harmony Hub with Siri Shortcuts and got rid of HomeBridge. See here for how: https://www.macstories.net/ios/how-to-trigger-ifttt-applets-with-ios-12s-new-shortcuts-app-and-siri/ It works flawlessly every single time. Highly recommend.

Squuiid avatar Sep 26 '18 13:09 Squuiid

Has anyone checked recently if this error is still occurring? I see changes have been made to https://github.com/swissmanu/harmonyhubjs-client to address this issue.

pponce avatar Dec 10 '18 21:12 pponce

I'm giving it a go with 0.3.0-alpha.2.
I actually had to edit the package.json file that was installed with 0.3.0-alpha2 and changed the value version for harmonyhubjs-client to "^1.1.6" within the file. It had some other value that caused it not to use the latest version. Then I ran npm update in the existing directory where it was installed to get it to use the lastest harmonyhubjs-client version.

I'll report back how things go after a good week of using it.

pponce avatar Dec 11 '18 16:12 pponce

Things appeared to be working pretty well. Now my only problem is that Harmony removed the local API's in their most recent firmware. So now it does not work at all...... :(

pponce avatar Dec 18 '18 21:12 pponce

@pponce Just out of interest- I assume you've enabled the beta functionality now - and can you comment if your patching fixed the maxclients issue?

Pensive avatar Feb 06 '19 09:02 Pensive

Yeah I ran without issue for a long time using 0.3.0-alpha2 with harmonyhubjs-client 1.1.6. Didn’t have any max client issues that I could detect.

I recently moved to one of the websocket implementations that is using airborne04’s js client. Not sure if Logitech is going to favor ws or xmpp going forward. But it seems there are some great working options now for homebridge.

pponce avatar Feb 06 '19 16:02 pponce

I’m having trouble with websockets - tried nicos and materiks.

Works fine from Siri or the home app but both have problem when I link them via a hue switch.

Works fine at first but come down in the morning and materiks just doesn’t work and pings up a websocket not open error, nicos works but it takes 20 or 30 seconds.

For some reason the sockets go to sleep and they are not properly woken by a 3rd party HomeKit switch.

The hue switch clicks are reaching HomeKit because the icon shakes. So I’m thinking of resurrecting this one and making it 12.2 compliant.

Local apis will always be superior to web based ones.

Pensive avatar Feb 06 '19 19:02 Pensive

Have you tried materiks using airborne04’s xmpp client as a dependency? I think they can be swapped out. Airborne04 said the websocket version of the client was a drop in replacement for the xmpp version.

But as for this plugin. I don’t use a hue switch to control my activities but I didn’t have any issues with the 0.3.0 alpha2 with the latest harmonyhubjs-client.

pponce avatar Feb 06 '19 22:02 pponce

Ooooh that would be a quick and easy fix! I’ll give it a go!!!

Pensive avatar Feb 06 '19 22:02 Pensive

@Pensive I know you said you were moving to use XMPP. Just wanted to let you know that Nico's websocket implementation i believe fixed the websockets not being open issue you experienced.

pponce avatar Feb 19 '19 17:02 pponce

Yes , and by the way the websocket api is a local one :)

Sent with GitHawk

nicoduj avatar Feb 19 '19 18:02 nicoduj

Interesting - thank you for the headsup! I haven’t had a chance to play with it so I’m still running websockets at the mo - I’ll try updating :)

I thought a huge part of the hoohah when they shut down the local API was that the websockets implementation went out to the cloud server?

I’ll look in greater detail

Pensive avatar Feb 19 '19 18:02 Pensive