GAE: Channel API: ApplicationError: 1

2019-07-26 03:48发布

GAE seems to throw an ApplicationError: 1 on some code that has worked before. It could be a general GEA problem or some version upgrade issue as the code last was used a while ago. How would I debug that error?

ApplicationError: 1  (/base/data/home/runtimes/python27/python27_lib/versions/third_party/webapp2-2.5.2/webapp2.py:1552)
Traceback (most recent call last):
  File "/base/data/home/runtimes/python27/python27_lib/versions/third_party/webapp2-2.5.2/webapp2.py", line 1535, in __call__
    rv = self.handle_exception(request, response, e)
  File "/base/data/home/runtimes/python27/python27_lib/versions/third_party/webapp2-2.5.2/webapp2.py", line 1529, in __call__
    rv = self.router.dispatch(request, response)
  File "/base/data/home/runtimes/python27/python27_lib/versions/third_party/webapp2-2.5.2/webapp2.py", line 1278, in default_dispatcher
    return route.handler_adapter(request, response)
  File "/base/data/home/runtimes/python27/python27_lib/versions/third_party/webapp2-2.5.2/webapp2.py", line 1102, in __call__
    return handler.dispatch()
  File "/base/data/home/runtimes/python27/python27_lib/versions/third_party/webapp2-2.5.2/webapp2.py", line 572, in dispatch
    return self.handle_exception(e, self.app.debug)
  File "/base/data/home/runtimes/python27/python27_lib/versions/third_party/webapp2-2.5.2/webapp2.py", line 570, in dispatch
    return method(*args, **kwargs)
  File "/base/data/home/apps/e~(AppId)/dev.(VersionId)/worker.py", line 732, in post
    channel.send_message('status-' + userId, str(emailCount) + ":" + str(emailTotal))
  File "/base/data/home/runtimes/python27/python27_lib/versions/1/google/appengine/api/channel/channel.py", line 242, in send_message
    raise _ToChannelError(e)
ApplicationError: ApplicationError: 1   

1条回答
趁早两清
2楼-- · 2019-07-26 04:11

The Channels API has been shutdown; the decprecation page is here.

It states:

The Channel API did not scale well enough for the workloads it was intended for and so did not find wide adoption. Accordingly, support for the Channel API will be shut down for brief periods of time for maintenance beginning on July 13, 2017, as described in the shutdown timetable. The service will be turned off permanently on October 31, 2017.

The recommended alternative is to use Firebase:

See Using Firebase for realtime events on App Engine for information on replacing Channel API functionality with the Firebase Realtime Database.

查看更多
登录 后发表回答