我创建了一个搜索索引,用文档填充它,它按设计工作。现在我想使用开发控制台从索引中删除文档。
这样做时,我遇到了错误。
'Index' object has no attribute 'delete_documents'
完整的堆栈跟踪如下:
Traceback (most recent call last):
File "C:\Program Files\Google\google_appengine\lib\webapp2\webapp2.py", line 1536, in __call__
rv = self.handle_exception(request, response, e)
File "C:\Program Files\Google\google_appengine\lib\webapp2\webapp2.py", line 1530, in __call__
rv = self.router.dispatch(request, response)
File "C:\Program Files\Google\google_appengine\lib\webapp2\webapp2.py", line 1278, in default_dispatcher
return route.handler_adapter(request, response)
File "C:\Program Files\Google\google_appengine\lib\webapp2\webapp2.py", line 1102, in __call__
return handler.dispatch()
File "C:\Program Files\Google\google_appengine\lib\webapp2\webapp2.py", line 572, in dispatch
return self.handle_exception(e, self.app.debug)
File "C:\Program Files\Google\google_appengine\lib\webapp2\webapp2.py", line 570, in dispatch
return method(*args, **kwargs)
File "C:\Program Files\Google\google_appengine\google\appengine\ext\admin\__init__.py", line 133, in xsrf_required_decorator
method(self)
File "C:\Program Files\Google\google_appengine\google\appengine\ext\admin\__init__.py", line 1766, in post
index.delete_documents(docs)
AttributeError: 'Index' object has no attribute 'delete_documents'