Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Ruby Build a Todo List Application with Rails 4 Build a Todo List Application with Rails 4 Set up Git and Add Gems

joseph mallari
joseph mallari
4,052 Points

My server stops running? help?

/Users/macbook/Desktop/Treehouse/projects/odot/config/environments/development.rb:1:in <top (required)>': undefined methodconfigure' for #<Odot::Application:0x007fe2fb345c70> (NoMethodError)

Brandon Barrette
Brandon Barrette
20,485 Points

Paste in your development.rb file please so we can help you diagnose.

joseph mallari
joseph mallari
4,052 Points
Rails.application.configure do
  # Settings specified here will take precedence over those in config/application.rb.

  # In the development environment your application's code is reloaded on
  # every request. This slows down response time but is perfect for development
  # since you don't have to restart the web server when you make code changes.
  config.cache_classes = false

  # Do not eager load code on boot.
  config.eager_load = false

  # Show full error reports and disable caching.
  config.consider_all_requests_local       = true
  config.action_controller.perform_caching = false

  # Don't care if the mailer can't send.
  config.action_mailer.raise_delivery_errors = false

  # Print deprecation notices to the Rails logger.
  config.active_support.deprecation = :log

  # Raise an error on page load if there are pending migrations.
  config.active_record.migration_error = :page_load

  # Debug mode disables concatenation and preprocessing of assets.
  # This option may cause significant delays in view rendering with a large
  # number of complex assets.
  config.assets.debug = true

  # Adds additional error checking when serving assets at runtime.
  # Checks for improperly declared sprockets dependencies.
  # Raises helpful error messages.
  config.assets.raise_runtime_errors = true

  # Raises error for missing translations
  # config.action_view.raise_on_missing_translations = true
end
joseph mallari
joseph mallari
4,052 Points

Well actually, yeah.

from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/activesupport-4.0.1/lib/active_support/dependencies.rb:229:in `require'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/activesupport-4.0.1/lib/active_support/dependencies.rb:229:in `block in require'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/activesupport-4.0.1/lib/active_support/dependencies.rb:214:in `load_dependency'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/activesupport-4.0.1/lib/active_support/dependencies.rb:229:in `require'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/railties-4.0.1/lib/rails/engine.rb:591:in `block (2 levels) in <class:Engine>'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/railties-4.0.1/lib/rails/engine.rb:590:in `each'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/railties-4.0.1/lib/rails/engine.rb:590:in `block in <class:Engine>'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/railties-4.0.1/lib/rails/initializable.rb:30:in `instance_exec'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/railties-4.0.1/lib/rails/initializable.rb:30:in `run'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/railties-4.0.1/lib/rails/initializable.rb:55:in `block in run_initializers'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/1.9.1/tsort.rb:150:in `block in tsort_each'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/1.9.1/tsort.rb:183:in `block (2 levels) in each_strongly_connected_component'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/1.9.1/tsort.rb:210:in `block (2 levels) in each_strongly_connected_component_from'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/1.9.1/tsort.rb:219:in `each_strongly_connected_component_from'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/1.9.1/tsort.rb:209:in `block in each_strongly_connected_component_from'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/railties-4.0.1/lib/rails/initializable.rb:44:in `each'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/railties-4.0.1/lib/rails/initializable.rb:44:in `tsort_each_child'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/1.9.1/tsort.rb:203:in `each_strongly_connected_component_from'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/1.9.1/tsort.rb:182:in `block in each_strongly_connected_component'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/1.9.1/tsort.rb:180:in `each'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/1.9.1/tsort.rb:180:in `each_strongly_connected_component'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/1.9.1/tsort.rb:148:in `tsort_each'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/railties-4.0.1/lib/rails/initializable.rb:54:in `run_initializers'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/railties-4.0.1/lib/rails/application.rb:215:in `initialize!'
from /Users/macbook/Desktop/Treehouse/projects/odot/config/environment.rb:5:in `<top (required)>'
from /Users/macbook/Desktop/Treehouse/projects/odot/config.ru:3:in `require'
from /Users/macbook/Desktop/Treehouse/projects/odot/config.ru:3:in `block in <main>'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/rack-1.5.2/lib/rack/builder.rb:55:in `instance_eval'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/rack-1.5.2/lib/rack/builder.rb:55:in `initialize'
from /Users/macbook/Desktop/Treehouse/projects/odot/config.ru:in `new'
from /Users/macbook/Desktop/Treehouse/projects/odot/config.ru:in `<main>'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/rack-1.5.2/lib/rack/builder.rb:49:in `eval'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/rack-1.5.2/lib/rack/builder.rb:49:in `new_from_string'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/rack-1.5.2/lib/rack/builder.rb:40:in `parse_file'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/rack-1.5.2/lib/rack/server.rb:277:in `build_app_and_options_from_config'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/rack-1.5.2/lib/rack/server.rb:199:in `app'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/railties-4.0.1/lib/rails/commands/server.rb:48:in `app'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/rack-1.5.2/lib/rack/server.rb:314:in `wrapped_app'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/railties-4.0.1/lib/rails/commands/server.rb:75:in `start'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/railties-4.0.1/lib/rails/commands.rb:76:in `block in <top (required)>'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/railties-4.0.1/lib/rails/commands.rb:71:in `tap'
from /Users/macbook/.rbenv/versions/1.9.3-p327/lib/ruby/gems/1.9.1/gems/railties-4.0.1/lib/rails/commands.rb:71:in `<top (required)>'
from bin/rails:4:in `require'
from bin/rails:4:in `<main>'
Brandon Barrette
Brandon Barrette
20,485 Points

What's the last file you were working in? My guess is that there is some error there. Was the server working before this?

joseph mallari
joseph mallari
4,052 Points

Or could it be the vagrant up too? Failed to mount folders in Linux guest. This is usually because the "vboxsf" file system is not available. Please verify that the guest additions are properly installed in the guest and can work properly. The command attempted was:

mount -t vboxsf -o uid=id -u treehouse,gid=getent group treehouse | cut -d: -f3 home_treehouse_projects /home/treehouse/projects mount -t vboxsf -o uid=id -u treehouse,gid=id -g treehouse home_treehouse_projects /home/treehouse/projects

The error output from the last command was:

stdin: is not a tty /sbin/mount.vboxsf: mounting failed with the error: No such device

joseph mallari
joseph mallari
4,052 Points

I was working on something else and the server was working

2 Answers

Brandon Barrette
Brandon Barrette
20,485 Points

There's nothing wrong in that file. Any other errors they give you in the terminal?

on any environment file it used to say AppName::Application.configure in earlier version, not Rails.application.configure. I think that was why.

Basically that NoMethodError on your question means that configure method can be found somewhere else. (in your case probably Odot::Application)

I guess you may download the matching vm to your current course.

Try this on rails console :

> Odot::Application.methods.include?(:configure)

and

> Rails.application.methods.include?(:configure)

and see which one's false.