def subscribe(hass, callback):
 def zigbee_frame_subscriber(event):
  'Decode and unpickle the frame from the event bus, and call back.'
  frame = pickle.loads(b64decode(event.data[ATTR_FRAME]))
  callback(frame)
 hass.bus.listen(EVENT_ZIGBEE_FRAME_RECEIVED, zigbee_frame_subscriber)

def subscribe ( hass , callback ) : def zigbee_frame_subscriber ( event ) : frame = pickle . loads ( b64decode ( event . data [ ATTR_FRAME ] ) ) callback ( frame ) hass . bus . listen ( EVENT_ZIGBEE_FRAME_RECEIVED , zigbee_frame_subscriber )
toggle watching a document for edits .