1

I keep getting this error with the ember-rails gem:

ERROR -- : undefined method `ember' for #<Rails::Application::Configuration:0x007f14d10deb88> (NoMethodError)
/home/deploy/apps/gastos/shared/bundle/ruby/2.0.0/gems/railties-4.0.0/lib/rails/railtie/configuration.rb:95:in `method_missing'
/home/deploy/apps/gastos/releases/20130914034514/config/environments/staging.rb:81:in `block in <top (required)>'
/home/deploy/apps/gastos/shared/bundle/ruby/2.0.0/gems/railties-4.0.0/lib/rails/railtie/configurable.rb:24:in `class_eval'
/home/deploy/apps/gastos/shared/bundle/ruby/2.0.0/gems/railties-4.0.0/lib/rails/railtie/configurable.rb:24:in `configure'
/home/deploy/apps/gastos/releases/20130914034514/config/environments/staging.rb:1:in `<top (required)>'
/home/deploy/apps/gastos/shared/bundle/ruby/2.0.0/gems/activesupport-4.0.0/lib/active_support/dependencies.rb:228:in `require'
/home/deploy/apps/gastos/shared/bundle/ruby/2.0.0/gems/activesupport-4.0.0/lib/active_support/dependencies.rb:228:in `block in require'
/home/deploy/apps/gastos/shared/bundle/ruby/2.0.0/gems/activesupport-4.0.0/lib/active_support/dependencies.rb:213:in `load_dependency'
/home/deploy/apps/gastos/shared/bundle/ruby/2.0.0/gems/activesupport-4.0.0/lib/active_support/dependencies.rb:228:in `require'
/home/deploy/apps/gastos/shared/bundle/ruby/2.0.0/gems/railties-4.0.0/lib/rails/engine.rb:591:in `block (2 levels) in <class:Engine>'
/home/deploy/apps/gastos/shared/bundle/ruby/2.0.0/gems/railties-4.0.0/lib/rails/engine.rb:590:in `each'
/home/deploy/apps/gastos/shared/bundle/ruby/2.0.0/gems/railties-4.0.0/lib/rails/engine.rb:590:in `block in <class:Engine>'
/home/deploy/apps/gastos/shared/bundle/ruby/2.0.0/gems/railties-4.0.0/lib/rails/initializable.rb:30:in `instance_exec'
/home/deploy/apps/gastos/shared/bundle/ruby/2.0.0/gems/railties-4.0.0/lib/rails/initializable.rb:30:in `run'
/home/deploy/apps/gastos/shared/bundle/ruby/2.0.0/gems/railties-4.0.0/lib/rails/initializable.rb:55:in `block in run_initializers'
/home/deploy/.rbenv/versions/2.0.0-p247/lib/ruby/2.0.0/tsort.rb:150:in `block in tsort_each'
/home/deploy/.rbenv/versions/2.0.0-p247/lib/ruby/2.0.0/tsort.rb:183:in `block (2 levels) in each_strongly_connected_component'
/home/deploy/.rbenv/versions/2.0.0-p247/lib/ruby/2.0.0/tsort.rb:210:in `block (2 levels) in each_strongly_connected_component_from'
/home/deploy/.rbenv/versions/2.0.0-p247/lib/ruby/2.0.0/tsort.rb:219:in `each_strongly_connected_component_from'
/home/deploy/.rbenv/versions/2.0.0-p247/lib/ruby/2.0.0/tsort.rb:209:in `block in each_strongly_connected_component_from'
/home/deploy/apps/gastos/shared/bundle/ruby/2.0.0/gems/railties-4.0.0/lib/rails/initializable.rb:44:in `each'
/home/deploy/apps/gastos/shared/bundle/ruby/2.0.0/gems/railties-4.0.0/lib/rails/initializable.rb:44:in `tsort_each_child'
/home/deploy/.rbenv/versions/2.0.0-p247/lib/ruby/2.0.0/tsort.rb:203:in `each_strongly_connected_component_from'
/home/deploy/.rbenv/versions/2.0.0-p247/lib/ruby/2.0.0/tsort.rb:182:in `block in each_strongly_connected_component'
/home/deploy/.rbenv/versions/2.0.0-p247/lib/ruby/2.0.0/tsort.rb:180:in `each'
/home/deploy/.rbenv/versions/2.0.0-p247/lib/ruby/2.0.0/tsort.rb:180:in `each_strongly_connected_component'
/home/deploy/.rbenv/versions/2.0.0-p247/lib/ruby/2.0.0/tsort.rb:148:in `tsort_each'
/home/deploy/apps/gastos/shared/bundle/ruby/2.0.0/gems/railties-4.0.0/lib/rails/initializable.rb:54:in `run_initializers'
/home/deploy/apps/gastos/shared/bundle/ruby/2.0.0/gems/railties-4.0.0/lib/rails/application.rb:215:in `initialize!'
/home/deploy/apps/gastos/shared/bundle/ruby/2.0.0/gems/railties-4.0.0/lib/rails/railtie/configurable.rb:30:in `method_missing'
/home/deploy/apps/gastos/releases/20130914034514/config/environment.rb:5:in `<top (required)>'

I've placed the configuration for ember in my environment file (staging.rb) like so:

config.ember.variant = :production

The only clue that I've gotten from Google so far was this issue on Github where the solution was to take out ember-rails from the :assets group. I'm using Rails 4 already, so I don't even have an :assets group in the first place. I should also point out that I've already setup my application to use a staging environment, so I'm certain that the problem doesn't have anything to do with its current Rails environment.

Has anyone else solved this problem already? Am I just missing something?

3
  • Currently having the same issue. Did you figure it out? Commented Feb 3, 2014 at 14:30
  • Yup, it turns out I just had to restart the server. If that doesn't work for you, I don't know what else to do. Commented Feb 4, 2014 at 1:38
  • 1
    Crap. Why is that NEVER the first thing I do?! Commented Feb 7, 2014 at 0:15

1 Answer 1

1

For the sake of everyone else who may encounter this error, all I had to do was restart my server and it worked fine afterwards.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.