Hi,
I see that only required files are
-project
+waveapi
app.yaml
ergodicresearch.py
But how did these extra files came into?
-ergodicresearch
app.yaml
index.yaml
main.py
Delete these extra files.
Then, in in project/ergodicresearch.py, chage the "version" of robot
if __name__ == '__main__':
myRobot = robot.Robot('ergodicresearch',
image_url='http://ergodicresearch.appspot.com/icon.png',
version='2',
profile_url='http://ergodicresearch.appspot.com/')
Then update the project in google app engine. Then try.
If it does not solve your problem, then log on to your dashboard
(https://appengine.google.com/)
select your application, then from the left panel, click on the label
"Logs". You will find the errors that is creating the problem.
Let me know what happens.
Regards
Sarwar Erfan
On Dec 7, 8:52 am, George Oliver <[email protected]> wrote:
> hi, I've read some older threads on this topic, but nothing has helped
> -- I followed the Python bot 'hello world' tutorial
> athttp://code.google.com/apis/wave/extensions/robots/python-tutorial.html
> and uploaded the bot, but the bot doesn't respond to events and its
> capabilities.xml returns a blank page (the source is blank as well).
>
> This is the bot: [email protected]
>
> Uploading the bot and adding it to a wave works fine, but then I get
> nothing. I see no debug/info/etc. logs, but I do see activity in the
> dashboard/quota log when I create a blip in the wave that the bot is
> in.
>
> Thanks for any help! I've appended source code below.
>
> Here's what my source dir looks like:
>
> -project
> +waveapi
> app.yaml
> ergodicresearch.py
> -ergodicresearch
> app.yaml
> index.yaml
> main.py
>
> This is /app.yaml:
>
> application: ergodicresearch
> version: 1
> runtime: python
> api_version: 1
>
> handlers:
> - url: /_wave/.*
> script: ergodicresearch.py
> - url: /assets
> static_dir: assets
>
> This is /ergodicresearch.py:
>
> from waveapi import events
> from waveapi import model
> from waveapi import robot
>
> def OnParticipantsChanged(properties, context):
> """Invoked when any participants have been added/removed."""
> added = properties['participantsAdded']
> for p in added:
> Notify(context)
>
> def OnRobotAdded(properties, context):
> """Invoked when the robot has been added."""
> root_wavelet = context.GetRootWavelet()
> root_wavelet.CreateBlip().GetDocument().SetText("I'm alive!")
>
> def Notify(context):
> root_wavelet = context.GetRootWavelet()
> root_wavelet.CreateBlip().GetDocument().SetText("Hi everybody!")
>
> if __name__ == '__main__':
> myRobot = robot.Robot('ergodicresearch',
> image_url='http://ergodicresearch.appspot.com/icon.png',
> version='1',
> profile_url='http://ergodicresearch.appspot.com/')
> myRobot.RegisterHandler(events.WAVELET_PARTICIPANTS_CHANGED,
> OnParticipantsChanged)
> myRobot.RegisterHandler(events.WAVELET_SELF_ADDED, OnRobotAdded)
> myRobot.Run()
>
> This is ergodicresearch/app.yaml:
>
> application: ergodicresearch
> version: 1
> runtime: python
> api_version: 1
>
> handlers:
> - url: .*
> script: main.py
>
> This is ergodicresearch/index.yaml:
>
> indexes:
>
> # AUTOGENERATED
>
> # This index.yaml is automatically updated whenever the dev_appserver
> # detects that a new type of query is run. If you want to manage the
> # index.yaml file manually, remove the above marker line (the line
> # saying "# AUTOGENERATED"). If you want to manage some indexes
> # manually, move them above the marker line. The index.yaml file is
> # automatically uploaded to the admin console when you next deploy
> # your application using appcfg.py.
>
> and this is ergodicresearch/main.py:
>
> #!/usr/bin/env python
> #
> # Copyright 2007 Google Inc.
> #
> # Licensed under the Apache License, Version 2.0 (the "License");
> # you may not use this file except in compliance with the License.
> # You may obtain a copy of the License at
> #
> # http://www.apache.org/licenses/LICENSE-2.0
> #
> # Unless required by applicable law or agreed to in writing, software
> # distributed under the License is distributed on an "AS IS" BASIS,
> # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
> implied.
> # See the License for the specific language governing permissions and
> # limitations under the License.
> #
>
> from google.appengine.ext import webapp
> from google.appengine.ext.webapp import util
>
> class MainHandler(webapp.RequestHandler):
>
> def get(self):
> self.response.out.write('Hello world!')
>
> def main():
> application = webapp.WSGIApplication([('/', MainHandler)],
> debug=True)
> util.run_wsgi_app(application)
>
> if __name__ == '__main__':
> main()
--
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.