Hi, first off thanks Ezra for Merb - it''s certainly interesting and I''m keen to have a play. However, I''m having difficulties in getting started. I''ve followed the docs for setting up mrblog and everything seems to be installed correctly, and merb appears to start fine: $ merb you must install the markaby gem to use .mab templates you must install the haml gem to use .haml templates ActiveRecord session mixed in Rails session compatibilty on. Compiling routes.. merb init called Merb started with these options: --- :dist_root: /path/to/merb/mrblog/dist :allow_reloading: true :environment: development :merb_root: /path/to/merb/mrblog :cache_templates: true :use_mutex: true :config: dist/conf/mup.conf :host: 127.0.0.1 :show_error: true :port: "4000" :sql_session: true However any request to 127.0.0.1:4000 returns: Mon May 14 17:55:30 BST 2007: ERROR: undefined method `each'' for #<MerbUploadHandler:0x234bcfc> with nothing in the browser or in the log. Similarly, using a newly generated test app, I get: Mon May 14 17:56:27 BST 2007: ERROR: undefined method `each'' for nil:NilClass I''ve tried both installing via gem and from trunk. Without a trace and a line number it''s hard to know where to start. Am I missing something really obvious here? It''s been known to happen before... Any help much appreciated! Cheers, Mike
Mike- What version of mongrel do you have installed? This error looks like you have an outdated mongrel. Install mongrel 1.0.1 an d this will go away. Cheers- -Ezra On May 14, 2007, at 10:16 AM, Mike Evans wrote:> Hi, first off thanks Ezra for Merb - it''s certainly interesting and > I''m keen to have a play. However, I''m having difficulties in getting > started. I''ve followed the docs for setting up mrblog and everything > seems to be installed correctly, and merb appears to start fine: > > $ merb > you must install the markaby gem to use .mab templates > you must install the haml gem to use .haml templates > ActiveRecord session mixed in > Rails session compatibilty on. > Compiling routes.. > merb init called > Merb started with these options: > --- > :dist_root: /path/to/merb/mrblog/dist > :allow_reloading: true > :environment: development > :merb_root: /path/to/merb/mrblog > :cache_templates: true > :use_mutex: true > :config: dist/conf/mup.conf > :host: 127.0.0.1 > :show_error: true > :port: "4000" > :sql_session: true > > > However any request to 127.0.0.1:4000 returns: > > Mon May 14 17:55:30 BST 2007: ERROR: undefined method `each'' for > #<MerbUploadHandler:0x234bcfc> > > with nothing in the browser or in the log. Similarly, using a newly > generated test app, I get: > > Mon May 14 17:56:27 BST 2007: ERROR: undefined method `each'' for > nil:NilClass > > > I''ve tried both installing via gem and from trunk. Without a trace > and a line number it''s hard to know where to start. Am I missing > something really obvious here? It''s been known to happen before... > Any help much appreciated! > > Cheers, > Mike > _______________________________________________ > Merb-devel mailing list > Merb-devel at rubyforge.org > http://rubyforge.org/mailman/listinfo/merb-devel-- Ezra Zygmuntowicz -- Lead Rails Evangelist -- ez at engineyard.com -- Engine Yard, Serious Rails Hosting -- (866) 518-YARD (9273)
Thanks Ezra, that''s it - with the latest Mongrel it''s all good. Onwards and upwards! Mike On 14 May 2007, at 19:30, Ezra Zygmuntowicz wrote:> Mike- > > What version of mongrel do you have installed? This error looks > like you have an outdated mongrel. Install mongrel 1.0.1 an d this > will go away. > > Cheers- > > -Ezra > > > On May 14, 2007, at 10:16 AM, Mike Evans wrote: > >> Hi, first off thanks Ezra for Merb - it''s certainly interesting and >> I''m keen to have a play. However, I''m having difficulties in getting >> started. I''ve followed the docs for setting up mrblog and everything >> seems to be installed correctly, and merb appears to start fine: >> >> $ merb >> you must install the markaby gem to use .mab templates >> you must install the haml gem to use .haml templates >> ActiveRecord session mixed in >> Rails session compatibilty on. >> Compiling routes.. >> merb init called >> Merb started with these options: >> --- >> :dist_root: /path/to/merb/mrblog/dist >> :allow_reloading: true >> :environment: development >> :merb_root: /path/to/merb/mrblog >> :cache_templates: true >> :use_mutex: true >> :config: dist/conf/mup.conf >> :host: 127.0.0.1 >> :show_error: true >> :port: "4000" >> :sql_session: true >> >> >> However any request to 127.0.0.1:4000 returns: >> >> Mon May 14 17:55:30 BST 2007: ERROR: undefined method `each'' for >> #<MerbUploadHandler:0x234bcfc> >> >> with nothing in the browser or in the log. Similarly, using a newly >> generated test app, I get: >> >> Mon May 14 17:56:27 BST 2007: ERROR: undefined method `each'' for >> nil:NilClass >> >> >> I''ve tried both installing via gem and from trunk. Without a trace >> and a line number it''s hard to know where to start. Am I missing >> something really obvious here? It''s been known to happen before... >> Any help much appreciated! >> >> Cheers, >> Mike >> _______________________________________________ >> Merb-devel mailing list >> Merb-devel at rubyforge.org >> http://rubyforge.org/mailman/listinfo/merb-devel > > -- Ezra Zygmuntowicz-- Lead Rails Evangelist > -- ez at engineyard.com > -- Engine Yard, Serious Rails Hosting > -- (866) 518-YARD (9273) > >
Sorry to bug everyone with newbie questions today but hopefully this one is more substantial than the last. I''m trying to get a handle on the upload progress code as found in the mrblog example. Firstly, I found that the progress bar isn''t displayed given the current code in trunk, as its CSS and the link to mup.js in views/files/start.herb are inside <% throw_content :header %>, but the files/start action is rendered without a layout. Removing either the throw_content or the :layout => :none in the controller solves this. However, for me the bar stays on 0% until the upload is complete, at which point it jumps to 100%. When uploading a 350Mb file locally, it appears that although the periodic polling occurs, the upload is considered to be finished almost immediately it begins: 1179176946: Added 1179176946: Marking 1179176946: Marking 1179176946: Marking 1179176946: Added 1179176946: Finished {"action"=>"progress", "controller"=>"files", "upload_id"=>"1179176946"} 1179176946: Added 1179176946: Finished {"action"=>"progress", "controller"=>"files", "upload_id"=>"1179176946"} 1179176946: Added 1179176946: Finished {"action"=>"progress", "controller"=>"files", "upload_id"=>"1179176946"} ... In reality, the upload takes a couple of minutes. (Even copying the file locally takes more than a minute.) Can anyone point me in the right direction? I''m not sure where the Mongrel::Upload class is defined - I can see that the debug output above is coming from merb-0.3.1/lib/merb/merb_upload_progress.rb as required in merb_upload_handler.rb, but I don''t understand how request_progress is called to update the :size and :received counters, nor why the upload is treated as over almost before it starts. I''m testing on ruby 1.8.6 on Mac OS X 10.4.9 with Mongrel 1.0.1. Thanks for any help, Mike On 14 May 2007, at 19:30, Ezra Zygmuntowicz wrote:> Mike- > > What version of mongrel do you have installed? This error looks > like you have an outdated mongrel. Install mongrel 1.0.1 an d this > will go away. > > Cheers- > > -Ezra > > > On May 14, 2007, at 10:16 AM, Mike Evans wrote: > >> Hi, first off thanks Ezra for Merb - it''s certainly interesting and >> I''m keen to have a play. However, I''m having difficulties in getting >> started. I''ve followed the docs for setting up mrblog and everything >> seems to be installed correctly, and merb appears to start fine: >> >> $ merb >> you must install the markaby gem to use .mab templates >> you must install the haml gem to use .haml templates >> ActiveRecord session mixed in >> Rails session compatibilty on. >> Compiling routes.. >> merb init called >> Merb started with these options: >> --- >> :dist_root: /path/to/merb/mrblog/dist >> :allow_reloading: true >> :environment: development >> :merb_root: /path/to/merb/mrblog >> :cache_templates: true >> :use_mutex: true >> :config: dist/conf/mup.conf >> :host: 127.0.0.1 >> :show_error: true >> :port: "4000" >> :sql_session: true >> >> >> However any request to 127.0.0.1:4000 returns: >> >> Mon May 14 17:55:30 BST 2007: ERROR: undefined method `each'' for >> #<MerbUploadHandler:0x234bcfc> >> >> with nothing in the browser or in the log. Similarly, using a newly >> generated test app, I get: >> >> Mon May 14 17:56:27 BST 2007: ERROR: undefined method `each'' for >> nil:NilClass >> >> >> I''ve tried both installing via gem and from trunk. Without a trace >> and a line number it''s hard to know where to start. Am I missing >> something really obvious here? It''s been known to happen before... >> Any help much appreciated! >> >> Cheers, >> Mike >> _______________________________________________ >> Merb-devel mailing list >> Merb-devel at rubyforge.org >> http://rubyforge.org/mailman/listinfo/merb-devel > > -- Ezra Zygmuntowicz-- Lead Rails Evangelist > -- ez at engineyard.com > -- Engine Yard, Serious Rails Hosting > -- (866) 518-YARD (9273) > >
We''re currently investigating this issue right now. If you''re on trunk this is an unresolved bug. If you want a progress indicator you should checkout rev 222. cheerio, Rogelio On 5/14/07, Mike Evans <mike at harmonypark.net> wrote:> > Sorry to bug everyone with newbie questions today but hopefully this > one is more substantial than the last. I''m trying to get a handle on > the upload progress code as found in the mrblog example. Firstly, I > found that the progress bar isn''t displayed given the current code in > trunk, as its CSS and the link to mup.js in views/files/start.herb > are inside <% throw_content :header %>, but the files/start action is > rendered without a layout. Removing either the throw_content or > the :layout => :none in the controller solves this. > > However, for me the bar stays on 0% until the upload is complete, at > which point it jumps to 100%. When uploading a 350Mb file locally, it > appears that although the periodic polling occurs, the upload is > considered to be finished almost immediately it begins: > > 1179176946: Added > 1179176946: Marking > 1179176946: Marking > 1179176946: Marking > 1179176946: Added > 1179176946: Finished > {"action"=>"progress", "controller"=>"files", "upload_id"=>"1179176946"} > 1179176946: Added > 1179176946: Finished > {"action"=>"progress", "controller"=>"files", "upload_id"=>"1179176946"} > 1179176946: Added > 1179176946: Finished > {"action"=>"progress", "controller"=>"files", "upload_id"=>"1179176946"} > ... > > In reality, the upload takes a couple of minutes. (Even copying the > file locally takes more than a minute.) > > Can anyone point me in the right direction? I''m not sure where the > Mongrel::Upload class is defined - I can see that the debug output > above is coming from merb-0.3.1/lib/merb/merb_upload_progress.rb as > required in merb_upload_handler.rb, but I don''t understand how > request_progress is called to update the :size and :received > counters, nor why the upload is treated as over almost before it starts. > > I''m testing on ruby 1.8.6 on Mac OS X 10.4.9 with Mongrel 1.0.1. > > Thanks for any help, > Mike > > > On 14 May 2007, at 19:30, Ezra Zygmuntowicz wrote: > > > Mike- > > > > What version of mongrel do you have installed? This error looks > > like you have an outdated mongrel. Install mongrel 1.0.1 an d this > > will go away. > > > > Cheers- > > > > -Ezra > > > > > > On May 14, 2007, at 10:16 AM, Mike Evans wrote: > > > >> Hi, first off thanks Ezra for Merb - it''s certainly interesting and > >> I''m keen to have a play. However, I''m having difficulties in getting > >> started. I''ve followed the docs for setting up mrblog and everything > >> seems to be installed correctly, and merb appears to start fine: > >> > >> $ merb > >> you must install the markaby gem to use .mab templates > >> you must install the haml gem to use .haml templates > >> ActiveRecord session mixed in > >> Rails session compatibilty on. > >> Compiling routes.. > >> merb init called > >> Merb started with these options: > >> --- > >> :dist_root: /path/to/merb/mrblog/dist > >> :allow_reloading: true > >> :environment: development > >> :merb_root: /path/to/merb/mrblog > >> :cache_templates: true > >> :use_mutex: true > >> :config: dist/conf/mup.conf > >> :host: 127.0.0.1 > >> :show_error: true > >> :port: "4000" > >> :sql_session: true > >> > >> > >> However any request to 127.0.0.1:4000 returns: > >> > >> Mon May 14 17:55:30 BST 2007: ERROR: undefined method `each'' for > >> #<MerbUploadHandler:0x234bcfc> > >> > >> with nothing in the browser or in the log. Similarly, using a newly > >> generated test app, I get: > >> > >> Mon May 14 17:56:27 BST 2007: ERROR: undefined method `each'' for > >> nil:NilClass > >> > >> > >> I''ve tried both installing via gem and from trunk. Without a trace > >> and a line number it''s hard to know where to start. Am I missing > >> something really obvious here? It''s been known to happen before... > >> Any help much appreciated! > >> > >> Cheers, > >> Mike > >> _______________________________________________ > >> Merb-devel mailing list > >> Merb-devel at rubyforge.org > >> http://rubyforge.org/mailman/listinfo/merb-devel > > > > -- Ezra Zygmuntowicz-- Lead Rails Evangelist > > -- ez at engineyard.com > > -- Engine Yard, Serious Rails Hosting > > -- (866) 518-YARD (9273) > > > > > > _______________________________________________ > Merb-devel mailing list > Merb-devel at rubyforge.org > http://rubyforge.org/mailman/listinfo/merb-devel >-------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/merb-devel/attachments/20070514/f925db16/attachment.html
Nice one, thanks Rogelio - the progress bar in rev 222 works as expected. Cheers, Mike On 15 May 2007, at 03:21, Rogelio J. Samour wrote:> We''re currently investigating this issue right now. If you''re on > trunk this is an unresolved bug. > > If you want a progress indicator you should checkout rev 222. > > cheerio, > > Rogelio > > On 5/14/07, Mike Evans <mike at harmonypark.net> wrote: > Sorry to bug everyone with newbie questions today but hopefully this > one is more substantial than the last. I''m trying to get a handle on > the upload progress code as found in the mrblog example. Firstly, I > found that the progress bar isn''t displayed given the current code in > trunk, as its CSS and the link to mup.js in views/files/start.herb > are inside <% throw_content :header %>, but the files/start action is > rendered without a layout. Removing either the throw_content or > the :layout => :none in the controller solves this. > > However, for me the bar stays on 0% until the upload is complete, at > which point it jumps to 100%. When uploading a 350Mb file locally, it > appears that although the periodic polling occurs, the upload is > considered to be finished almost immediately it begins: > > 1179176946: Added > 1179176946: Marking > 1179176946: Marking > 1179176946: Marking > 1179176946: Added > 1179176946: Finished > {"action"=>"progress", "controller"=>"files", > "upload_id"=>"1179176946"} > 1179176946: Added > 1179176946: Finished > {"action"=>"progress", "controller"=>"files", > "upload_id"=>"1179176946"} > 1179176946: Added > 1179176946: Finished > {"action"=>"progress", "controller"=>"files", > "upload_id"=>"1179176946"} > ... > > In reality, the upload takes a couple of minutes. (Even copying the > file locally takes more than a minute.) > > Can anyone point me in the right direction? I''m not sure where the > Mongrel::Upload class is defined - I can see that the debug output > above is coming from merb-0.3.1 /lib/merb/merb_upload_progress.rb as > required in merb_upload_handler.rb, but I don''t understand how > request_progress is called to update the :size and :received > counters, nor why the upload is treated as over almost before it > starts. > > I''m testing on ruby 1.8.6 on Mac OS X 10.4.9 with Mongrel 1.0.1. > > Thanks for any help, > Mike > > > On 14 May 2007, at 19:30, Ezra Zygmuntowicz wrote: > > > Mike- > > > > What version of mongrel do you have installed? This error > looks > > like you have an outdated mongrel. Install mongrel 1.0.1 an d this > > will go away. > > > > Cheers- > > > > -Ezra > > > > > > On May 14, 2007, at 10:16 AM, Mike Evans wrote: > > > >> Hi, first off thanks Ezra for Merb - it''s certainly interesting and > >> I''m keen to have a play. However, I''m having difficulties in > getting > >> started. I''ve followed the docs for setting up mrblog and > everything > >> seems to be installed correctly, and merb appears to start fine: > >> > >> $ merb > >> you must install the markaby gem to use .mab templates > >> you must install the haml gem to use .haml templates > >> ActiveRecord session mixed in > >> Rails session compatibilty on. > >> Compiling routes.. > >> merb init called > >> Merb started with these options: > >> --- > >> :dist_root: /path/to/merb/mrblog/dist > >> :allow_reloading: true > >> :environment: development > >> :merb_root: /path/to/merb/mrblog > >> :cache_templates: true > >> :use_mutex: true > >> :config: dist/conf/mup.conf > >> :host: 127.0.0.1 > >> :show_error: true > >> :port: "4000" > >> :sql_session: true > >> > >> > >> However any request to 127.0.0.1:4000 returns: > >> > >> Mon May 14 17:55:30 BST 2007: ERROR: undefined method `each'' for > >> #<MerbUploadHandler:0x234bcfc> > >> > >> with nothing in the browser or in the log. Similarly, using a newly > >> generated test app, I get: > >> > >> Mon May 14 17:56:27 BST 2007: ERROR: undefined method `each'' for > >> nil:NilClass > >> > >> > >> I''ve tried both installing via gem and from trunk. Without a trace > >> and a line number it''s hard to know where to start. Am I missing > >> something really obvious here? It''s been known to happen before... > >> Any help much appreciated! > >> > >> Cheers, > >> Mike > >> _______________________________________________ > >> Merb-devel mailing list > >> Merb-devel at rubyforge.org > >> http://rubyforge.org/mailman/listinfo/merb-devel > > > > -- Ezra Zygmuntowicz-- Lead Rails Evangelist > > -- ez at engineyard.com > > -- Engine Yard, Serious Rails Hosting > > -- (866) 518-YARD (9273) > > > > > > _______________________________________________ > Merb-devel mailing list > Merb-devel at rubyforge.org > http://rubyforge.org/mailman/listinfo/merb-devel > > _______________________________________________ > Merb-devel mailing list > Merb-devel at rubyforge.org > http://rubyforge.org/mailman/listinfo/merb-devel-------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/merb-devel/attachments/20070515/677e0e6a/attachment-0001.html
Hi Mike, i''ve just tried mrblog revision222 and wonder if you had to modify anything other than dist/conf/merb_init.rb and dist/conf/merb.yml to get the upload progress to work? thanks, greg On May 15, 2007, at 10:03 AM, Mike Evans wrote:> Nice one, thanks Rogelio - the progress bar in rev 222 works as > expected. > > Cheers, > Mike > > On 15 May 2007, at 03:21, Rogelio J. Samour wrote: > >> We''re currently investigating this issue right now. If you''re on >> trunk this is an unresolved bug. >> >> If you want a progress indicator you should checkout rev 222. >> >> cheerio, >> >> Rogelio >> >> On 5/14/07, Mike Evans <mike at harmonypark.net> wrote: >> Sorry to bug everyone with newbie questions today but hopefully this >> one is more substantial than the last. I''m trying to get a handle on >> the upload progress code as found in the mrblog example. Firstly, I >> found that the progress bar isn''t displayed given the current code in >> trunk, as its CSS and the link to mup.js in views/files/start.herb >> are inside <% throw_content :header %>, but the files/start action is >> rendered without a layout. Removing either the throw_content or >> the :layout => :none in the controller solves this. >> >> However, for me the bar stays on 0% until the upload is complete, at >> which point it jumps to 100%. When uploading a 350Mb file locally, it >> appears that although the periodic polling occurs, the upload is >> considered to be finished almost immediately it begins: >> >> 1179176946: Added >> 1179176946: Marking >> 1179176946: Marking >> 1179176946: Marking >> 1179176946: Added >> 1179176946: Finished >> {"action"=>"progress", "controller"=>"files", >> "upload_id"=>"1179176946"} >> 1179176946: Added >> 1179176946: Finished >> {"action"=>"progress", "controller"=>"files", >> "upload_id"=>"1179176946"} >> 1179176946: Added >> 1179176946: Finished >> {"action"=>"progress", "controller"=>"files", >> "upload_id"=>"1179176946"} >> ... >> >> In reality, the upload takes a couple of minutes. (Even copying the >> file locally takes more than a minute.) >> >> Can anyone point me in the right direction? I''m not sure where the >> Mongrel::Upload class is defined - I can see that the debug output >> above is coming from merb-0.3.1 /lib/merb/merb_upload_progress.rb as >> required in merb_upload_handler.rb, but I don''t understand how >> request_progress is called to update the :size and :received >> counters, nor why the upload is treated as over almost before it >> starts. >> >> I''m testing on ruby 1.8.6 on Mac OS X 10.4.9 with Mongrel 1.0.1. >> >> Thanks for any help, >> Mike >> >> >> On 14 May 2007, at 19:30, Ezra Zygmuntowicz wrote: >> >> > Mike- >> > >> > What version of mongrel do you have installed? This error >> looks >> > like you have an outdated mongrel. Install mongrel 1.0.1 an d this >> > will go away. >> > >> > Cheers- >> > >> > -Ezra >> > >> > >> > On May 14, 2007, at 10:16 AM, Mike Evans wrote: >> > >> >> Hi, first off thanks Ezra for Merb - it''s certainly interesting >> and >> >> I''m keen to have a play. However, I''m having difficulties in >> getting >> >> started. I''ve followed the docs for setting up mrblog and >> everything >> >> seems to be installed correctly, and merb appears to start fine: >> >> >> >> $ merb >> >> you must install the markaby gem to use .mab templates >> >> you must install the haml gem to use .haml templates >> >> ActiveRecord session mixed in >> >> Rails session compatibilty on. >> >> Compiling routes.. >> >> merb init called >> >> Merb started with these options: >> >> --- >> >> :dist_root: /path/to/merb/mrblog/dist >> >> :allow_reloading: true >> >> :environment: development >> >> :merb_root: /path/to/merb/mrblog >> >> :cache_templates: true >> >> :use_mutex: true >> >> :config: dist/conf/mup.conf >> >> :host: 127.0.0.1 >> >> :show_error: true >> >> :port: "4000" >> >> :sql_session: true >> >> >> >> >> >> However any request to 127.0.0.1:4000 returns: >> >> >> >> Mon May 14 17:55:30 BST 2007: ERROR: undefined method `each'' for >> >> #<MerbUploadHandler:0x234bcfc> >> >> >> >> with nothing in the browser or in the log. Similarly, using a >> newly >> >> generated test app, I get: >> >> >> >> Mon May 14 17:56:27 BST 2007: ERROR: undefined method `each'' for >> >> nil:NilClass >> >> >> >> >> >> I''ve tried both installing via gem and from trunk. Without a trace >> >> and a line number it''s hard to know where to start. Am I missing >> >> something really obvious here? It''s been known to happen before... >> >> Any help much appreciated! >> >> >> >> Cheers, >> >> Mike >> >> _______________________________________________ >> >> Merb-devel mailing list >> >> Merb-devel at rubyforge.org >> >> http://rubyforge.org/mailman/listinfo/merb-devel >> > >> > -- Ezra Zygmuntowicz-- Lead Rails Evangelist >> > -- ez at engineyard.com >> > -- Engine Yard, Serious Rails Hosting >> > -- (866) 518-YARD (9273) >> > >> > >> >> _______________________________________________ >> Merb-devel mailing list >> Merb-devel at rubyforge.org >> http://rubyforge.org/mailman/listinfo/merb-devel >> >> _______________________________________________ >> Merb-devel mailing list >> Merb-devel at rubyforge.org >> http://rubyforge.org/mailman/listinfo/merb-devel > > _______________________________________________ > Merb-devel mailing list > Merb-devel at rubyforge.org > http://rubyforge.org/mailman/listinfo/merb-devel-------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/merb-devel/attachments/20070515/92b0ee08/attachment.html
Hi Greg, yes, because the start action in the files controller has no layout, the mup.js javascript is not being included. Without this, the progress bar isn''t displayed at all, even at 0%. So you have to either remove :layout => :none from the start action in controllers/ files.rb, or remove the <% throw_content :header %><% end %> wrapper around the CSS and javascript include in views/files/start.herb. Cheers, Mike On 15 May 2007, at 20:24, Gregory O''Connor wrote:> Hi Mike, > i''ve just tried mrblog revision222 and wonder if you had to modify > anything other than dist/conf/merb_init.rb and dist/conf/merb.yml > to get the upload progress to work? > thanks, > greg > > On May 15, 2007, at 10:03 AM, Mike Evans wrote: > >> Nice one, thanks Rogelio - the progress bar in rev 222 works as >> expected. >> >> Cheers, >> Mike >> >> On 15 May 2007, at 03:21, Rogelio J. Samour wrote: >> >>> We''re currently investigating this issue right now. If you''re on >>> trunk this is an unresolved bug. >>> >>> If you want a progress indicator you should checkout rev 222. >>> >>> cheerio, >>> >>> Rogelio >>> >>> On 5/14/07, Mike Evans <mike at harmonypark.net> wrote: >>> Sorry to bug everyone with newbie questions today but hopefully this >>> one is more substantial than the last. I''m trying to get a handle on >>> the upload progress code as found in the mrblog example. Firstly, I >>> found that the progress bar isn''t displayed given the current >>> code in >>> trunk, as its CSS and the link to mup.js in views/files/start.herb >>> are inside <% throw_content :header %>, but the files/start >>> action is >>> rendered without a layout. Removing either the throw_content or >>> the :layout => :none in the controller solves this. >>> >>> However, for me the bar stays on 0% until the upload is complete, at >>> which point it jumps to 100%. When uploading a 350Mb file >>> locally, it >>> appears that although the periodic polling occurs, the upload is >>> considered to be finished almost immediately it begins: >>> >>> 1179176946: Added >>> 1179176946: Marking >>> 1179176946: Marking >>> 1179176946: Marking >>> 1179176946: Added >>> 1179176946: Finished >>> {"action"=>"progress", "controller"=>"files", >>> "upload_id"=>"1179176946"} >>> 1179176946: Added >>> 1179176946: Finished >>> {"action"=>"progress", "controller"=>"files", >>> "upload_id"=>"1179176946"} >>> 1179176946: Added >>> 1179176946: Finished >>> {"action"=>"progress", "controller"=>"files", >>> "upload_id"=>"1179176946"} >>> ... >>> >>> In reality, the upload takes a couple of minutes. (Even copying the >>> file locally takes more than a minute.) >>> >>> Can anyone point me in the right direction? I''m not sure where the >>> Mongrel::Upload class is defined - I can see that the debug output >>> above is coming from merb-0.3.1 /lib/merb/merb_upload_progress.rb as >>> required in merb_upload_handler.rb, but I don''t understand how >>> request_progress is called to update the :size and :received >>> counters, nor why the upload is treated as over almost before it >>> starts. >>> >>> I''m testing on ruby 1.8.6 on Mac OS X 10.4.9 with Mongrel 1.0.1. >>> >>> Thanks for any help, >>> Mike >>> >>> >>> On 14 May 2007, at 19:30, Ezra Zygmuntowicz wrote: >>> >>> > Mike- >>> > >>> > What version of mongrel do you have installed? This error >>> looks >>> > like you have an outdated mongrel. Install mongrel 1.0.1 an d this >>> > will go away. >>> > >>> > Cheers- >>> > >>> > -Ezra >>> > >>> > >>> > On May 14, 2007, at 10:16 AM, Mike Evans wrote: >>> > >>> >> Hi, first off thanks Ezra for Merb - it''s certainly >>> interesting and >>> >> I''m keen to have a play. However, I''m having difficulties in >>> getting >>> >> started. I''ve followed the docs for setting up mrblog and >>> everything >>> >> seems to be installed correctly, and merb appears to start fine: >>> >> >>> >> $ merb >>> >> you must install the markaby gem to use .mab templates >>> >> you must install the haml gem to use .haml templates >>> >> ActiveRecord session mixed in >>> >> Rails session compatibilty on. >>> >> Compiling routes.. >>> >> merb init called >>> >> Merb started with these options: >>> >> --- >>> >> :dist_root: /path/to/merb/mrblog/dist >>> >> :allow_reloading: true >>> >> :environment: development >>> >> :merb_root: /path/to/merb/mrblog >>> >> :cache_templates: true >>> >> :use_mutex: true >>> >> :config: dist/conf/mup.conf >>> >> :host: 127.0.0.1 >>> >> :show_error: true >>> >> :port: "4000" >>> >> :sql_session: true >>> >> >>> >> >>> >> However any request to 127.0.0.1:4000 returns: >>> >> >>> >> Mon May 14 17:55:30 BST 2007: ERROR: undefined method `each'' for >>> >> #<MerbUploadHandler:0x234bcfc> >>> >> >>> >> with nothing in the browser or in the log. Similarly, using a >>> newly >>> >> generated test app, I get: >>> >> >>> >> Mon May 14 17:56:27 BST 2007: ERROR: undefined method `each'' for >>> >> nil:NilClass >>> >> >>> >> >>> >> I''ve tried both installing via gem and from trunk. Without a >>> trace >>> >> and a line number it''s hard to know where to start. Am I missing >>> >> something really obvious here? It''s been known to happen >>> before... >>> >> Any help much appreciated! >>> >> >>> >> Cheers, >>> >> Mike >>> >> _______________________________________________ >>> >> Merb-devel mailing list >>> >> Merb-devel at rubyforge.org >>> >> http://rubyforge.org/mailman/listinfo/merb-devel >>> > >>> > -- Ezra Zygmuntowicz-- Lead Rails Evangelist >>> > -- ez at engineyard.com >>> > -- Engine Yard, Serious Rails Hosting >>> > -- (866) 518-YARD (9273) >>> > >>> > >>> >>> _______________________________________________ >>> Merb-devel mailing list >>> Merb-devel at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/merb-devel >>> >>> _______________________________________________ >>> Merb-devel mailing list >>> Merb-devel at rubyforge.org >>> http://rubyforge.org/mailman/listinfo/merb-devel >> >> _______________________________________________ >> Merb-devel mailing list >> Merb-devel at rubyforge.org >> http://rubyforge.org/mailman/listinfo/merb-devel >-------------- next part -------------- An HTML attachment was scrubbed... URL: http://rubyforge.org/pipermail/merb-devel/attachments/20070515/cd47d025/attachment-0001.html