BlipSubmitted not working?

6 views
Skip to first unread message

JamesBrooks

unread,
Oct 10, 2009, 9:34:50 PM10/10/09
to Google Wave API
For some reason BlipSubmitted does not work, I've tried all sorts of
outputs when the method should be called.

tehgdbot.RegisterHandler(events.BLIP_SUBMITTED, OnBlipSubmitted)

def OnBlipSubmitted(properties, context):
blip = context.GetBlipById(properties['blipId'])
blip.CreateChild().GetDocument().SetText('I\'d now read the
text...')

But nothing...

James Purser

unread,
Oct 10, 2009, 9:37:24 PM10/10/09
to google-...@googlegroups.com

Have you tried putting some logging into the function?

logging.debug("OnBlipSubmitted Called") or something similar?
--
James Purser
Collaborynth
http://collaborynth.com.au
Mob: +61 406 576 553
Skype: purserj1977
Twitter: http://twitter.com/purserj

JamesBrooks

unread,
Oct 10, 2009, 9:40:50 PM10/10/09
to Google Wave API
How does this work? I don't have a sandbox developer account yet, so
I'm not sure if this is a sandbox thing or not?

On Oct 11, 2:37 am, James Purser <jamesrpur...@gmail.com> wrote:
> On Sat, 2009-10-10 at 18:34 -0700, JamesBrooks wrote:
> > For some reason BlipSubmitted does not work, I've tried all sorts of
> > outputs when the method should be called.
>
> > tehgdbot.RegisterHandler(events.BLIP_SUBMITTED, OnBlipSubmitted)
>
> > def OnBlipSubmitted(properties, context):
> >     blip = context.GetBlipById(properties['blipId'])
> >     blip.CreateChild().GetDocument().SetText('I\'d now read the
> > text...')
>
> > But nothing...
>
> Have you tried putting some logging into the function?
>
> logging.debug("OnBlipSubmitted Called") or something similar?
> --
> James Purser
> Collaborynthhttp://collaborynth.com.au

James Purser

unread,
Oct 10, 2009, 9:43:39 PM10/10/09
to google-...@googlegroups.com
On Sat, 2009-10-10 at 18:40 -0700, JamesBrooks wrote:
> How does this work? I don't have a sandbox developer account yet, so
> I'm not sure if this is a sandbox thing or not?

Okay here's the onBlipSubmitted function from my openausbot:

def onBlipSubmitted(properties, context):
"""Invoked when a new wavelet blip is created"""
oakey = "F8c6oBD4YQsvEAGJT8DUgL8p"


blip = context.GetBlipById(properties['blipId'])

user = blip.GetCreator()
words = blip.GetDocument().GetText()
logging.debug("user: %s" % user)
logging.debug("words: %s" % str(words))

commands = []
commands.append(Command("help", r"^[hH][eE][lL][pP]$", help))
commands.append(Command("search_rep",
r"^search_rep ?(?P<HOUSE>[\w]+)? ?(?P<SEAT>[\w\s\w]+)?$", search_rep))
commands.append(Command("search_party",
r"^search_party ?(?P<PARTY>[\w]+)?$", search_party))
commands.append(Command("search_hansard",
r"^search_hansard ?(?P<HOUSE>[\w]+)? ?(?P<STYPE>[\w]+)? ?(?P<SEARCH>[w\s
\w]+)?$", search_hansard))

for command in commands:
pat = re.compile(command.pattern)
m = pat.search(words)
if m:
logging.debug("groupdict: %s" % str(m.groupdict()))
command(properties, context, user, **m.groupdict())
return
return

Note the logging.debug calls in the function. They create log entries in
your appspot account which can be viewed by selecting Logs and then
Debug from the drop down.
--
James Purser
Collaborynth

JamesBrooks

unread,
Oct 10, 2009, 9:48:42 PM10/10/09
to Google Wave API
Nope, no debug added to the logs. I tried it with the
WAVELET_SELF_ADDED and it logged it, so it's something wrong with the
BLIP_SUBMITTED method?

James Purser

unread,
Oct 10, 2009, 9:50:50 PM10/10/09
to google-...@googlegroups.com

Could you post your main function? Or if you're on the beta, my account
is the same as my gmail.

JamesBrooks

unread,
Oct 10, 2009, 9:53:02 PM10/10/09
to Google Wave API
I've added you on Wave.

On Oct 11, 2:50 am, James Purser <jamesrpur...@gmail.com> wrote:
> On Sat, 2009-10-10 at 18:48 -0700, JamesBrooks wrote:
> > Nope, no debug added to the logs. I tried it with the
> > WAVELET_SELF_ADDED and it logged it, so it's something wrong with the
> > BLIP_SUBMITTED method?
>
> Could you post your main function? Or if you're on the beta, my account
> is the same as my gmail.
>
> --
> James Purser
> Collaborynthhttp://collaborynth.com.au

Kyle

unread,
Oct 11, 2009, 3:09:10 AM10/11/09
to Google Wave API
I can confirm BLIP_SUBMITTED not working. The following is my main
file for my robot, and no debug information is being logged.

http://pastie.org/650182

pamela fox (Google employee)

unread,
Oct 11, 2009, 3:59:58 AM10/11/09
to Google Wave API
I was experiencing this issue, and by changing my app.yaml to point to
a new application ID, I got the robot at the new address to respond. I
will file a bug, but perhaps you can use that workaround in the
meantime.

Tip: I have a dummy App Engine ID that I use for temporary stuff like
this, it's handy. (Mine is pamelafox-randomdemo).

- pamela

JamesBrooks

unread,
Oct 11, 2009, 5:42:19 AM10/11/09
to Google Wave API
Thanks Pamela! I shall create a new id now.

On Oct 11, 8:59 am, "pamela fox (Google employee)"

JamesBrooks

unread,
Oct 11, 2009, 5:55:39 AM10/11/09
to Google Wave API
Nope changing the application id did not work, still no BLIP_SUBMITTED
request.

pamela (Google Employee)

unread,
Oct 11, 2009, 9:58:32 AM10/11/09
to google-...@googlegroups.com
Hey James-

It worked for me, but perhaps there is still some other issue. What are the IDs that you have tried?

- pamela

JamesBrooks

unread,
Oct 11, 2009, 10:31:02 AM10/11/09
to Google Wave API
I created a new one called catkincottage but alas no luck.

On Oct 11, 2:58 pm, "pamela (Google Employee)" <pamela...@gmail.com>
wrote:

Rahul

unread,
Oct 11, 2009, 11:30:39 AM10/11/09
to Google Wave API
I have same problem but it is working in sandbox but not in preview

Roy

unread,
Oct 11, 2009, 1:37:46 PM10/11/09
to Google Wave API
I'm having the same issue. BLIP_SUBMITTED does not seem to work.

pamela (Google Employee)

unread,
Oct 11, 2009, 5:35:11 PM10/11/09
to google-...@googlegroups.com
Can you 2 update the thread with your app IDs? It will be useful for us debugging.

- pamela

JamesBrooks

unread,
Oct 11, 2009, 7:00:17 PM10/11/09
to Google Wave API
tehgdbot and catkincottage neither work

On Oct 11, 10:35 pm, "pamela (Google Employee)" <pamela...@gmail.com>
wrote:

pamela (Google Employee)

unread,
Oct 12, 2009, 3:00:12 AM10/12/09
to google-...@googlegroups.com
We believe we located the problem. Your robots should probably work right now, but until we fix the underlying cause, they may stop responding again. We're working on the fix.

It is possible that getting a new app engine ID will fix the issue for you; but it's also possible that it won't. (So, worth a try, but not a guarantee now).

Apologies for causing frustration.

- pamela

JamesBrooks

unread,
Oct 12, 2009, 4:53:59 AM10/12/09
to Google Wave API
Thanks pamela, I shall try it later.

On Oct 12, 8:00 am, "pamela (Google Employee)" <pamela...@gmail.com>
> > > > > > > > > > > > Twitter:http://twitter.com/purserj- Hide quoted text -
>
> - Show quoted text -

Chris C.

unread,
Oct 12, 2009, 3:19:21 PM10/12/09
to Google Wave API
Holy cow, is _that_ why no matter what I did yesterday, my Python
robot didn't do anything? I decided to learn Python for some robot-
writing funtimes, and no matter what I did, the sample bot did
nothing. I am so relieved. Thanks for looking into it!

On Oct 12, 3:00 am, "pamela (Google Employee)" <pamela...@gmail.com>

JamesBrooks

unread,
Oct 12, 2009, 3:22:59 PM10/12/09
to Google Wave API
Tell me about it! I spent 8 hours on the day I reported this
scratching my head. I'm still recovering from the amount of coffee I
had!

aberant

unread,
Oct 12, 2009, 2:22:41 PM10/12/09
to Google Wave API
roybot5000 does not work either. i just ran into this problem.

On Oct 11, 4:35 pm, "pamela (Google Employee)" <pamela...@gmail.com>
wrote:

pamela (Google Employee)

unread,
Oct 12, 2009, 9:37:28 PM10/12/09
to google-...@googlegroups.com
Sorry for the hassle, everyone. 

The problem arises from us retrieving an empty capabilities.xml file from your App Engine server (when it times out, for example, which does sometimes happen) and then never re-retrieving that file. 

So, your robot should theoretically work atleast once on a new App ID if it is coded correctly. Make sure that your capabilities.xml is being generated correctly by navigating to it in browser. For example:
http://exporty-bot.appspot.com/_wave/capabilities.xml 

We're working on the fix. Please star this issue:

- pamela

Daniel Koller

unread,
Oct 13, 2009, 11:56:47 AM10/13/09
to Google Wave API
Hi there,

I also have the issue that I do not see any the BLIP_ADDED*-Events
posted:

- I used already two app-Is (linkeddataexplorer.appsport.com and
ldetest01.appspot.com) with the same App-Version deployed. (at the
moment it just echoes what comes in).
- My capabilities.xml loads, but has no w:Profile part ... may this be
the problem?
- The app never gets called, and nothing is echoed too ;-)
- I redeloyed it, I also removed and added the app as contacts over
and over.

Can you help there?

Kind regards,

Daniel

Juan Figueredo

unread,
Oct 20, 2009, 1:14:18 AM10/20/09
to Google Wave API
Hi Pamela, thx for your answer. It worked nicely indeed.

As a not-so-desirable-but-useful workaround I included the main events
with nop methods in the first upload to a new App-Id (except
document_changed as it sounds as a highly consuming event - plz
correct me if wrong). Now I have a (on blip_submitted) !dice command
=P
On Oct 12, 8:37 pm, "pamela (Google Employee)" <pamela...@gmail.com>
Reply all
Reply to author
Forward
0 new messages