Return-Path: Delivered-To: apmail-incubator-cassandra-user-archive@minotaur.apache.org Received: (qmail 99547 invoked from network); 20 Jul 2009 00:10:42 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 20 Jul 2009 00:10:42 -0000 Received: (qmail 96913 invoked by uid 500); 20 Jul 2009 00:11:47 -0000 Delivered-To: apmail-incubator-cassandra-user-archive@incubator.apache.org Received: (qmail 96871 invoked by uid 500); 20 Jul 2009 00:11:47 -0000 Mailing-List: contact cassandra-user-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: cassandra-user@incubator.apache.org Delivered-To: mailing list cassandra-user@incubator.apache.org Received: (qmail 96862 invoked by uid 99); 20 Jul 2009 00:11:47 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 20 Jul 2009 00:11:47 +0000 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of jbellis@gmail.com designates 209.85.219.223 as permitted sender) Received: from [209.85.219.223] (HELO mail-ew0-f223.google.com) (209.85.219.223) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 20 Jul 2009 00:11:38 +0000 Received: by ewy23 with SMTP id 23so1944358ewy.12 for ; Sun, 19 Jul 2009 17:11:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:content-type :content-transfer-encoding; bh=KuLjZw7n6T69P3K4bTGd51Q4y9/UY9IgVQnQFLCa+R8=; b=teBfyBN1SbUO6erV7RFhYE1i6eQ5LrrprD3Ek+KS0J9rM0bo3g76iKTjvI1QRn9AZi f5WWpaDIsw/sPgGQdoHDsLkhQistWMtRw/kcT53f4llvZZORJr/1ei6JCPF+JLZCA6uu Z3EzTwvp4zITEPwT/G3Y628Kmxxf4nFHIetSA= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:content-transfer-encoding; b=ROjRKoWRigJzPtwNM32BwRHstg56Ub1kiAla1ADffbTU61GXERfWOCXrjRjX7xDkpH rH7c3ixGu4NFF3ABE6+wA6waoAcnB7D3EpCOcd0smLZjmKe6TUWWz3xxuUkuwVG2kS0S wlAkonwD8ayosmqEVPKk6frUOsHQzdcWiOYJA= MIME-Version: 1.0 Received: by 10.216.8.78 with SMTP id 56mr964853weq.210.1248048677246; Sun, 19 Jul 2009 17:11:17 -0700 (PDT) In-Reply-To: References: <70254fc70907191029i72cf77cav51cd6da1b5a18250@mail.gmail.com> Date: Sun, 19 Jul 2009 19:11:17 -0500 Message-ID: Subject: Re: AttributeError: 'str' object has no attribute 'write' From: Jonathan Ellis To: cassandra-user@incubator.apache.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Virus-Checked: Checked by ClamAV on apache.org Building the java interface is part of the build, but ant has no way to guess which additional client interfaces you want to use, if any. On Sun, Jul 19, 2009 at 6:46 PM, Ian Holsman wrote: > hi Gasol. > shouldn't regeneration of the interface be part of the build process? > > On 20/07/2009, at 3:29 AM, Gasol Wu wrote: > >> hi, >> the cassandra.thrift has changed. >> u need to generate new python client and compile class again. >> >> >> On Mon, Jul 20, 2009 at 1:18 AM, wrote: >> Hi guys >> the new trunk cassandra doesnt work for a simple insert, how do we get >> this working >> >> client.insert('Table1', 'tofu', 'Super1:Related:tofu >> stew',pickle.dumps(dict(count=3D1)), time.time(), 0) >> >> ------------------------------------------------------------------------= --- >> AttributeError =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0Tr= aceback (most recent call >> last) >> >> /home/mark/work/cexperiments/ in () >> >> /home/mark/work/common/cassandra/Cassandra.py in insert(self, table, key= , >> column_path, value, timestamp, block_for) >> =A0 =A0358 =A0 =A0 =A0- block_for >> =A0 =A0359 =A0 =A0 """ >> --> 360 =A0 =A0 self.send_insert(table, key, column_path, value, timesta= mp, >> block_for) >> =A0 =A0361 =A0 =A0 self.recv_insert() >> =A0 =A0362 >> >> /home/mark/work/common/cassandra/Cassandra.py in send_insert(self, table= , >> key, column_path, value, timestamp, block_for) >> =A0 =A0370 =A0 =A0 args.timestamp =3D timestamp >> =A0 =A0371 =A0 =A0 args.block_for =3D block_for >> --> 372 =A0 =A0 args.write(self._oprot) >> =A0 =A0373 =A0 =A0 self._oprot.writeMessageEnd() >> =A0 =A0374 =A0 =A0 self._oprot.trans.flush() >> >> /home/mark/work/common/cassandra/Cassandra.py in write(self, oprot) >> =A0 1923 =A0 =A0 if self.column_path !=3D None: >> =A0 1924 =A0 =A0 =A0 oprot.writeFieldBegin('column_path', TType.STRUCT, = 3) >> -> 1925 =A0 =A0 =A0 self.column_path.write(oprot) >> =A0 1926 =A0 =A0 =A0 oprot.writeFieldEnd() >> =A0 1927 =A0 =A0 if self.value !=3D None: >> >> AttributeError: 'str' object has no attribute 'write' >> In [4]: client.insert('Table1', 'tofu', 'Super1:Related:tofu >> stew',pickle.dumps(dict(count=3D1)), time.time(), 0) >> >> >> -- >> Bidegg worlds best auction site >> http://bidegg.com >> > > -- > Ian Holsman > Ian@Holsman.net > > > >