After updating from Rails 0.8 to 0.9.3 send_file doesn''t work anymore: send_file ''/tmp/normen.csv'', :type => ''application/csv'' fails with the following log entries: /usr/lib/ruby/gems/1.8/gems/actionpack-1.2.0/lib/action_controller/base.rb:451: warning: syswrite for buffered IO [Wed Jan 12 14:45:19 2005] [error] [client 127.0.0.1] malformed header from script. Bad header=Titel;Titel-Nr.;Bereich;Dokume: /home/pi/work/rails/normen/public/dispatch.cgi /usr/lib/ruby/gems/1.8/gems/actionpack-1.2.0/lib/action_controller/base.rb:451: warning: syswrite for buffered IO The malformed "header" is part of the first line of the file to send! Any ideas? Pirmin -- Pirmin Kalberer Sourcepole - Linux & Open Source Solutions http://www.sourcepole.com
No help here, but I''ve ben wrestling with the same error message as well. On Wed, 12 Jan 2005 14:55:50 +0100, Pirmin Kalberer <sp_ml-UQchlGytWBLZJqsBc5GL+g@public.gmane.org> wrote:> After updating from Rails 0.8 to 0.9.3 send_file doesn''t work anymore: > > send_file ''/tmp/normen.csv'', :type => ''application/csv'' > > fails with the following log entries: > > /usr/lib/ruby/gems/1.8/gems/actionpack-1.2.0/lib/action_controller/base.rb:451: warning: syswrite for buffered IO > [Wed Jan 12 14:45:19 2005] [error] [client 127.0.0.1] malformed header from script. Bad header=Titel;Titel-Nr.;Bereich;Dokume: /home/pi/work/rails/normen/public/dispatch.cgi > /usr/lib/ruby/gems/1.8/gems/actionpack-1.2.0/lib/action_controller/base.rb:451: warning: syswrite for buffered IO > > The malformed "header" is part of the first line of the file to send! > > Any ideas? > > Pirmin > > -- > Pirmin Kalberer > Sourcepole - Linux & Open Source Solutions > http://www.sourcepole.com > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails >
Of course as soon as I post that I do remember what I did to work around it, set :streaming => false in your send_file command. That is obviously not a real solution, but it will let you continue development. I''m also fairly sure this bug is in the entire .9x tree. On Wed, 12 Jan 2005 08:13:32 -0600, Tanner Burson <tanner.burson-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> No help here, but I''ve ben wrestling with the same error message as well. > > > On Wed, 12 Jan 2005 14:55:50 +0100, Pirmin Kalberer > <sp_ml-UQchlGytWBLZJqsBc5GL+g@public.gmane.org> wrote: > > After updating from Rails 0.8 to 0.9.3 send_file doesn''t work anymore: > > > > send_file ''/tmp/normen.csv'', :type => ''application/csv'' > > > > fails with the following log entries: > > > > /usr/lib/ruby/gems/1.8/gems/actionpack-1.2.0/lib/action_controller/base.rb:451: warning: syswrite for buffered IO > > [Wed Jan 12 14:45:19 2005] [error] [client 127.0.0.1] malformed header from script. Bad header=Titel;Titel-Nr.;Bereich;Dokume: /home/pi/work/rails/normen/public/dispatch.cgi > > /usr/lib/ruby/gems/1.8/gems/actionpack-1.2.0/lib/action_controller/base.rb:451: warning: syswrite for buffered IO > > > > The malformed "header" is part of the first line of the file to send! > > > > Any ideas? > > > > Pirmin > > > > -- > > Pirmin Kalberer > > Sourcepole - Linux & Open Source Solutions > > http://www.sourcepole.com > > _______________________________________________ > > Rails mailing list > > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > > http://lists.rubyonrails.org/mailman/listinfo/rails > > >
Am Mittwoch, 12. Januar 2005 15.15 schrieb Tanner Burson:> Of course as soon as I post that I do remember what I did to work > around it, set > > :streaming => falseI tried that too, but it didn''t help :-( -- Pirmin Kalberer Sourcepole - Linux & Open Source Solutions http://www.sourcepole.com