For our group, we require authentication for checking out code. When I moved ccrb to new machine, I started getting a really weird error. I figured out the cause: I forgot to change my subversion config to cache the password, so svn complained. I''m just wondering if there''s a way to make ccrb more robust (or at least helpful) in the face of an underlying failure.> $ ./cruise start > ... > Build loop failed > REXML::ParseException: #<REXML::ParseException: No close tag for /log> > [stack trace] > ./lib/cruise_control/../../script/../config/../lib/ > cruise_control/../../script/../config/../lib/source_control/ > subversion/log_parser.rb:10:in `parse'' > ./lib/cruise_control/../../script/../config/../lib/ > cruise_control/../../script/../config/../lib/source_control/ > subversion.rb:60:in `latest_revision'' > [stack trace] > ... > No close tag for /log > Line: > Position: > Last 80 unconsumed characters:It turns out that svn was griping [I''ve marked STDOUT & STDERR channels]:> $ svn log --revision HEAD:1 --verbose --xml --limit 1 --non- > interactive > [STDOUT]<?xml version="1.0"?> > [STDOUT]<log> > [STDERR]svn: OPTIONS of ''http://.../'': authorization failed > (http://.../)That explains the unclosed /log tag. So, digging a little further, lib/source_control/ abstract_adapter.rb:execute_with_error_log is running the command, but throwing away the error output:> def execute_with_error_log(command, error_log) > FileUtils.rm_f(error_log) > FileUtils.touch(error_log) > execute(command, :stderr => error_log) do |io| > stdout_output = io.readlines > begin > error_message = File.open(error_log){|f| > f.read}.strip.split("\n")[1] || "" > rescue > error_message = "" > ensure > FileUtils.rm_f(error_log) > end > return stdout_output > end > endThis is where I get "stuck" -- what''s the ccrb "way" to proceed here? Raise an error? Scribble something in the builder_status file? The content of error_message before the method returned ("svn: OPTIONS of ''http://.../'': authorization failed (http://.../)") would have pointed out the problem. It just got buried. I''m sure that the are other niggling errors that bubble up from underlying source control systems from time to time. Aloha a hui hou, Ken -- Ken Mayer / kmayer at bitwrangler.com / 808-722-6142 / http://www.bitwrangler.com/
On Thu, Sep 25, 2008 at 6:20 PM, Ken Mayer <kmayer at bitwrangler.com> wrote:> This is where I get "stuck" -- what''s the ccrb "way" to proceed here? Raise > an error? Scribble something in the builder_status file? The content of > error_message before the method returned ("svn: OPTIONS of ''http://.../'': > authorization failed (http://.../)") would have pointed out the problem. > It just got buried. I''m sure that the are other niggling errors that bubble > up from underlying source control systems from time to time. >I just had this problem, and opened a bug: http://cruisecontrolrb.lighthouseapp.com/projects/9150/tickets/212-builder-failure-if-svn-log-fails-with-credentials-error Not sure the right way to proceed - I just discussed it the Jeremy Lighthouse and he had some thoughts. It boils down to the non-zero return code from failed auth not getting handled correctly. It should not go on and attempt to parse the command results. -- Chad -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://rubyforge.org/pipermail/cruisecontrolrb-users/attachments/20080926/69e5782e/attachment.html>
Bret Pettichord
2008-Sep-26 19:50 UTC
[Cruisecontrolrb-users] When svn returns an error...
> Not sure the right way to proceed - I just discussed it the Jeremy > Lighthouse >Did he change his name again, or is this another guy? -- Bret Pettichord GTalk: bpettichord at gmail.com CTO, WatirCraft LLC, http://www.watircraft.com Lead Developer, Watir, http://wtr.rubyforge.org Blog (Essays), http://www.io.com/~wazmo/blog MiniBlog (Links), http://feeds.feedburner.com/bretshotlist -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://rubyforge.org/pipermail/cruisecontrolrb-users/attachments/20080926/d23747b0/attachment-0001.html>
Alexey Verkhovsky
2008-Sep-26 20:01 UTC
[Cruisecontrolrb-users] When svn returns an error...
cruisecontrolrb-users-bounces at rubyforge.org wrote on 09/26/2008 01:50:17 PM:>> discussed it the Jeremy Lighthouse > Did he change his name againTo the best of my knowledge, Jeremy didn''t. Somebody else did though :) -- Alex -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://rubyforge.org/pipermail/cruisecontrolrb-users/attachments/20080926/a3f32a6c/attachment.html>
On Fri, Sep 26, 2008 at 1:01 PM, Alexey Verkhovsky < averkhov at thoughtworks.com> wrote:> > cruisecontrolrb-users-bounces at rubyforge.org wrote on 09/26/2008 01:50:17 > PM: > >> discussed it the Jeremy Lighthouse > > > Did he change his name again > > To the best of my knowledge, Jeremy didn''t. Somebody else did though :) > >Freudian slip. He - umm - makes sure bugs get fixed. Just like Lighthouse :) -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://rubyforge.org/pipermail/cruisecontrolrb-users/attachments/20080926/76e64705/attachment.html>
On Fri, Sep 26, 2008 at 10:54 AM, Chad Woolley <thewoolleyman at gmail.com>wrote:> > I just had this problem, and opened a bug: > > > http://cruisecontrolrb.lighthouseapp.com/projects/9150/tickets/212-builder-failure-if-svn-log-fails-with-credentials-error > > Not sure the right way to proceed - I just discussed it the Jeremy > Lighthouse and he had some thoughts. It boils down to the non-zero return > code from failed auth not getting handled correctly. It should not go on > and attempt to parse the command results. > >This is fixed here: http://github.com/thewoolleyman/cruisecontrol.rb/commit/0a4694b321560755874ba16438a630379bd0fd21 Can someone commit? Thanks, -- Chad -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://rubyforge.org/pipermail/cruisecontrolrb-users/attachments/20081128/63010adf/attachment.html>