Closed cocos-cz closed 2 years ago
Hey @cocos-cz,
which miniserver version do you use? Which nodejs version (node -v
)?
The error you have is emitted from the underlying node-lox-ws-api, not from node-red-contrib-loxone directly.
Hey,
its latest i believe - miniserver version 11.1.9.14.
Node version is v12.20.0
Ok, will try to to check on the node-lox-ws-api as well
I think you can't do much about node-lox-ws-api, as node-red-contrib-loxone defines the dependencies.
Currently we use our own forked version (https://github.com/codm/node-lox-ws-api) of it. We'll have a look into this...
Some extra info, when I dont have any node in the flow setup, in the log it keeps connecting to miniserver and being bumped the very same second.. at some point I get the error of too many attempts to connect..
on the bottom line, able to connect remotely to miniserver as well as loxberry connecting and working flawless (with same IP, port, user, pass setting...) - thats running on separate raspberry..
I am experiencing the same issue as @cocos-cz. Any update on this one?
Thanks
Sorry guys. I currently lent my miniserver to a friend as his got broken. He ordered a new one but it's not here, yet. So I can't test this at the moment...
Hi,
I'm facing exactly the same error as mentioned in post-comment https://github.com/codmpm/node-red-contrib-loxone/issues/58#issue-758525037
Thanks
Hello there,
I'm currently facing the same issue as mentioned above. Are there any updates on that issue yet?
Thanks a lot and best regards!
Hello,
same problem here, after changing password to Loxone in Android App, nodered is not able to connect:
Miniserver connection error: Socket Error: undefined ERR_STREAM_WRITE_AFTER_END (1006)
Even i created new user new pass, same issue, not able to connect :(
@codmdu any update please?
@codmdu is this project still alive?
Thanks
@killeriq What do you mean? This is an open-source project maintained mainly in our free-time.
well since Dec 7, 2020 no progress at all :(
You mentioned in Feb "Sorry guys. I currently lent my miniserver to a friend as his got broken. He ordered a new one but it's not here, yet. So I can't test this at the moment..."
Problem persist for all guys here seems like...
No clue what happend, was working for me all good, changed only Loxone password, updated also in Nodered and since then is not working...
there was no Loxone version update on my side and plugin in nodered wasnt updated also few months.
As result no data are going to Grafana :(
Understood. But then please don't use an open-source project which lives from the community and the free work in our spare time if you so heavily depend on it. Maybe contribute instead of nagging people to solve your problem.
Maybe re-read the license:
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
https://github.com/codmpm/node-red-contrib-loxone/blob/master/LICENSE
im not nagging...so don't feel offended ;)
Just asking if there is any progress or someone found some workaround , as there is no update for 5 months.
Maybe there is already some solution , but not mention in here.
If not - would be nice if you find time to have a look what might be the problem. Seems like more issue on Nodered side then on Loxone (if they didnt do any secret update on background)
@killeriq There is currently no progress, mainly because we are not able to reproduce this issue.
You said it stopped working after you changed the password, could it possible that youre using special chars (could you test it with a simple password?) Which versions are you using right now ? Could you share the logs of your loxone miniserver (after nodered crashed) ?
testing again...
When i wanted to start up "nodered doscker" i got:
21 Apr 14:14:57 - [info] Starting flows
21 Apr 14:14:57 - [info] Started flows
21 Apr 14:14:57 - [red] Uncaught Exception:
21 Apr 14:14:57 - TypeError: Cannot read property 'closeDescription' of undefined
at Connection.node $NODE_OPTIONS node_modules/node-red/red.js $FLOWS "--userDir" "/data"
npm ERR! Exit status 1
npm ERR! Failed at the node-red-docker@1.3.2 start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in: npm ERR! /data/.npm/_logs/2021-04-21T12_14_57_196Z-debug.log
When i stop the docker and start again it works for a while ...but then it end up with same error above
Created new user "nodered" in Loxone WebUI and set nodered as password
and still not able to connect :/
Log from nodereddocker
Versions: loxone FW 11.0.5.5 NodeRed 1.3.2 node-red-contrib-loxone 0.5.4 seems there is new update recently so i put 0.6.0
even after update to node-red-contrib-loxone 0.6.0
it get flooded , to it kills Nodered...and also high load on docker :(
Thanks @killeriq, good info.
Are you sure you talk about node-red-contrib-loxone when refering to 0.6.0
?
The current version is 0.10.11
: https://www.npmjs.com/package/node-red-contrib-loxone
Could you also give us the output of node -v
so that we know which nodeJS version you are using?
ah sry you are right is node-red-contrib-influxdb 0.6.0
correct node-red-contrib-loxone 0.10.11
I backedup all flows and removed all of them...still getting errors in log
maybe to remove the plugin / Palette might help
But i dont see remove option :(
rest is Empty...or remove whole Docker and set it up again?
Flooding the debug screen like this...
You have to delete the nodes in the editor first, thus "in use"....
I have some progress:
no clue how to remove them and from where
Probably with some upgrade of some nodered or Palette it got messed up ...and this might be issue also for everyone else need to probably manually set everything from scratch as importing put again some wrong values
again same errors, So i did again Fresh new install, installed only node-red-contrib-loxone 0.10.11 added server I hit Deploy only with this single Flow / node and again errors
no damn clue what is causing it :(((
With "GIT" command what is ment to be installed in Nodered UI - Palette? - could this be the problem? As of verison 0.10.4 please make sure, that your system has the git command installed, as the needed library are currently pulled from github. Otherwise you will get an undefined ls-remote-Error.
If you were missing git you can't install node-red-contrib-loxone as a dependency is installed via git.
@codmdu will have a look tomorrow.
i was able to install "node-red-contrib-loxone 0.10.11" , but just to be sure how do I check if is installed?
Or you meant without GIT part already installed i wouldnt be able to install "node-red-contrib-loxone 0.10.11? ?
@codmpm any results? Thanks
Found a workaround, if you have an user which is created in loxone config version I think before 10 and "important" you didn't change the password in the new version, you can get the script back working.
you can identify old accounts with old password in loxone config, as it's not showing the passwort strength indicator:
Account with old Password
new Passwords are visible with the password strength indicator:
I think, like @codmpm, that it isn't a problem with node-red-contrib-loxone script, the problem seems to be the node-lox-ws-api, maybe it doesn't get the right token back from miniserver. As I try to authenticate with an new created password or account, the loxone monitor writes 401 Unauthorized.
so if you have an account with an old password before Lox Config 10, you can get the function back.
Thanks for the tip, but unfortunately i dont have any "old acccounts" :(
@macabros999 Thank you for sharing the information with us. Sadly i can't reproduce the issue. I created a new user (which shows the password strength indicator) on the loxone miniserver, but i'm still able to connect to the server through the loxone node.
@codmdu on which version of Loxone Config / Miniserver FW are you?
Miniserver: 12.0.2.24 Loxone Config: 12.02.24
ok, i'm doing backup and will do upgrade from 11.0.5.5 to 12.02.24 to see if it helps. Drives me nuts that "professional" loxone updates, never knows what stop to work
Seems like they messed up something in Loxone, after they introduced additional Groups / Rights
Here are my test results (I can creating users in LoxConfig 12.0.2.24) , In the end i think upgrade wasn't necessary to do Soon as i added multiple accounts with different right and one of them wasnt working it messed up all (even working) accounts and Nodered was throwing errors. When i removed NON working account, all was good again.
Now even im able to connect - only what get sent "time to time" in "stream all" node is this. everything else is not sending anything :( Strange...any clue what might be issue now?
Even after few days, no data are going through. I was comparing how is the membership and rights - Soon as i Add user into "Everyone" user group...it start to throw errors again Also not able to connect :(
Which groups / rights are you using please? Seems like Loxone did huge mess again :(
Finally was able to get it working, really pain in the ...
Working: Tester1 - "Full Access" - - Connected get structure , getting all data
NOT Working Tester - "Admins" - Connected get structure , but NOT getting any data
admin - "Admins","Full Acccess" - NOT Connected, NO structure , NOT getting any data
nodered - "User" - Connected get structure , but NOT getting any data
Finally was able to get it working, really pain in the ...
Working: Tester1 - "Full Access" - - Connected get structure , getting all data
NOT Working Tester - "Admins" - Connected get structure , but NOT getting any data
admin - "Admins","Full Acccess" - NOT Connected, NO structure , NOT getting any data
nodered - "User" - Connected get structure , but NOT getting any data
- Also tried to give all rights and still - Connected get structure , but NOT getting any data
- Seems like all Rooms / Block which need to be monitored needs to be added manually then it might work for the specific room / Block
Having exactly the same problem.
Do you think you can set out exactly how to implement a working configuration in Loxone?
I have the same issue. I did some debugging and looks like a problem in encrypted communication, so in node-lox-ws-ap. I was able to reproduce the problem with a simple script:
const node_lox_ws_api = require("node_lox_ws_api");
let client = new node_lox_ws_api( '192.168.88.30:80', 'nodered', 'password', false, 'Token-Enc', true );
client.connect()
Miniserver started to drop all connections after a couple of tries.
I tried steps that @killeriq described without any success. From the code, it looks like the first error message is sent during keys exchange, so even before the user name is sent to miniserver. It is weird :)
Hey @VelkyVenik, thanks for the debugging. Maybe @alladdin can have a look at this?
same for me - but just since the last Config changes - no user/permissions - from today. It was working pretty good.
guys try to use the rules i posted before, spend few days with that until i figure it out....you need to give to new account additional rights
what additional rights you have? I gave it rights to literally everything and not working. I run Lox. 12.2.12.1. I see the structure, but after deploy it crashes
I have the same situation as @martindudek I use: Loxone ver. 12.2.12.01, node-red-contrib-loxone ver. 0.10.11, also, I created a separate user with full rights permission and the most complex password. Need your help
Please test this issue with 0.10.12
which was released right now.
Thanks to @arsiesis, @pevecyan and @umarovt for having a look into node-lox-ws-api which should relate to this.
Leaving open till marked as solved :+1:
hi @codmpm
for me, the fix solves the problem. I have tested this on a new-gen. Miniserver Go with version 12.2.12.1.
Hi,
I am trying to get up and running node-red with my loxone miniserver, but the moment I set the miniserver details, nodered starts crashing..
I am getting this error: TypeError: Cannot read property 'closeDescription' of undefined at Connection. (/home/pi/.node-red/node_modules/node-lox-ws-api/lib/Connection.js:64:62)
at WebSocketClient.emit (events.js:314:20)
at ClientRequest.handleRequestError (/home/pi/.node-red/node_modules/websocket/lib/WebSocketClient.js:227:14)
at ClientRequest.emit (events.js:314:20)
at Socket.socketErrorListener (_http_client.js:427:9)
at Socket.emit (events.js:314:20)
at emitErrorNT (internal/streams/destroy.js:92:8)
at emitErrorAndCloseNT (internal/streams/destroy.js:60:3)
at processTicksAndRejections (internal/process/task_queues.js:84:21)
nodered.service: Main process exited, code=exited, status=1/FAILURE
nodered.service: Failed with result 'exit-code'.
Thats when I try to setup "online" node to test the connection.. When I delete everything from the flow, i am getting: WebSocket error: Socket Error: undefined ERR_STREAM_WRITE_AFTER_END 1006
and after some time crash again... seems like I am not able to connect to the miniserver.. anybody out there, who could help, how to make stable login into miniserver?
R4pi 8GB, on raspberry Pi OS, all updates done.
Thanks