Mercurial > code > home > repos > homeauto
diff service/environment/environment.py @ 1708:3cfd3693a4ac
quick fixes for cyclone sse
author | drewp@bigasterisk.com |
---|---|
date | Wed, 17 Nov 2021 14:25:14 -0800 |
parents | 4167101b816f |
children |
line wrap: on
line diff
--- a/service/environment/environment.py Sat Oct 23 13:23:02 2021 -0700 +++ b/service/environment/environment.py Wed Nov 17 14:25:14 2021 -0800 @@ -15,8 +15,9 @@ from patchablegraph import PatchableGraph, CycloneGraphEventsHandler, CycloneGraphHandler from twilight import isWithinTwilight from standardservice.logsetup import log, verboseLogging - +from patch_cyclone import patch_sse from rdfdoc import Doc +patch_sse() ROOM = Namespace("http://projects.bigasterisk.com/room/") DEV = Namespace("http://projects.bigasterisk.com/device/") @@ -27,7 +28,7 @@ class CycloneGraphEventsHandlerWithCors(CycloneGraphEventsHandler): def flush(self): - self.set_header("Access-Control-Allow-Origin", "*") + self.set_header(b"Access-Control-Allow-Origin", b"*") return CycloneGraphEventsHandler.flush(self)