Ah - the GadgetStateChanged event works with filter, but the filter is attended to filter on the URL of the gadget, so that you can only listen to changes for a particular gadget.
We'll improve the documentation to make that clearer. It's possible that a document changed filter will work for what you want, since the gadget state is technically a part of the document. I have not tested that, however. - pamela On Wed, Apr 14, 2010 at 5:51 AM, Martin Kreichgauer < [email protected]> wrote: > Hello, > > I tried using the filters of the Python v2 Robot API with the > GadgetStateChanged event. The code looks like this: > > def on_gadget_state_changed(event, wavelet): > # ... > my_robot = robot.Robot(my_robot, profile_url='url') > my_robot.register_handler(events.GadgetStateChanged, > on_gadget_state_changed, > filter="StringThatDoesNotAppearAnywhereInTheGadgetState") > appengine_robot_runner.run(my_robot, debug=True) > > I would expect that the handler never gets called because the filter > string can certainly not be found in the wave or any gadget state. > However, the event handler is called every single time the gadget > state changes. What am I doing wrong? > > Thanks, > Martin Kreichgauer > > -- > You received this message because you are subscribed to the Google Groups > "Google Wave API" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]<google-wave-api%[email protected]> > . > For more options, visit this group at > http://groups.google.com/group/google-wave-api?hl=en. > > -- You received this message because you are subscribed to the Google Groups "Google Wave API" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/google-wave-api?hl=en.
