From: Toby Dipasquale Date: 2007-04-18T11:48:54+09:00 Subject: Re: Timeout errors using Net::HTTP on Windows Toby Dipasquale wrote: > Toby DiPasquale wrote: >> I'm having a problem here running some file upload code on Windows. I've >> installed Ruby 1.8.6 from the one-click installer on Windows 2000 Server >> in VMware and on real hardware with Windows XP. The client, when running >> on Windows, always times/errors out no matter what. Here's the error: >> >> c:/ruby/lib/ruby/1.8/net/http.rb:2094:in `error!': 408 "Request Timeout >> " (Net::HTTPServerException) >> from c:/ruby/lib/ruby/1.8/net/http.rb:2103:in `value' >> from put_client.rb:25:in `upload_file' >> from c:/ruby/lib/ruby/1.8/net/http.rb:543:in `start' >> from put_client.rb:20:in `upload_file' >> from put_client.rb:30 > > This error is more indicative of what I've been seeing: > > c:/ruby/lib/ruby/1.8/timeout.rb:54:in `rbuf_fill': execution expired > (Timeout::Error) > from c:/ruby/lib/ruby/1.8/timeout.rb:56:in `timeout' > from c:/ruby/lib/ruby/1.8/timeout.rb:76:in `timeout' > from c:/ruby/lib/ruby/1.8/net/protocol.rb:132:in `rbuf_fill' > from c:/ruby/lib/ruby/1.8/net/protocol.rb:116:in `readuntil' > from c:/ruby/lib/ruby/1.8/net/protocol.rb:126:in `readline' > from c:/ruby/lib/ruby/1.8/net/http.rb:2017:in `read_status_line' > from c:/ruby/lib/ruby/1.8/net/http.rb:2006:in `read_new' > from c:/ruby/lib/ruby/1.8/net/http.rb:1047:in `request' > from put_client.rb:25:in `upload_file' > from c:/ruby/lib/ruby/1.8/net/http.rb:543:in `start' > from put_client.rb:21:in `upload_file' > from put_client.rb:31 > > > I've been looking on the engines for answers to this issue, both before > and after I posted, but it seems that whenever this has come up in the > past, the query has gone unanswered or was unrelated to this particular > problem. For posterity: as described and discussed here: http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-talk/229801 it turns out that threads and I/O don't mix in the One-Click Installer at this time. Neither, apparently, do they mix in the MinGW builds I made. Cygwin is not an option for me, so I will have to switch to a different language. Thanks anyway. -- Toby DiPasquale -- Posted via http://www.ruby-forum.com/.