[ https://issues.apache.org/jira/browse/LUCENE-8495?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17339489#comment-17339489 ]
Radu Gheorghe commented on LUCENE-8495: --------------------------------------- Is there something needed to merge this patch? Maybe some testing on the current master master branch? Can I help with anything? I'm asking because it seems to affect other use-cases, for example with ascii folding in the analysis chain in Solr. > ComplexPhraseQuery.rewrite throws "Unknown query > type:org.apache.lucene.search.SynonymQuery" when nested BooleanQuery contains > a SynonymQuery > ---------------------------------------------------------------------------------------------------------------------------------------------- > > Key: LUCENE-8495 > URL: https://issues.apache.org/jira/browse/LUCENE-8495 > Project: Lucene - Core > Issue Type: Bug > Components: core/queryparser > Affects Versions: 7.4, 8.0 > Reporter: Bjarke Mortensen > Priority: Major > Attachments: > 0001-Added-support-for-nested-synonym-queries-in-ComplexP.patch > > > When using nested queries in ComplexPhrases, and a part of the query is a > SynonymQuery, an exception is thrown from addComplexPhraseClause: > {{throw new IllegalArgumentException("Unknown query type:"}} > {{ + childQuery.getClass().getName());}} > Examples (dogs and tv are synonyms): > {{"(cats OR dogs) cigar"}} > "platform* (video* OR tv)"~10 > The bug is similar in nature to LUCENE-8305, in that SynonymQuery support was > added to ComplexPhraseQueryParser (in LUCENE-7695), but was not expanded to > nested queries. > The fix is similar to the one in LUCENE-8305, namely to add the same logic in > addComplexPhraseClause as in rewrite. > See attached patch. -- This message was sent by Atlassian Jira (v8.3.4#803005) --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For additional commands, e-mail: issues-h...@lucene.apache.org