Return-Path: Delivered-To: apmail-couchdb-user-archive@www.apache.org Received: (qmail 70728 invoked from network); 20 Jan 2009 00:16:16 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 20 Jan 2009 00:16:16 -0000 Received: (qmail 53911 invoked by uid 500); 20 Jan 2009 00:16:10 -0000 Delivered-To: apmail-couchdb-user-archive@couchdb.apache.org Received: (qmail 53861 invoked by uid 500); 20 Jan 2009 00:16:10 -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 53850 invoked by uid 99); 20 Jan 2009 00:16:10 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 19 Jan 2009 16:16:10 -0800 X-ASF-Spam-Status: No, hits=2.2 required=10.0 tests=HTML_MESSAGE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of dundeemt@gmail.com designates 209.85.198.230 as permitted sender) Received: from [209.85.198.230] (HELO rv-out-0506.google.com) (209.85.198.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 20 Jan 2009 00:16:03 +0000 Received: by rv-out-0506.google.com with SMTP id g37so2875751rvb.35 for ; Mon, 19 Jan 2009 16:15:43 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:sender:received:date :x-google-sender-auth:message-id:subject:from:to:content-type; bh=Wb10QoDuekFdfnpCsp/9i3kEdfqD0fOEOIiBq3CQNeE=; b=l1bR6JEC66oCTGXqQZaf6h6zWJbfKLV+wAtz/5d4e6lUC7vP2omIvM+Ro6AZ1XYRlg cx47MSo13zhRPtlCGQ27Sp91eIJnKT9ZSNDKbo3V8gaZ6F7BpxsrPpwt050VlQIyMemQ xPLbpw4X+LnZzK6IK5ntlAQbpdh9x4de0emc4= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:sender:date:x-google-sender-auth:message-id:subject :from:to:content-type; b=S2NfIMV5Q+bSab3MgJ8v/JLvm+pvIyQVdRKKsJ0mW7EPovaHgyAOpw86i0V/jFg6yt 7BQJd2XrW3EQOYJY95vbdZx8S1enrxysJgLHEqGlGCTJ16OIzNiWwISPfuPrMKDzXNmC GHG7XTP90UtfCr9npklsoYAhMIervsrBSy2vg= MIME-Version: 1.0 Sender: dundeemt@gmail.com Received: by 10.141.201.1 with SMTP id d1mr3068763rvq.293.1232410543553; Mon, 19 Jan 2009 16:15:43 -0800 (PST) Date: Mon, 19 Jan 2009 18:15:43 -0600 X-Google-Sender-Auth: 30b359d770b57a9b Message-ID: <5aaed53f0901191615r6062c9e3gf1dd966ec206bd03@mail.gmail.com> Subject: on Reduce w/ Python view server From: "Jeff Hinrichs - DM&T" To: couchdb-user Content-Type: multipart/alternative; boundary=000e0cd14964aa7c850460def0d5 X-Virus-Checked: Checked by ClamAV on apache.org --000e0cd14964aa7c850460def0d5 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Using couchdb-python 0.5 and couchdb 0.9.0a735191-incubating I am working on a "rosetta stone" for javascript and python views. (nothing like rewriting in a different language to lean something) I've worked though the simple map only views. I then did a simple reduce(keys,vals) which worked out fine. But I am stumped on rereduce when the function signature includes keys,vals,rereduce. I've been trying to work through the js code from "Top N Tags" from the snippets page, http://wiki.apache.org/couchdb/View_Snippets In particular, I am confused as to what is passed to the rereduce function when rereduce=True. The javascript is returning a complex structure instead of a simple scalar, I see that it has to do with getting state back from a previous reduce operation, but I'm confused. The unpacking of the previous results, I think has me befuddled ;( Any help is appreciated. Regards, Jeff p.s. Yes, I'd be happy to make a wiki page out of my work, but I'm not sure where it belongs, couchdb wiki or the couchdb-python wiki. --000e0cd14964aa7c850460def0d5--