Return-Path: Delivered-To: apmail-subversion-users-archive@minotaur.apache.org Received: (qmail 17831 invoked from network); 5 Jan 2011 22:16:27 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 5 Jan 2011 22:16:27 -0000 Received: (qmail 96497 invoked by uid 500); 5 Jan 2011 22:16:27 -0000 Delivered-To: apmail-subversion-users-archive@subversion.apache.org Received: (qmail 96456 invoked by uid 500); 5 Jan 2011 22:16:27 -0000 Mailing-List: contact users-help@subversion.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Delivered-To: mailing list users@subversion.apache.org Received: (qmail 96449 invoked by uid 99); 5 Jan 2011 22:16:27 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 05 Jan 2011 22:16:27 +0000 X-ASF-Spam-Status: No, hits=1.8 required=10.0 tests=FREEMAIL_FROM,FREEMAIL_REPLY,RCVD_IN_DNSWL_LOW,RFC_ABUSE_POST,SPF_PASS,T_TO_NO_BRKTS_FREEMAIL X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of andy.levy@gmail.com designates 209.85.214.43 as permitted sender) Received: from [209.85.214.43] (HELO mail-bw0-f43.google.com) (209.85.214.43) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 05 Jan 2011 22:16:21 +0000 Received: by bwz14 with SMTP id 14so17472695bwz.16 for ; Wed, 05 Jan 2011 14:16:00 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:mime-version:received:in-reply-to :references:from:date:message-id:subject:to:cc:content-type :content-transfer-encoding; bh=cj+r0IJpq6pzV9Urf6XdUJrfpBQKzmzuSUJf3mK76OU=; b=d0lyv+eVYga/f9OM5sfNMqjPsG4ZieLw7/T8YqRcRpcxgk1CFTGmtQSD82EtqZ6zBF /92BGuQpGLxVSpnMhDtOP1YXfqdLhd9dr5qoiPAPGsVIYnc0GFA/2rffInjRYB2uH5bK smVraYzFR4lPvDqT70KUTbBqCjngX7h9GUij8= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type:content-transfer-encoding; b=scMIgHTvY7UgAojkpwLYVSDzQ/HSkFNWtU7L0BcInBMOoT2xc42uPaxAebtCrfXtx2 0Pm7Hd2ZDOfY6oE6jl3yrDvj0SF8gZtgqujYea8bgoTB0hII1XnF7GXyoj2cMTKHxlwm lvoOEymsK+q0rvqA8KuLxoaT5dE5bAVI1xe9g= Received: by 10.204.72.20 with SMTP id k20mr1270193bkj.184.1294265759679; Wed, 05 Jan 2011 14:15:59 -0800 (PST) MIME-Version: 1.0 Received: by 10.204.4.145 with HTTP; Wed, 5 Jan 2011 14:15:19 -0800 (PST) In-Reply-To: References: From: Andy Levy Date: Wed, 5 Jan 2011 17:15:19 -0500 Message-ID: Subject: Re: Hooks That Use Perl Test::Builder Having Problems with STDERR To: eric.berg@barclayscapital.com Cc: qazwart@gmail.com, users@subversion.apache.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Virus-Checked: Checked by ClamAV on apache.org On Wed, Jan 5, 2011 at 17:03, wrote: > Dave, if you look into how the hooks work, basically, they are passed a r= epo > path and a transaction id that, using svnlook, gives you access to copies= of > the working files, so it doesn't matter where the hooks run, nor is there > any requirement for server/client communication. Depending upon what your hooks do, they may require a full working copy (and thus client executable) to operate. > Though I do love immediate checkins, I'm not sure where you're going when > you suggest that our validations might be better handled some way other t= han > by hooks.=A0 That appears to be the whole reason to have such hooks:=A0 t= o > validate files before allowing a checkin. One breaking point in my mind is "how long will this take?". If it's a very fast script to execute then a hook script is probably fine. If it's a compilation & test suite execution, that could take minutes or longer. One of my projects takes 15 minutes to do a full compile & deploy; I can't hold every other commit to the repository for that. > How would hudson help to validate files in the context of a checkin > transaction? A CI server would do the validation after checkin (allowing the checkin to be very fast), and send notifications in the case of errors (or success, for that matter). > ________________________________ > From: David Weintraub [mailto:qazwart@gmail.com] > Sent: Wednesday, January 05, 2011 4:37 PM > To: Berg, Eric: IT (NYK) > Cc: users@subversion.apache.org > Subject: Re: Hooks That Use Perl Test::Builder Having Problems with STDER= R > > On Wed, Jan 5, 2011 at 11:30 AM,=A0=A0wrot= e: >> >> I'm working on porting a fairly extensive set of CVS hooks to SVN. > > Okay. Stop right there. When ever someone mentions "a fairly extensive se= t" > of hooks, I start to think maybe most of what they want shouldn't > necessarily be hooks. When hooks are running, the client is sitting there > waiting for the results. I've been at one place where it wasn't unusual f= or > a commit to take almost a minute for reformatting, testing, etc. Those we= re > a group of very frustrated developers. > Besides, how can you even run your tests? The hooks execute on the > Subversion server, yet the working directory is on the client=A0There's n= o > communication between the server and client until the hooks are complete. >> The issue that I'm having now is that my pre-commit hook, which runs a >> Perl script >> that performs tests based on Test::Builder and Test::More, never show >> their stderr >> on the console. =A0I see it in the svn web server logs, but not on the >> console. > The problem is that Subversion swallow STDOUT and STDERR from the hooks, = and > Subversion won't display STDERR unless the hook script returns a non-zero > exit value, and only then, it displays it on the developer's console. Tha= t > may be your problem. > Do you have =A0continuous build server like Hudson (http://hudson-ci.org)= ? > Even if you don't need to compile code, you can use something like Hudson > for running your tests. Hudson can checkout the project from the Subversi= on > repository, run tests, and then report back the results. > Moving your testing to Hudson will simplify your life and help keep a > running record of your test results. Hudson won't interfere with > Test::Builder and Test::More, and you'll be able to keep the test results= of > all of your check ins in one easy to find place. > -- > David Weintraub > qazwart@gmail.com > > _______________________________________________ > > > > This e-mail may contain information that is confidential, privileged or > otherwise protected from disclosure. If you are not an intended recipient= of > this e-mail, do not duplicate or redistribute it by any means. Please del= ete > it and any attachments and notify the sender that you have received it in > error. Unless specifically indicated, this e-mail is not an offer to buy = or > sell or a solicitation to buy or sell any securities, investment products= or > other financial product or service, an official confirmation of any > transaction, or an official statement of Barclays. Any views or opinions > presented are solely those of the author and do not necessarily represent > those of Barclays. This e-mail is subject to terms available at the > following link: www.barcap.com/emaildisclaimer. By messaging with Barclay= s > you consent to the foregoing.=A0 Barclays Capital is the investment banki= ng > division of Barclays Bank PLC, a company registered in England (number > 1026167) with its registered office at 1 Churchill Place, London, E14 5HP= . > This email may relate to or be sent from other members of the Barclays > Group. > > _______________________________________________