ioBroker.vis icon indicating copy to clipboard operation
ioBroker.vis copied to clipboard

binding formel hat umlaut problem

Open liv-in-sky opened this issue 2 years ago • 9 comments

ist im 2 definierten dp ein umlaut (üöä) enthalten kommt ein fehler im browser log und die formel funktioniert nicht

forum: https://forum.iobroker.net/post/705384

beispiel fehler (biomüll): {dp2:trashschedule.0.type.restmüll.daysLeft; dp1:trashschedule.0.type.biomüll.daysLeft; dp2 == 13 || dp1==8 ? 0 : 100 } beispiel ohne fehler (papierTonne): {dp2:trashschedule.0.type.restmüll.daysLeft; dp1:trashschedule.0.type.papierTonne.daysLeft; dp2 == 13 || dp1==8 ? 0 : 100 }

liv-in-sky avatar Nov 17 '21 12:11 liv-in-sky

Die Formel funktioniert auch nicht, wenn im zweiten dp eine # enthalten ist. Forum: https://forum.iobroker.net/topic/49473/vis-binding-und-verkn%C3%BCpfung-mehrerer-variablen/17

Beispiel: {v1:e3dc-rscp.0.BAT.BAT#0.DCB#0.DCB_CELL_TEMPERATURE.06;v2:e3dc-rscp.0.BAT.BAT#0.DCB#0.DCB_CELL_TEMPERATURE.07;v1-v2}

ArnoD15 avatar Nov 20 '21 09:11 ArnoD15

Kann ich bestätigen: Sobald mehr als ein DP im Binding einer Variablen zugewiesen und verarbeitet wird (hier "secondDP") und diese weiteren DPs Umlaute enthalten, z.B. {firstDP:0_userdata.0.UmlautÄ; secondDP:0_userdata.0.UmlautÖ; firstDP=="true" && secondDP=="true"} kommt es bei der Code-Ausführung im anzeigenden Webbrowser auf der Console zum Fehler ReferenceError: secondDP is not defined und das gesamte Binding ist nicht funktional. Wird nur ein DP mit Umlaut im Binding verwendet, funktioniert es, z.B. {firstDP:0_userdata.0.UmlautÄ; firstDP=="true"}

@GermanBluefox

th4git avatar Jan 23 '22 09:01 th4git

Wäre klasse, wenn der eingangs beschriebene Binding-Bug mit Umlauten in State-IDs bei nächster Gelegenheit beseitigt werden könnte - damit man das echt gute VIS (danke an die Engagierten) richtig ausreizen kann. :-) @GermanBluefox

th4git avatar Feb 15 '22 19:02 th4git

Problem besteht auch noch mit Adapter v1.4.12.

Fehlermeldungen dazu in der Webbrowser-Console (Chrome):

vis.js:2594 Error in eval[value]: {firstDP:0_userdata.0.UmlautÄ; secondDP:0_userdata.0.UmlautÖ; firstDP=="true" && secondDP=="true"}
formatBinding @ vis.js:2594
updateStates @ vis.js:3181
(anonymous) @ vis.js:2976
(anonymous) @ conn.js:801
r.onack @ socket.io.js:8
r.onpacket @ socket.io.js:8
(anonymous) @ socket.io.js:8
r.emit @ socket.io.js:6
r.ondecoded @ socket.io.js:6
(anonymous) @ socket.io.js:8
r.emit @ socket.io.js:6
a.add @ socket.io.js:6
r.ondata @ socket.io.js:6
(anonymous) @ socket.io.js:8
r.emit @ socket.io.js:6
r.onPacket @ socket.io.js:6
(anonymous) @ socket.io.js:6
r.emit @ socket.io.js:6
r.onPacket @ socket.io.js:7
r.onData @ socket.io.js:7
ws.onmessage @ socket.io.js:8
vis.js:2595 Error in eval[script]: var firstDP = "false";return  secondDP:0_userdata.0.UmlautÖ;
formatBinding @ vis.js:2595
updateStates @ vis.js:3181
(anonymous) @ vis.js:2976
(anonymous) @ conn.js:801
r.onack @ socket.io.js:8
r.onpacket @ socket.io.js:8
(anonymous) @ socket.io.js:8
r.emit @ socket.io.js:6
r.ondecoded @ socket.io.js:6
(anonymous) @ socket.io.js:8
r.emit @ socket.io.js:6
a.add @ socket.io.js:6
r.ondata @ socket.io.js:6
(anonymous) @ socket.io.js:8
r.emit @ socket.io.js:6
r.onPacket @ socket.io.js:6
(anonymous) @ socket.io.js:6
r.emit @ socket.io.js:6
r.onPacket @ socket.io.js:7
r.onData @ socket.io.js:7
ws.onmessage @ socket.io.js:8
vis.js:2596 Error in eval[error]: SyntaxError: Unexpected token ':'

@GermanBluefox

th4git avatar Mar 08 '22 09:03 th4git

In die Falle bin ich auch getappt. Adapter 1.4.15.

  1. {a:alias.0.Smartmeter.Zählerstand.Abgabe;b:alias.0.Smartmeter.Zählerstand.Abgabe;a}
  2. {a:alias.0.Smartmeter.Zählerstand.Abgabe;b:alias.0.Smartmeter.Zählerstand.Abgabe;b}
  3. {a:alias.0.Smartmeter.Zählerstand.Abgabe;b:alias.0.Smartmeter.Zählerstand.Abgabe;a + " und " + b}

Ergibt:

  1. 7
  2. 0
  3. 0

Danke und Gruß

Parodontitis avatar May 01 '22 13:05 Parodontitis

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs within the next 7 days. Please check if the issue is still relevant in the most current version of the adapter and tell us. Also check that all relevant details, logs and reproduction steps are included and update them if needed. Thank you for your contributions. Dieses Problem wurde automatisch als veraltet markiert, da es in letzter Zeit keine Aktivitäten gab. Es wird geschlossen, wenn nicht innerhalb der nächsten 7 Tage weitere Aktivitäten stattfinden. Bitte überprüft, ob das Problem auch in der aktuellsten Version des Adapters noch relevant ist, und teilt uns dies mit. Überprüft auch, ob alle relevanten Details, Logs und Reproduktionsschritte enthalten sind bzw. aktualisiert diese. Vielen Dank für Eure Unterstützung.

stale[bot] avatar Sep 21 '22 06:09 stale[bot]

Gleiches Problem. Habe ewig versucht, eine einfache Berechnung auszuführen, die einfach nicht klappen wollte. Jetzt diesen Bug entdeckt.

micw421 avatar Sep 21 '22 08:09 micw421

Will there be any progress with this issue/bug? It's open for almost 1 year now and I expect it can be fixed within 30 minutes... @GermanBluefox

th4git avatar Nov 02 '22 13:11 th4git

potentieller fix für das umlaut/raute-problem allerdings zunächst zum testen mit umfangreicheren visualisierungen. Anweisungen für den manuellen patch in einer iobroker-test-instanz https://forum.iobroker.net/topic/69004/rechnen-im-html-widget-geht-nicht-mehr/18

oweitman avatar Oct 11 '23 18:10 oweitman