致力于在本地构建googlecloudendpoints API,了解如何构造消息。此API将使管理SDK报表API a活动:列表方法可用,但受OU限制(对于使用G套件的用户)。在包含一组重复消息的消息上遇到构造错误:
ERROR 2019-04-01 12:01:58,861 service.py:191] Encountered unexpected error from ProtoRPC method implementation: TypeError (__init__() takes exactly 1 argument (6 given))
Traceback (most recent call last):
File "/Users/me/google-cloud-sdk/platform/google_appengine/lib/protorpc-1.0/protorpc/wsgi/service.py", line 181, in protorpc_service_app
response = method(instance, request)
File "/Users/me/Documents/GitHub/activitylogs_api/lib/endpoints/api_config.py", line 1351, in invoke_remote
return remote_method(service_instance, request)
File "/Users/me/google-cloud-sdk/platform/google_appengine/lib/protorpc-1.0/protorpc/remote.py", line 414, in invoke_remote_method
response = method(service_instance, request)
File "/Users/me/Documents/GitHub/activitylogs_api/main.py", line 142, in list_activities
events=[event1,event2]
TypeError: __init__() takes exactly 1 argument (6 given)
INFO 2019-04-01 12:01:58,873 module.py:861] default: "GET /_ah/api/activitylogs/v1/list HTTP/1.1" 503 196
代码如下:
^{pr2}$
所有字段都需要作为关键字参数传入,包括
id
和actor
:相关问题 更多 >
编程相关推荐