- From: Ash Berlin <
>
- To:
- Subject: [chef] Re: Re: Re: Re: Re: Re: Problem with remote_file downloading?
- Date: Wed, 8 Sep 2010 16:36:32 +0100
On 8 Sep 2010, at 16:32, Daniel DeLeo wrote:
>
>
>
> If i create the directory it works. The bug here is that in attempting to
>
> work around one problem in net/http chef has hidden any number of other
>
> possible problems.
>
>
>
>
Chef only rescues NoMethodError and only re-raises it as
>
Errno::ECONNREFUSED if the error message matches "undefined method
>
`closed?' for nil:NilClass"
>
>
http://github.com/opscode/chef/blob/1306d20e7f8fd64b069dbcf213f6230df4c67fae/chef/lib/chef/rest/rest_request.rb#L76-86
>
>
You can see in the original gist that this is actually the error that
>
was raised, since the original error is logged to debug. The
>
backtrace there also shows that this error was raised from net/http.rb
>
line 1060, which is consistent with the net/http bug chef is papering
>
over.
>
>
So I'm still quite confused how remote file to a directory that
>
doesn't exist could cause this.
>
>
Dan DeLeo
Because net/http did raise a NoMethodError due to @socket being already nil.
But this was not caused by connection refused - the download succeeded and
the block ran, and the block then excepted (at some point in that flow I
guess @socket got closed and nulled).
-ash
Archive powered by MHonArc 2.6.16.