Return-Path: Delivered-To: apmail-lucene-solr-dev-archive@minotaur.apache.org Received: (qmail 8428 invoked from network); 8 Sep 2009 11:19:22 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 8 Sep 2009 11:19:22 -0000 Received: (qmail 57773 invoked by uid 500); 8 Sep 2009 11:19:22 -0000 Delivered-To: apmail-lucene-solr-dev-archive@lucene.apache.org Received: (qmail 57699 invoked by uid 500); 8 Sep 2009 11:19:22 -0000 Mailing-List: contact solr-dev-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: solr-dev@lucene.apache.org Delivered-To: mailing list solr-dev@lucene.apache.org Received: (qmail 57689 invoked by uid 99); 8 Sep 2009 11:19:21 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 08 Sep 2009 11:19:21 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 08 Sep 2009 11:19:18 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 9B76F234C4B5 for ; Tue, 8 Sep 2009 04:18:57 -0700 (PDT) Message-ID: <1254050438.1252408737634.JavaMail.jira@brutus> Date: Tue, 8 Sep 2009 04:18:57 -0700 (PDT) From: "Uri Boness (JIRA)" To: solr-dev@lucene.apache.org Subject: [jira] Commented: (SOLR-1071) spellcheck.extendedResults returns an invalid JSON response when count > 1 In-Reply-To: <1091095058.1237251350628.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/SOLR-1071?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12752448#action_12752448 ] Uri Boness commented on SOLR-1071: ---------------------------------- bq. It already does... it's just the client code that checks for NamedList (the parent of SimpleOrderedMap) No... sorry, I mean the top most "suggestions" node. line 182 in the patched class. > spellcheck.extendedResults returns an invalid JSON response when count > 1 > -------------------------------------------------------------------------- > > Key: SOLR-1071 > URL: https://issues.apache.org/jira/browse/SOLR-1071 > Project: Solr > Issue Type: Bug > Components: spellchecker > Affects Versions: 1.3 > Reporter: Uri Boness > Assignee: Yonik Seeley > Fix For: 1.4 > > Attachments: SOLR-1071.patch, SpellCheckComponent_fix.patch, SpellCheckComponent_new_structure.patch, SpellCheckComponent_new_structure_incl_test.patch > > > When: wt=json & spellcheck.extendedResults=true & spellcheck.count > 1, the suggestions are returned in the following format: > "suggestions":[ > "amsterdm",{ > "numFound":5, > "startOffset":0, > "endOffset":8, > "origFreq":0, > "suggestion":{ > "frequency":8498, > "word":"amsterdam"}, > "suggestion":{ > "frequency":1, > "word":"amsterd"}, > "suggestion":{ > "frequency":8, > "word":"amsterdams"}, > "suggestion":{ > "frequency":1, > "word":"amstedam"}, > "suggestion":{ > "frequency":22, > "word":"amsterdamse"}}, > "beak",{ > "numFound":5, > "startOffset":9, > "endOffset":13, > "origFreq":0, > "suggestion":{ > "frequency":379, > "word":"beek"}, > "suggestion":{ > "frequency":26, > "word":"beau"}, > "suggestion":{ > "frequency":26, > "word":"baak"}, > "suggestion":{ > "frequency":15, > "word":"teak"}, > "suggestion":{ > "frequency":11, > "word":"beuk"}}, > "correctlySpelled",false, > "collation","amsterdam beek"]}} > This is an invalid json as each term is associated with a JSON object which holds multiple "suggestion" attributes. When working with a JSON library only the last "suggestion" attribute is picked up. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.