I get Ruby on Rails created on a new Snow Leopard installation. After the battle (and beating ) of MySQL and Sphinx issues, I was stuck in a silly HAML related error.
Essentially, I get the missing template error for each view using HAML. I can add an empty xxx.html.erb file, and the (empty) page loads fine. But xxx.html.haml throws an error, although this file definitely exists in the corresponding directory.
Here is the development server error:
ActionView::MissingTemplate (Missing template sections/index.erb in view path app/views):
haml (2.2.4) rails/./lib/sass/plugin/rails.rb:19:in `process'
I am using the haml gem (2.2.4), the rail harness (2.3.4) and the ruby โโ1.8.7. I launched haml -rails. from the root directory of the RoR root directory; The init file is located in the vendor / plugins / haml directory. I confirmed that "require" haml '"=> true via IRB.
Any help would be appreciated!
In response to Yaraher:
I tried to reinstall and reinstall, which did not cause errors, except using rdocs ("Could not find the main page README.rdoc").
In script / console:
>> require 'haml'
=> []
Update:
Installing an old version of Rails, which is known to work with HAML in this project, seems to have "fixed" the problem. I would still be interested to hear the real answer to this problem - I do not want to get stuck in 2.3.2.
sudo gem install -v 2.3.2 rails
Update 2:
This is definitely caused by the difference between Rails 2.3.2 and 2.3.4. When installing both stones, I can install which is used in my environment.rb file. HAML works fine with 2.3.2 and breaks as described in 2.3.4.
source
share