简体   繁体   English

带有Google Wave主动机器人API的HttpError 502 fetch_wavelet()

[英]HttpError 502 with Google Wave Active Robot API fetch_wavelet()

I am trying to use the Google Wave Active Robot API fetch_wavelet() and I get an HTTP 502 error 我正在尝试使用Google Wave Active Robot API fetch_wavelet() ,但收到HTTP 502错误

example: 例:

    from waveapi import robot
    import passwords

    robot = robot.Robot('gae-run', 'http://images.com/fake-image.jpg')
    robot.setup_oauth(passwords.CONSUMER_KEY, passwords.CONSUMER_SECRET, server_rpc_base='http://www-opensocial.googleusercontent.com/api/rpc')
    wavelet = robot.fetch_wavelet('googlewave.com!w+dtuZi6t3C','googlewave.com!conv+root')
    robot.submit(wavelet)
    self.response.out.write(wavelet.creator)

But the error I get is this: 但是我得到的错误是这样的:

Traceback (most recent call last):
  File "/base/python_runtime/python_lib/versions/1/google/appengine/ext/webapp/__init__.py", line 511, in __call__
    handler.get(*groups)
  File "/base/data/home/apps/clstff/gae-run.342467577023864664/main.py", line 23, in get
    robot.submit(wavelet)
  File "/base/data/home/apps/clstff/gae-run.342467577023864664/waveapi/robot.py", line 486, in submit
    res = self.make_rpc(pending)
  File "/base/data/home/apps/clstff/gae-run.342467577023864664/waveapi/robot.py", line 251, in make_rpc
    raise IOError('HttpError ' + str(code))
IOError: HttpError 502

Any ideas? 有任何想法吗?


Edit: 编辑:

When clstff@appspot.com is not a member of the wave I get the correct error message 如果clstff@appspot.com不是wave的成员,我会收到正确的错误消息

Error: RPC Error500: internalError: clstff@appspot.com is not a participant of wave id: [WaveId:googlewave.com!w+Pq1HgvssD] wavelet id: [WaveletId:googlewave.com!conv+root]. Unable to apply operation: {'method':'robot.fetchWave','id':'655720','waveId':'googlewave.com!w+Pq1HgvssD','waveletId':'googlewave.com!conv+root','blipId':'null','parameters':{}}

But when clstff@appsot.com is a member of the wave I get the http 502 error. 但是,如果clstff@appsot.com wave的成员, 则会出现http 502错误。

IOError: HttpError 502

Joe Gregorio answered my question on the Google Wave API Google group Joe Gregorio在Google Wave API Google论坛上回答了我的问题

Did you make any changes to the wavelet before submitting it? 提交之前,您对小波进行过任何更改吗? I think there was an old bug where sending in an empty change would cause a 502, this might be a regression in that behavior. 我认为存在一个旧错误,发送空更改将导致502,这可能是该行为的回归。

If I removed the robot.submit(wavelet) line, it worked! 如果我删除了robot.submit(wavelet)行,它就可以了!

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM