Hi all,
I got the following error message when booting up my app (which works fine with Rails 3.0.0.beta4) in Rails 3.0.0.rc;
activesupport-3.0.0.rc/lib/active_support/file_update_checker.rb:27:in `stat': can't convert Array into String (TypeError)
When I put some debug code on that line I see the follwing array being passed;
["/Users/smath/.rvm/gems/ruby-1.8.7-p299/gems/activesupport-3.0.0.rc/ lib/active_support/locale/en.yml", "/Users/smath/.rvm/gems/ruby-1.8.7- p299/gems/activemodel-3.0.0.rc/lib/active_model/locale/en.yml", "/ Users/smath/.rvm/gems/ruby-1.8.7-p299/gems/activerecord-3.0.0.rc/lib/ active_record/locale/en.yml", "/Users/smath/.rvm/gems/ruby-1.8.7-p299/ gems/actionpack-3.0.0.rc/lib/action_view/locale/en.yml", ["/werkmap/ projects/skylight/twizzi2/config/locales/en.yml", "/werkmap/projects/ skylight/twizzi2/config/locales/fr.yml", "/werkmap/projects/skylight/ twizzi2/config/locales/nl.yml"], "/werkmap/projects/skylight/twizzi2/ config/locales/en.yml", "/werkmap/projects/skylight/twizzi2/config/ locales/fr.yml", "/werkmap/projects/skylight/twizzi2/config/locales/ nl.yml"]
If you look good, you see that my locales files (in the middle of the main array) are in a new array.
This middle-array is being passed into File.stat which can't handle arrays. So when I change line 25 in file_update_checker from;
paths.map { |path| File.stat(path).mtime }.max
to
paths.flatten.uniq.map { |path| File.stat(path).mtime }.max
All seems to work fine, however I don't know wheter that's a good fix or not.
I'm currently using rvm with ruby-1.8.7-p299.
Can someone verify this problem before I turn it into a ticket?
Thanks!
Stijn