empierre / MyDomoAtHome

MyDomoAtHome - REST interface for ImperoHome with Domoticz (ISS)
http://domoticz.com/wiki/ImperiHome
GNU General Public License v3.0
32 stars 22 forks source link

MyDomoAtHome and domoticz v3.9501 - V3.9528 (latest to date) no connection to devices #169

Closed rwaaren closed 5 years ago

rwaaren commented 6 years ago

since domoticz beta V3.9501 mydomoticz do not return anything from domoticz when asked using domoticz_ip:3002/devices

It does react to domoticz_ip:3002 with the standard screen

See http://www.domoticz.com/forum/viewtopic.php?f=6&t=23579 for more details and what already have been investigated Also reported as a domoticz issue ( https://github.com/domoticz/domoticz/issues/2434 )

empierre commented 6 years ago

Hello,

Thanks for pointing that, I hope we'll know if the change from domoticz is a bug or wanted before changing and impacting everyone.

empierre commented 6 years ago

@rwaaren I've upgraded to 9527, will try to see what's going on as soon as I can

empierre commented 6 years ago

ok domoticz gives that now: "LevelActions" : "aHR0cCUzQS8vJTdDJTdDJTdDJTdDJTdDJTdDJTdDJTdDJTdDJTdDJTdDJTdDJTdDfHx8fHx8fHx8fA==", "LevelInt" : 100, "LevelNames" : "T2ZmfExldmVsMXxMZXZlbDJ8TGV2ZWwzfC4uLi58LS0tLXxqb3VyIGRlIGwnYW58ZsOqdGUgZHUgdHJhdmFpbHx0MXx0Mnx0Mw==",

that cannot be exploited for I read those values to have the leels

empierre commented 6 years ago

device that has changed: "SubType" : "Selector Switch", "SwitchType" : "Selector", "SwitchTypeVal" : 18, "Type" : "Light/Switch",

empierre commented 6 years ago

ok some fields (which) are base64 encoded, need to detect that to ensure backward compatibility : https://www.npmjs.com/package/is-base64 then decode it: https://stackoverflow.com/questions/14573001/nodejs-how-to-decode-base64-encoded-string-back-to-binary

vulbas commented 6 years ago

hello empierre. do I have to install is-base64? mdah still does not work. what changed ?

hello empierre. il faut installer is-base64 ? mdah ne fonctionne toujours pas. qu'est ce qui a changé ?

empierre commented 6 years ago

Hello,

These are notes for me to work on it...

vulbas commented 6 years ago

ho ok, thanks for your job 👍

empierre commented 6 years ago

will generate a package later

vulbas commented 6 years ago

nous sommes nombreux à attendre

many of us wait

jonferreira commented 6 years ago

@empierre I'm having this same issue with domo v4.9732 :(

jonferreira commented 6 years ago

journalctl -f shows

Jun 30 11:26:59 raspberrypi sudo[1204]: pi : TTY=pts/1 ; PWD=/home/pi ; USER=root ; COMMAND=/bin/journalctl -f Jun 30 11:26:59 raspberrypi sudo[1204]: pam_unix(sudo:session): session opened for user root by pi(uid=0) Jun 30 11:27:03 raspberrypi MDAH[427]: { MaxDimLevel: null, Jun 30 11:27:03 raspberrypi MDAH[427]: Action: null, Jun 30 11:27:03 raspberrypi MDAH[427]: graph: null, Jun 30 11:27:03 raspberrypi MDAH[427]: Selector: [ 'T2ZmfEhvbWV8QXdheXxIb2xpZGF5c3xOaWdodA==' ] } Jun 30 11:27:03 raspberrypi MDAH[427]: 1 Jun 30 11:27:03 raspberrypi MDAH[427]: /usr/share/mydomoathome/app/mdah.js:433 Jun 30 11:27:03 raspberrypi MDAH[427]: params.push({"key": "Value", "value": ret[lvl].toString()}); Jun 30 11:27:03 raspberrypi MDAH[427]: ^ Jun 30 11:27:03 raspberrypi MDAH[427]: TypeError: Cannot read property 'toString' of undefined Jun 30 11:27:03 raspberrypi MDAH[427]: at DevMultiSwitch (/usr/share/mydomoathome/app/mdah.js:433:51) Jun 30 11:27:03 raspberrypi MDAH[427]: at Request._callback (/usr/share/mydomoathome/app/mdah.js:2458:45) Jun 30 11:27:03 raspberrypi MDAH[427]: at Request.self.callback (/usr/share/mydomoathome/app/node_modules/request/request.js:200:22) Jun 30 11:27:03 raspberrypi MDAH[427]: at emitTwo (events.js:125:13) Jun 30 11:27:03 raspberrypi MDAH[427]: at Request.emit (events.js:213:7) Jun 30 11:27:03 raspberrypi MDAH[427]: at Request. (/usr/share/mydomoathome/app/node_modules/request/request.js:1067:10) Jun 30 11:27:03 raspberrypi MDAH[427]: at emitOne (events.js:120:20) Jun 30 11:27:03 raspberrypi MDAH[427]: at Request.emit (events.js:210:7) Jun 30 11:27:03 raspberrypi MDAH[427]: at IncomingMessage. (/usr/share/mydomoathome/app/node_modules/request/request.js:988:12) Jun 30 11:27:03 raspberrypi MDAH[427]: at emitNone (events.js:110:20) Jun 30 11:27:03 raspberrypi MDAH[427]: error: Forever detected script exited with code: 1 Jun 30 11:27:03 raspberrypi MDAH[427]: error: Script restart attempt #9

jonferreira commented 6 years ago

I take that back, turns out I was running 2.36 even though it previously said I was running the "latest"...all good now :)