Open skyline2030 opened 2 years ago
Hi skyline2030, i will try to fork this project and implement the fixes from iobroker. Is there a link to the fixed version, which you have found?
Hi eckonator, that sounds good! I have the same problem like skyline2030. I think that should be the link ?! https://github.com/axelmohnen/fhem-landroid-s/issues
I hope it helps :-)
I also did some research on this yesterday. I suspect the fix is relatively simple. In the directory "fhem-landroid-s" is a file "package.json". In this file the following line should be changed to version 1.7.0:
"dependencies": { "iobroker.worx": "^1.0.0" }
According to my research, version 1.7.0 is the last patched version that might work. After that the ioBroker module was completely refactored, so the rest of the FHEM version won't work with it without any adjustments from version 2.x.x on. Unfortunately I can't test my solution yet, because my Node version is at 12 and for version 1.7.0 at least Node 16 is needed.
The solution could therefore look like this:
After that it could work again. Unfortunately I'm not at home this weekend to do further research. Maybe someone can test and report if my theory leads to success?
Hi eckonator, many thank's for your help. I just tried it as you described. With "npm install" there are unfortunately many errors and the installation fails. Unfortunately I don't really know anything about linux and can't help you further. I guess I'll have to wait then. npm v 6.14.17; node v 14.21.0 2022-11-05T15_57_22_520Z-debug.log
Hi SuMiHe, maybe there was a permission problem. Try „sudo npm install“. But i think i have to try by myself next week.
I tried that too, nearly same error. See the 2. log 2022-11-05T16_05_08_525Z-debug.log
Hm, try this:
cd /opt/PATH-TO-YOUR/fhem-landroid-s
sudo rm -rf node_modules
sudo npm install iobroker.worx@1.7.0
node LandroidSrv.js mower1
then I get Errors by "sudo npm install iobroker.worx@1.7.0". See the log. 2022-11-05T17_48_25_099Z-debug.log Unfortunately, my knowledge of Linux is not sufficient to interpret it :-(
Okay, here is a new try :-)
cd /opt/PATH-TO-YOUR/fhem-landroid-s
sudo rm -rf node_modules package-lock.json
sudo npm cache clean --force
sudo npm cache verify
sudo npm install iobroker.worx@1.7.0
node LandroidSrv.js mower1
nope, no luck again. Thank you for your help. I think I'll have to wait a bit until someone with more now how than I can help you. 2022-11-05T18_16_59_923Z-debug.log
Now it seems your machine do not trust the ssl certificat. Maybe this can help:
sudo npm config set strict-ssl false
And then run the lines from my previous post.
still the ssl error :-(
"npm ERR! request to https://registry.npmjs.org/iobroker.worx failed, reason: write EPROTO 1995606480:error:140943FC:SSL routines:ssl3_read_bytes:sslv3 alert bad record mac:../deps/openssl/openssl/ssl/record/rec_layer_s3.c:1544:SSL alert number 20 "
Thank's a lot, but it's ok for now. Sorry.
Okay, here is a new try :-)
cd /opt/PATH-TO-YOUR/fhem-landroid-s sudo rm -rf node_modules package-lock.json sudo npm cache clean --force sudo npm cache verify sudo npm install iobroker.worx@1.7.0 node LandroidSrv.js mower1
root@MYSERVER:/opt/landroid/fhem-landroid-s-master# node -v v16.18.1
root@MYSERVER:/opt/landroid/fhem-landroid-s-master# npm -v 8.19.3
root@MYSERVER:/opt/landroid/fhem-landroid-s-master# rm -rf node_modules package-lock.json root@MYSERVER:/opt/landroid/fhem-landroid-s-master# npm cache clean --force npm WARN using --force Recommended protections disabled. root@MYSERVER:/opt/landroid/fhem-landroid-s-master# npm cache verify Cache verified and compressed (~/.npm/_cacache) Content verified: 0 (0 bytes) Index entries: 0 Finished in 0.008s root@MYSERVER:/opt/landroid/fhem-landroid-s-master# npm install iobroker.worx@1.7.0 npm WARN deprecated har-validator@5.1.5: this library is no longer supported npm WARN deprecated circular-json@0.5.9: CircularJSON is in maintenance only, flatted is its successor. npm WARN deprecated request-promise@4.2.6: request-promise has been deprecated because it extends the now deprecated request package, s ee https://github.com/request/request/issues/3142 npm WARN deprecated uuid@3.4.0: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details. npm WARN deprecated request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
added 120 packages, and audited 121 packages in 10s
14 packages are looking for funding
run npm fund
for details
found 0 vulnerabilities root@MYSERVER:/opt/landroid/fhem-landroid-s-master# node LandroidSrv.js mower1 INFO: worx is selected
unfortunately I only get the output "INFO: worx is selected" and then the process terminates.
It’s not so easy that i thougt.
You can add in LandroidSrv.js, Line 452 this:
worxCloud.login();
After that it seems to go further, but it‘s never starting the mqtt
proccess.
I tried to get help from ioBroker.worx developers. Now, we have to wait…
Until 20 October 2022 all worked fine. We had a power outage for some time at that day. After restarting, I got the following error:
0|Landroid | DEBUG: Connect to worx.... 0|Landroid | ERROR: Could not Connect to Worx Server: StatusCodeError: 404 - {"message":"Not Found","code":"404.000"} 0|Landroid | Thu, 20 Oct 2022 19:28:45 GMT --> 'ERROR: StatusCodeError: 404 - {"message":"Not Found","code":"404.000"} 0|Landroid | INFO: worx is selected
This error comes over and over again. No connection to worx server takes place.
I searched for web entries describing the same error and found several people who had the same problem, but not with fhem but with IOBROKER. I found out: somebody supplied a fix for the IOBROKER version, but the fhem version still has NO FIX.
Is anybody able to adapt the fix to the fhem version of landroid.