Either my head or everything seems completely broken.
Using waveapi Revision: 14
Tested bot:
def OnEvent(type, properties, context):
logging.debug("Event %s %s"%(type,properties))
if __name__ == '__main__':
from waveapi import robot
myRobot = robot.Robot('qmax-waving',
image_url='
http://qmax-waving.appspot.com/
assets/icon.jpg',
version='6.1')
myRobot.RegisterHandler(events.BLIP_SUBMITTED, lambda p,c: OnEvent
(events.BLIP_SUBMITTED,p,c))
myRobot.RegisterHandler(events.WAVELET_BLIP_CREATED, lambda p,c:
OnEvent(events.WAVELET_BLIP_CREATED,p,c))
myRobot.RegisterHandler(events.WAVELET_BLIP_REMOVED, lambda p,c:
OnEvent(events.WAVELET_BLIP_REMOVED,p,c))
myRobot.RegisterHandler(events.WAVELET_PARTICIPANTS_CHANGED,
lambda p,c: OnEvent(events.WAVELET_PARTICIPANTS_CHANGED,p,c))
myRobot.RegisterHandler(events.WAVELET_SELF_ADDED, lambda p,c:
OnEvent(events.WAVELET_SELF_ADDED,p,c))
myRobot.RegisterHandler(events.WAVELET_SELF_REMOVED, lambda p,c:
OnEvent(events.WAVELET_SELF_REMOVED,p,c))
myRobot.RegisterHandler(events.WAVELET_TIMESTAMP_CHANGED, lambda
p,c: OnEvent(events.WAVELET_TIMESTAMP_CHANGED,p,c))
myRobot.RegisterHandler(events.WAVELET_TITLE_CHANGED, lambda p,c:
OnEvent(events.WAVELET_TITLE_CHANGED,p,c))
myRobot.RegisterHandler(events.WAVELET_VERSION_CHANGED, lambda
p,c: OnEvent(events.WAVELET_VERSION_CHANGED,p,c))
myRobot.RegisterHandler(events.BLIP_CONTRIBUTORS_CHANGED, lambda
p,c: OnEvent(events.BLIP_CONTRIBUTORS_CHANGED,p,c))
myRobot.RegisterHandler(events.BLIP_DELETED, lambda p,c: OnEvent
(events.BLIP_DELETED,p,c))
myRobot.RegisterHandler(events.BLIP_SUBMITTED, lambda p,c: OnEvent
(events.BLIP_SUBMITTED,p,c))
myRobot.RegisterHandler(events.BLIP_TIMESTAMP_CHANGED, lambda p,c:
OnEvent(events.BLIP_TIMESTAMP_CHANGED,p,c))
myRobot.RegisterHandler(events.BLIP_VERSION_CHANGED, lambda p,c:
OnEvent(events.BLIP_VERSION_CHANGED,p,c))
myRobot.RegisterHandler(events.DOCUMENT_CHANGED, lambda p,c:
OnEvent(events.DOCUMENT_CHANGED,p,c))
myRobot.RegisterHandler(events.FORM_BUTTON_CLICKED , lambda p,c:
OnEvent(events.FORM_BUTTON_CLICKED,p,c))
myRobot.Run()
Testing:
added bot to wave, created blip, typed text, deleted blip, added
another robot, removed another robot, removed the bot.
On wave preview:
triggered WAVELET_SELF_ADDED, BLIP_SUBMITTED
On wave sandbox:
triggered WAVELET_SELF_ADDED
Nothing else.