NEWS
[Gelöst] Script und Fehlermeldung im Log
-
Hallo Leute brauch mal wieder euer Wissen.
Ich möchte meine Wasserpumpe so steuern das diese nur alle 30Min an oder aus ist.
Mit dem Script lief es auf dem Raspi, seid ich nun den NUC habe hagelt es Fehlermeldungen im Log.
! javascript.0 2018-12-30 17:46:08.177 info Stop script script.js.Heizung.Wasserpumpe
! javascript.0 2018-12-30 17:46:04.572 error at TCP.onStreamRead [as onread] (internal/stream_base_commons.js:94:17)
! javascript.0 2018-12-30 17:46:04.572 error at Socket.Readable.push (_stream_readable.js:219:10)
! javascript.0 2018-12-30 17:46:04.572 error at readableAddChunk (_stream_readable.js:264:11)
! javascript.0 2018-12-30 17:46:04.572 error at addChunk (_stream_readable.js:283:12)
! javascript.0 2018-12-30 17:46:04.571 error at Socket.emit (events.js:182:13)
! javascript.0 2018-12-30 17:46:04.571 error at Socket._ultron.on (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/ws/lib/WebSocket.js:138:22)
! javascript.0 2018-12-30 17:46:04.571 error at Receiver.add (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/ws/lib/Receiver.js:139:10)
! javascript.0 2018-12-30 17:46:04.571 error at Receiver.startLoop (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/ws/lib/Receiver.js:165:16)
! javascript.0 2018-12-30 17:46:04.571 error at Receiver.getData (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/ws/lib/Receiver.js:330:12)
! javascript.0 2018-12-30 17:46:04.571 error at Receiver.dataMessage (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/ws/lib/Receiver.js:389:14)
! javascript.0 2018-12-30 17:46:04.571 error at Receiver._receiver.onmessage (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/ws/lib/WebSocket.js:141:47)
! javascript.0 2018-12-30 17:46:04.571 error at WebSocket.emit (events.js:182:13)
! javascript.0 2018-12-30 17:46:04.571 error at WebSocket.onMessage (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/ws/lib/EventTarget.js:99:16)
! javascript.0 2018-12-30 17:46:04.571 error at WebSocket.ws.onmessage (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/engine.io-client/lib/transports/websocket.js:147:10)
! javascript.0 2018-12-30 17:46:04.571 error at WS.Transport.onData (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/engine.io-client/lib/transport.js:137:8)
! javascript.0 2018-12-30 17:46:04.571 error at WS.Transport.onPacket (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/engine.io-client/lib/transport.js:145:8)
! javascript.0 2018-12-30 17:46:04.571 error at WS.Emitter.emit (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/component-emitter/index.js:133:20)
! javascript.0 2018-12-30 17:46:04.571 error at WS. <anonymous>(/opt/iobroker/node_modules/iobroker.js-controller/node_modules/engine.io-client/lib/socket.js:273:10)
! javascript.0 2018-12-30 17:46:04.571 error at Socket.onPacket (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/engine.io-client/lib/socket.js:456:14)
! javascript.0 2018-12-30 17:46:04.571 error at Socket.Emitter.emit (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/component-emitter/index.js:133:20)
! javascript.0 2018-12-30 17:46:04.571 error at Socket. <anonymous>(/opt/iobroker/node_modules/component-bind/index.js:21:15)
! javascript.0 2018-12-30 17:46:04.570 error at Manager.ondata (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/socket.io-client/lib/manager.js:335:16)
! javascript.0 2018-12-30 17:46:04.570 error at Decoder.add (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/socket.io-parser/index.js:251:12)
! javascript.0 2018-12-30 17:46:04.570 error at Decoder.Emitter.emit (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/component-emitter/index.js:133:20)
! javascript.0 2018-12-30 17:46:04.570 error at Decoder. <anonymous>(/opt/iobroker/node_modules/component-bind/index.js:21:15)
! javascript.0 2018-12-30 17:46:04.570 error at Manager.ondecoded (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/socket.io-client/lib/manager.js:345:8)
! javascript.0 2018-12-30 17:46:04.570 error at Manager.Emitter.emit (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/component-emitter/index.js:133:20)
! javascript.0 2018-12-30 17:46:04.570 error at Manager. <anonymous>(/opt/iobroker/node_modules/component-bind/index.js:21:15)
! javascript.0 2018-12-30 17:46:04.570 error at Socket.onpacket (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/socket.io-client/lib/socket.js:244:12)
! javascript.0 2018-12-30 17:46:04.570 error at Socket.onack (/opt/iobroker/node_modules/iobroker.js-controller/node_modules/socket.io-client/lib/socket.js:319:9)
! javascript.0 2018-12-30 17:46:04.570 error at Socket.adapter.getForeignState (/opt/iobroker/node_modules/iobroker.javascript/main.js:823:17)
! javascript.0 2018-12-30 17:46:04.570 error at createActiveObject (/opt/iobroker/node_modules/iobroker.javascript/main.js:1200:20)
! javascript.0 2018-12-30 17:46:04.570 error at prepareScript (/opt/iobroker/node_modules/iobroker.javascript/main.js:1146:37)
! javascript.0 2018-12-30 17:46:04.570 error at compile (/opt/iobroker/node_modules/iobroker.javascript/main.js:957:28)
! javascript.0 2018-12-30 17:46:04.570 error at Object.createScript (vm.js:251:10)
! javascript.0 2018-12-30 17:46:04.570 error at new Script (vm.js:79:7)
! javascript.0 2018-12-30 17:46:04.570 error SyntaxError: Unexpected token *
! javascript.0 2018-12-30 17:46:04.569 error ^
! javascript.0 2018-12-30 17:46:04.569 error schedule(*/30 7-22 * * *, function () {
! javascript.0 2018-12-30 17:46:04.569 error at script.js.Heizung.Wasserpumpe:1
! javascript.0 2018-12-30 17:46:04.569 error script.js.Heizung.Wasserpumpe compile failed:
! javascript.0 2018-12-30 17:46:04.567 info Start javascript script.js.Heizung.Wasserpumpe</anonymous></anonymous></anonymous></anonymous>Im Anhang ist das Script.
10440_wasserpumpe.jpg -
javascript.0 2018-12-30 17:46:04.569 error schedule(*/30 7-22 * * *, function () { `
Downgrade Javascript-Adapter auf Version 3.6.4 ! -
Post geändert, habs hinbekommen
Lösung
[root@iobroker ~]# cd /opt/iobroker
[root@iobroker iobroker]# npm install iobroker.javascript@3.6.4
npm WARN deprecated coffee-script@1.12.7: CoffeeScript on NPM has moved to "coffeescript" (no hyphen)
- iobroker.javascript@3.6.4
removed 13 packages, updated 6 packages and audited 2843 packages in 4.162s
found 48 vulnerabilities (28 low, 9 moderate, 11 high)
run
npm audit fix
to fix them, ornpm audit
for details[root@iobroker iobroker]# iobroker update javascript
Used repository: javascript
update done
-
Allerdings hagelt es immer noch Fehlermeldungen.
! javascript.0 2018-12-30 18:29:58.689 error at Object.createScript (vm.js:251:10)
! javascript.0 2018-12-30 18:29:58.689 error at new Script (vm.js:79:7)
! javascript.0 2018-12-30 18:29:58.689 error SyntaxError: Unexpected token *
! javascript.0 2018-12-30 18:29:58.689 error ^
! javascript.0 2018-12-30 18:29:58.689 error schedule(*/30 7-22 * * *, function () {
! javascript.0 2018-12-30 18:29:58.689 error script.js.Heizung.Wasserpumpe compile failed: at script.js.Heizung.Wasserpumpe:1
! javascript.0 2018-12-30 18:29:58.689 info Start javascript script.js.Heizung.Wasserpumpe -
Gib mal den Zeitplan unter JS 3.6.4 neu ein. Er wird vermutlich nicht automatisch korrigiert.
-
Ich hab den Zeitplan gelöscht um neu erstellt.
Es hat sich leider nichts geändert, bekomme die selbe Fehlermeldung erneut
-
Es hat sich leider nichts geändert, bekomme die selbe Fehlermeldung erneut `
Hat der JS-Adapter wirklich die Version 3.6.4 ?Bluefox hat in Version 4.0.7 das CRON-Problem gefixt. Diese Version kann man von github installieren.
-
Ok hab jetzt 4.0.7 drauf dann mal das ganze von vorne
-
Wie hole ich mir per CLI die neue Version. `
Nicht per CLI, sondern über den Reiter "Adapter": "Installieren aus eigener URL" anwählen (Katzenkopf oben), im Reiter "VON GITHUB" Adapter "javascript" auswählen und Button "INSTALLIEREN" klicken. -
Langsam glaube ich das ich ein generelle Problem mit der kompletten Installation habe
Um mal bissel ordnung zu haben im Log wollte ich gerade mal das LOG löschen,
dabei hat sich der iobroker neugestartet.
Naja und was das Pumpen Script angeht ist es schlimmer geworden
! javascript.0 2018-12-30 21:09:23.288 info Stop script script.js.Heizung.Fussboden
! javascript.0 2018-12-30 21:09:09.043 error at TCP.onStreamRead [as onread] (internal/stream_base_commons.js:94:17)
! javascript.0 2018-12-30 21:09:09.043 error at Socket.Readable.push (_stream_readable.js:219:10)
! javascript.0 2018-12-30 21:09:09.043 error at readableAddChunk (_stream_readable.js:264:11)
! javascript.0 2018-12-30 21:09:09.043 error at addChunk (_stream_readable.js:283:12)
! javascript.0 2018-12-30 21:09:09.043 error at Socket.emit (events.js:182:13)
! javascript.0 2018-12-30 21:09:09.043 error at Socket.realHandler (/opt/iobroker/node_modules/ws/lib/WebSocket.js:825:20)
! javascript.0 2018-12-30 21:09:09.043 error at Receiver.add (/opt/iobroker/node_modules/ws/lib/Receiver.js:103:24)
! javascript.0 2018-12-30 21:09:09.043 error at Receiver.expectHandler (/opt/iobroker/node_modules/ws/lib/Receiver.js:499:31)
! javascript.0 2018-12-30 21:09:09.043 error at Receiver.finish (/opt/iobroker/node_modules/ws/lib/Receiver.js:541:12)
! javascript.0 2018-12-30 21:09:09.043 error at Receiver.flush (/opt/iobroker/node_modules/ws/lib/Receiver.js:347:3)
! javascript.0 2018-12-30 21:09:09.043 error at /opt/iobroker/node_modules/ws/lib/Receiver.js:508:14
! javascript.0 2018-12-30 21:09:09.043 error at Receiver.applyExtensions (/opt/iobroker/node_modules/ws/lib/Receiver.js:371:5)
! javascript.0 2018-12-30 21:09:09.043 error at /opt/iobroker/node_modules/ws/lib/Receiver.js:536:18
! javascript.0 2018-12-30 21:09:09.043 error at Receiver.ontext (/opt/iobroker/node_modules/ws/lib/WebSocket.js:841:10)
! javascript.0 2018-12-30 21:09:09.043 error at WebSocket.emit (events.js:182:13)
! javascript.0 2018-12-30 21:09:09.043 error at WebSocket.onMessage (/opt/iobroker/node_modules/ws/lib/WebSocket.js:442:14)
! javascript.0 2018-12-30 21:09:09.043 error at WebSocket.ws.onmessage (/opt/iobroker/node_modules/engine.io-client/lib/transports/websocket.js:146:10)
! javascript.0 2018-12-30 21:09:09.043 error at WS.Transport.onData (/opt/iobroker/node_modules/engine.io-client/lib/transport.js:137:8)
! javascript.0 2018-12-30 21:09:09.043 error at WS.Transport.onPacket (/opt/iobroker/node_modules/engine.io-client/lib/transport.js:145:8)
! javascript.0 2018-12-30 21:09:09.043 error at WS.Emitter.emit (/opt/iobroker/node_modules/engine.io-client/node_modules/component-emitter/index.js:133:20)
! javascript.0 2018-12-30 21:09:09.043 error at WS. <anonymous>(/opt/iobroker/node_modules/engine.io-client/lib/socket.js:268:10)
! javascript.0 2018-12-30 21:09:09.043 error at Socket.onPacket (/opt/iobroker/node_modules/engine.io-client/lib/socket.js:451:14)
! javascript.0 2018-12-30 21:09:09.043 error at Socket.Emitter.emit (/opt/iobroker/node_modules/engine.io-client/node_modules/component-emitter/index.js:133:20)
! javascript.0 2018-12-30 21:09:09.043 error at Socket. <anonymous>(/opt/iobroker/node_modules/component-bind/index.js:21:15)
! javascript.0 2018-12-30 21:09:09.043 error at Manager.ondata (/opt/iobroker/node_modules/socket.io-client/lib/manager.js:322:16)
! javascript.0 2018-12-30 21:09:09.043 error at Decoder.add (/opt/iobroker/node_modules/socket.io-parser/index.js:246:12)
! javascript.0 2018-12-30 21:09:09.043 error at Decoder.Emitter.emit (/opt/iobroker/node_modules/component-emitter/index.js:134:20)
! javascript.0 2018-12-30 21:09:09.042 error at Decoder. <anonymous>(/opt/iobroker/node_modules/component-bind/index.js:21:15)
! javascript.0 2018-12-30 21:09:09.042 error at Manager.ondecoded (/opt/iobroker/node_modules/socket.io-client/lib/manager.js:332:8)
! javascript.0 2018-12-30 21:09:09.042 error at Manager.Emitter.emit (/opt/iobroker/node_modules/socket.io-client/node_modules/component-emitter/index.js:133:20)
! javascript.0 2018-12-30 21:09:09.042 error at Manager. <anonymous>(/opt/iobroker/node_modules/component-bind/index.js:21:15)
! javascript.0 2018-12-30 21:09:09.042 error at Socket.onpacket (/opt/iobroker/node_modules/socket.io-client/lib/socket.js:236:12)
! javascript.0 2018-12-30 21:09:09.042 error at Socket.onack (/opt/iobroker/node_modules/socket.io-client/lib/socket.js:312:9)
! javascript.0 2018-12-30 21:09:09.042 error at Socket.adapter.getForeignState (/opt/iobroker/node_modules/iobroker.javascript/main.js:823:17)
! javascript.0 2018-12-30 21:09:09.042 error at createActiveObject (/opt/iobroker/node_modules/iobroker.javascript/main.js:1200:20)
! javascript.0 2018-12-30 21:09:09.042 error at prepareScript (/opt/iobroker/node_modules/iobroker.javascript/main.js:1146:37)
! javascript.0 2018-12-30 21:09:09.042 error at compile (/opt/iobroker/node_modules/iobroker.javascript/main.js:957:28)
! javascript.0 2018-12-30 21:09:09.042 error at Object.createScript (vm.js:251:10)
! javascript.0 2018-12-30 21:09:09.042 error at new Script (vm.js:79:7)
! javascript.0 2018-12-30 21:09:09.042 error SyntaxError: Unexpected token *
! javascript.0 2018-12-30 21:09:09.042 error ^
! javascript.0 2018-12-30 21:09:09.042 error schedule(*/30 7-22 * * *, function () {
! javascript.0 2018-12-30 21:09:09.042 error at script.js.Heizung.Wasserpumpe:1
! javascript.0 2018-12-30 21:09:09.042 error script.js.Heizung.Wasserpumpe compile failed:</anonymous></anonymous></anonymous></anonymous> -
Es ist nicht die Version 4.07 aktiv:
@Wolfgang:javascript.0 2018-12-30 21:09:09.042 error schedule(*/30 7-22 * * *, function () { `
Wenn Du auf Javascript-Ansicht umschaltest, muss es so aussehen:schedule("*/30 7-22 * * *", function () {
-
sieht bei mir genau so aus
schedule("*/30 7-22 * * *", function () {
setState("sonoff.0.POWR2_Pumpe_Wasser.POWER"/POWR2_Pumpe_Wasser POWER/, true);
});
Und dann scheint Iobroker mich anzulügen
10440_java.png -
sieht bei mir genau so aus
schedule("*/30 7-22 * * *", function () { `
Dann sollte der Fehlerlog nicht mehr auftreten. -
Ich hab jetzt nochmal alles gelöscht incl. dem ganzen Script.
Anschließend alles wieder installiert und das Script neuerstellt.
Nun ist Ruhe in Log.
Danke Paul