Adapt to changes in 'State' interface
authorBenjamin Braatz <bb@bbraatz.eu>
Fri, 5 Mar 2021 22:40:38 +0000 (23:40 +0100)
committerBenjamin Braatz <bb@bbraatz.eu>
Fri, 5 Mar 2021 22:40:38 +0000 (23:40 +0100)
conf.json
example-client.py

index 740d854fdfaebb00a2c683bca2fa8ef105cd1411..10b4afcd831c4568c3c66d3956f53b83a181d80c 100644 (file)
--- a/conf.json
+++ b/conf.json
     },
     "Delay Start after On": {
         "plugin": "Alias",
-        "from": { "sender": "Example State", "state": true, "changed": true },
+        "from": { "sender": "Example State", "event": "changed", "state": true },
         "to": { "target": "Off Delay", "command": "wait" }
     },
     "State Off after Delay": {
         "plugin": "Alias",
         "from": { "sender": "Off Delay", "event": "finished" },
-        "to": { "target": "Example State", "command": "set state", "state": false }
+        "to": { "target": "Example State", "command": "set state", "new state": false }
     },
     "Debug Logger": {
         "plugin": "Log",
index 6359db5535f759b630b496e876652f0e3fd7f0b6..367666e0186581bcbfe01ec631ed4d708a699968 100644 (file)
@@ -6,7 +6,7 @@ import websockets
 
 async def test_commands(websocket):
     commands = [{'target': 'Example State',
-                 'command': 'set state', 'state': True},
+                 'command': 'set state', 'new state': True},
                 {'target': 'Example State', 'command':
                  'get state'}]
     for command in commands: