当我尝试将1000多个列表插入Appengine数据存储区时,我痛心此错误RequestTooLargeError: The request to API call datastore_v3.Put() was too large.

尝试导入此

from google.appengine.ext.db import RequestTooLargeError
try:
    .....
except RequestTooLargeError:
    logging.error("RequestTooLargeError")


但是得到ImportError: cannot import name RequestTooLargeError

如何在Appengine中捕获此RequestTooLargeError异常?

最佳答案

此模块例外:

from google.appengine.runtime.apiproxy_errors import RequestTooLargeError

10-05 18:56