Return-Path: Delivered-To: apmail-couchdb-user-archive@www.apache.org Received: (qmail 54662 invoked from network); 30 Dec 2008 11:36:18 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 30 Dec 2008 11:36:18 -0000 Received: (qmail 53143 invoked by uid 500); 30 Dec 2008 11:36:16 -0000 Delivered-To: apmail-couchdb-user-archive@couchdb.apache.org Received: (qmail 53103 invoked by uid 500); 30 Dec 2008 11:36:16 -0000 Mailing-List: contact user-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@couchdb.apache.org Delivered-To: mailing list user@couchdb.apache.org Received: (qmail 53092 invoked by uid 99); 30 Dec 2008 11:36:15 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 30 Dec 2008 03:36:15 -0800 X-ASF-Spam-Status: No, hits=1.2 required=10.0 tests=SPF_NEUTRAL X-Spam-Check-By: apache.org Received-SPF: neutral (nike.apache.org: local policy) Received: from [83.97.50.139] (HELO jan.prima.de) (83.97.50.139) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 30 Dec 2008 11:36:05 +0000 Received: from [192.168.1.100] (f053000049.adsl.alicedsl.de [::ffff:78.53.0.49]) (AUTH: LOGIN jan, TLS: TLSv1/SSLv3,128bits,AES128-SHA) by jan.prima.de with esmtp; Tue, 30 Dec 2008 11:35:44 +0000 Message-Id: <8191A5C8-208E-400E-AB46-7DBE1E2623D0@apache.org> From: Jan Lehnardt To: user@couchdb.apache.org In-Reply-To: <495A0350.4060106@theopenlearningcentre.com> Content-Type: text/plain; charset=US-ASCII; format=flowed; delsp=yes Content-Transfer-Encoding: 7bit Mime-Version: 1.0 (Apple Message framework v930.3) Subject: Re: couchdb errors - Date: Tue, 30 Dec 2008 12:35:13 +0100 References: <4c69d7170812300107v52506bf8j1ece4313e7cbbd75@mail.gmail.com> <52EC596E-E6A4-479A-99C6-A8DB3819DC62@apache.org> <495A0350.4060106@theopenlearningcentre.com> X-Mailer: Apple Mail (2.930.3) X-Virus-Checked: Checked by ClamAV on apache.org Hi Alan, I think: 1) the wiki page that now lists install & runtime errors should be split up in separate install & runtime error pages. 2) the pages should get an index like http://wiki.apache.org/couchdb/Frequently_asked_questions that adds #anchors for direct links. Anybody wants to tackle this? Be our hero! Cheers Jan -- On 30 Dec 2008, at 12:17, Alan Bell wrote: > OK, so Jan's full reply there was a near-perfect error message. > Informative, useful and a proper explanation. So how do we get > "Cannot encode 'undefined' value as JSON" to include a link to a > wiki page with Jan's reply on it? > > Alan. > > > Jan Lehnardt wrote: >> >> On 30 Dec 2008, at 10:07, paul jobs wrote: >> >>> http://rafb.net/p/oz8VfH95.html >>> [Tue, 30 Dec 2008 09:04:46 GMT] [info] [<0.134.0>] OS Process Log >>> Message: >>> function raised exception (Cannot encode 'undefined' value as >>> JSON) with >>> doc._id bef1111175e1d5052e9c49db546b39db >> >> Your Javascript is using an object member that is not defined. E.g.: >> >> { >> "_id":"XYZ123", >> "_rev":"1BB2BB", >> "field":"value" >> } >> >> map: function(doc) { >> emit(doc.name, doc.address); >> } >> >> instead, try this: >> >> map: function(doc) { >> if(doc.name && doc.address) { >> emit(doc.name, doc.address); >> } >> } >> Cheers, >> Jan > >