Plone ParseError:Token';原子';必需,u';和';在LiveSearch上找到

Plone ParseError:Token';原子';必需,u';和';在LiveSearch上找到,plone,livesearch,Plone,Livesearch,在搜索查询中添加单词AND、OR、NOT会引发类似Plone 4.1中的错误: 2011-07-28 14:52:46 ERROR Zope.SiteErrorLog 1311882766.090.999612944712 http://localhost:8080/Plone/livesearch_reply Traceback (innermost last): Module ZPublisher.Publish, line 126, in publish Module ZPubli

在搜索查询中添加单词AND、OR、NOT会引发类似Plone 4.1中的错误:

2011-07-28 14:52:46 ERROR Zope.SiteErrorLog 1311882766.090.999612944712 http://localhost:8080/Plone/livesearch_reply
Traceback (innermost last):
  Module ZPublisher.Publish, line 126, in publish
  Module ZPublisher.mapply, line 77, in mapply
  Module Products.PDBDebugMode.runcall, line 70, in pdb_runcall
  Module ZPublisher.Publish, line 46, in call_object
  Module Products.CMFCore.FSPythonScript, line 130, in __call__
  Module Shared.DC.Scripts.Bindings, line 322, in __call__
  Module Shared.DC.Scripts.Bindings, line 359, in _bindAndExec
  Module Products.PythonScripts.PythonScript, line 344, in _exec
  Module script, line 73, in livesearch_reply
   - <FSPythonScript at /Plone/livesearch_reply>
   - Line 73
  Module AccessControl.ZopeGuards, line 373, in guarded_apply
  Module AccessControl.ZopeGuards, line 395, in builtin_guarded_apply
  Module Products.CMFPlone.CatalogTool, line 430, in searchResults
  Module Products.ZCatalog.ZCatalog, line 604, in searchResults
  Module Products.ZCatalog.Catalog, line 902, in searchResults
  Module Products.ZCatalog.Catalog, line 528, in search
  Module Products.ZCTextIndex.ZCTextIndex, line 222, in _apply_index
  Module Products.ZCTextIndex.QueryParser, line 135, in parseQuery
  Module Products.ZCTextIndex.QueryParser, line 175, in _parseOrExpr
  Module Products.ZCTextIndex.QueryParser, line 193, in _parseAndExpr
  Module Products.ZCTextIndex.QueryParser, line 210, in _parseNotExpr
  Module Products.ZCTextIndex.QueryParser, line 223, in _parseTerm
  Module Products.ZCTextIndex.QueryParser, line 242, in _parseAtom
  Module Products.ZCTextIndex.QueryParser, line 170, in _get
  Module Products.ZCTextIndex.QueryParser, line 156, in _require
ParseError: Token 'ATOM' required, u'AND' found
2011-07-28 14:52:46错误Zope.SiteErrorLog 1311882766.090.999612944712http://localhost:8080/Plone/livesearch_reply
回溯(最里面的最后一个):
发布中的模块ZPublisher.Publish,第126行
模块ZPublisher.mapply,第77行,在mapply中
pdb_runcall中第70行的模块Products.PDBDebugMode.runcall
模块ZPublisher.Publish,第46行,在call_对象中
模块Products.CMFCore.FSPythonScript,第130行,in__调用__
模块Shared.DC.Scripts.Bindings,第322行,在调用中__
模块Shared.DC.Scripts.Bindings,第359行,在_bindAndExec中
模块产品.PythonScripts.PythonScript,第344行,in_exec
模块脚本,第73行,在livesearch\u回复中
- 
-第73行
模块ACCESS CONTROL.ZOPEGARDS,第373行,采用防护措施
模块ACCESS CONTROL.ZOPEGARDS,第395行,内置式
searchResults中的模块Products.CMFPlone.CatalogTool,第430行
searchResults中的模块Products.ZCatalog.ZCatalog,第604行
searchResults中的模块Products.ZCatalog.Catalog,第902行
模块Products.ZCatalog.Catalog,第528行,搜索中
模块Products.ZCTextIndex.ZCTextIndex,第222行,在应用索引中
parseQuery中模块Products.ZCTextIndex.QueryParser,第135行
模块Products.ZCTextIndex.QueryParser,第175行,in_parseOrExpr
模块Products.ZCTextIndex.QueryParser,第193行,in_parseAndExpr
模块Products.ZCTextIndex.QueryParser,第210行,in_parseNotExpr
模块Products.ZCTextIndex.QueryParser,第223行,按_语法术语
模块Products.ZCTextIndex.QueryParser,第242行,在
模块Products.ZCTextIndex.QueryParser,第170行,输入
模块Products.ZCTextIndex.QueryParser,第156行,需要
ParseError:需要标记'ATOM',找到u'和'

有人能解释一下普隆的LiveSearch中搜索背后的逻辑吗?有什么方法可以避免这种情况,或者我可以忽略日志文件中的这些消息吗?

忽略它们,这是一种ZCTextIndex行为。错误只是被记录下来,查询不返回任何内容。在你的plone站点的某个地方有“word”并被索引,尝试在plone中搜索类似“and word OR”的内容,即使有“word”,也看不到任何返回。尝试只搜索“单词”,您将看到结果