Return-Path: Delivered-To: apmail-couchdb-dev-archive@www.apache.org Received: (qmail 14112 invoked from network); 9 Oct 2010 01:20:30 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 9 Oct 2010 01:20:30 -0000 Received: (qmail 82287 invoked by uid 500); 9 Oct 2010 01:19:51 -0000 Delivered-To: apmail-couchdb-dev-archive@couchdb.apache.org Received: (qmail 82212 invoked by uid 500); 9 Oct 2010 01:19:51 -0000 Mailing-List: contact dev-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@couchdb.apache.org Delivered-To: mailing list dev@couchdb.apache.org Received: (qmail 82130 invoked by uid 99); 9 Oct 2010 01:19:51 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 09 Oct 2010 01:19:51 +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.22] (HELO thor.apache.org) (140.211.11.22) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 09 Oct 2010 01:19:48 +0000 Received: from thor (localhost [127.0.0.1]) by thor.apache.org (8.13.8+Sun/8.13.8) with ESMTP id o991JRl6003594 for ; Sat, 9 Oct 2010 01:19:27 GMT Message-ID: <12190078.51001286587167545.JavaMail.jira@thor> Date: Fri, 8 Oct 2010 21:19:27 -0400 (EDT) From: "Paul Joseph Davis (JIRA)" To: dev@couchdb.apache.org Subject: [jira] Updated: (COUCHDB-895) Improved log() function to handle "undefined" as well as object's of type "xml" In-Reply-To: <25124905.427451285616913468.JavaMail.jira@thor> 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/COUCHDB-895?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Paul Joseph Davis updated COUCHDB-895: -------------------------------------- Skill Level: New Contributors Level (Easy) > Improved log() function to handle "undefined" as well as object's of type "xml" > ------------------------------------------------------------------------------- > > Key: COUCHDB-895 > URL: https://issues.apache.org/jira/browse/COUCHDB-895 > Project: CouchDB > Issue Type: Improvement > Components: JavaScript View Server > Affects Versions: 0.11.1, 0.11.2, 1.0, 1.0.1 > Reporter: Benjamin Young > Priority: Minor > Fix For: 1.0.2 > > Attachments: log_improvements.diff > > > Currently (1.0.1 and below), if you try log(undefined) in a map/reduce or other JS function in CouchDB, you'll get a rather verbose stack trace. This patch casts the message var as a String to avoid that stack trace and output the text representation of "undefined". > Additionally, this patch includes outputting XML objects (build with E4X: new XML('')) as string representations of the entire XML (using toXMLString()). -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.