Odd string error and fixnum's

1 view
Skip to first unread message

Josh

unread,
Dec 5, 2009, 12:32:00 AM12/5/09
to WebROaR - Ruby Application Server
Bug/error:
ActionView::TemplateError (can't convert Fixnum into String) on line
#148 of app/views/server/show.html.erb:
145: </tr>
146: <tr id="<%=Server.disk_color(@server.disk_size,
@server.disk_used, "used")%>">
147: <td>Used Diskspace</td>
148: <td><%=number_to_human_size(@server.disk_used)%></td>
149: </tr>
150: <tr id="data" class="even">
151: <td>Total Diskspace</td>
app/views/server/show.html.erb:148
webroar (0.2.4) src/ruby_lib/profiler/webroar_profiling.rb:65:in
`render'
app/controllers/server_controller.rb:46:in `show'
webroar (0.2.4) src/ruby_lib/profiler/webroar_profiling.rb:62:in
`perform_action'
webroar (0.2.4) src/ruby_lib/ruby_interface/./rack/adapter/
rails.rb:73:in `call'
webroar (0.2.4) src/ruby_lib/ruby_interface/deflater.rb:16:in
`call'
webroar (0.2.4) src/ruby_lib/ruby_interface/request_handler.rb:
37:in `process'

Seems to be specific to the way webroar is doing something, or did I
miss something?

For what its worth it was running fine on Mongrel, certain pages work
fine but when using number_to_human_size webroar dies....

Any incite would be appreciated -- everything else looks awesome so
far :)

Thanks in advance.

Aditya Babbar

unread,
Dec 7, 2009, 7:12:54 AM12/7/09
to web...@googlegroups.com
Josh,
Thank you for trying out WebROaR and reporting this issue. 

I have file Ticket #10 on Lighthouse for tracking it:

Right now it looks Math.log() called by number_to_human_size() is throwing this error. We would investigate the root cause and fix it soon.

Aditya

Aditya Babbar

unread,
Dec 10, 2009, 9:36:49 AM12/10/09
to web...@googlegroups.com
Josh,
We have fixed this issue and pushed the changes to Github repository. Could you please pull the latest code and try out your application on it?

We had defined one method called log using rb_define_singleton_method() and it was conflicting with the built-in method with the same name (log) called by Math.log invoked by number_to_human_size. We have renamed our method to log_message to prevent this collision. 

Thanks for reporting this issue and offering to look in to it!

Aditya

Josh Rendek

unread,
Dec 10, 2009, 10:01:51 AM12/10/09
to web...@googlegroups.com
Just saw the update in Lighthouse -- awesome job it works great ... gonna run some performance tests later and then hopefully throw it into production for a real go around :)

Josh
--
Josh Rendek
jo...@bluescripts.net
407.766.3134
Reply all
Reply to author
Forward
0 new messages