Unable to boot rails server using mysql2 - mysql2

Here is the error...
C:\Sites\simple_cms>rails s
> => Booting WEBrick
> => Rails 3.2.13 application starting in development on http://X.X.X.X:3000
> => Call with -d to detach
> => Ctrl-C to shutdown server
Exiting
C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/bundler-1.3.5/lib/bundler/rubygems_integ
ration.rb:214:in `block in replace_gem': Please install the mysql2 adapter: `gem
install activerecord-mysql2-adapter` (mysql2 is not part of the bundle. Add it
to Gemfile.) (LoadError)
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/activerecord-3.2.13/lib/act
ive_record/connection_adapters/mysql2_adapter.rb:3:in `<top (required)>'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/activesupport-3.2.13/lib/ac
tive_support/dependencies.rb:251:in `require'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/activesupport-3.2.13/lib/ac
tive_support/dependencies.rb:251:in `block in require'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/activesupport-3.2.13/lib/ac
tive_support/dependencies.rb:236:in `load_dependency'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/activesupport-3.2.13/lib/ac
tive_support/dependencies.rb:251:in `require'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/activerecord-3.2.13/lib/act
ive_record/connection_adapters/abstract/connection_specification.rb:50:in `resol
ve_hash_connection'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/activerecord-3.2.13/lib/act
ive_record/connection_adapters/abstract/connection_specification.rb:41:in `resol
ve_string_connection'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/activerecord-3.2.13/lib/act
ive_record/connection_adapters/abstract/connection_specification.rb:25:in `spec'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/activerecord-3.2.13/lib/act
ive_record/connection_adapters/abstract/connection_specification.rb:130:in `esta
blish_connection'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/activerecord-3.2.13/lib/act
ive_record/railtie.rb:82:in `block (2 levels) in <class:Railtie>'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/activesupport-3.2.13/lib/ac
tive_support/lazy_load_hooks.rb:36:in `instance_eval'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/activesupport-3.2.13/lib/ac
tive_support/lazy_load_hooks.rb:36:in `execute_hook'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/activesupport-3.2.13/lib/ac
tive_support/lazy_load_hooks.rb:43:in `block in run_load_hooks'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/activesupport-3.2.13/lib/ac
tive_support/lazy_load_hooks.rb:42:in `each'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/activesupport-3.2.13/lib/ac
tive_support/lazy_load_hooks.rb:42:in `run_load_hooks'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/activerecord-3.2.13/lib/act
ive_record/base.rb:720:in `<top (required)>'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/activerecord-3.2.13/lib/act
ive_record/railtie.rb:88:in `block in <class:Railtie>'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/railties-3.2.13/lib/rails/i
nitializable.rb:30:in `instance_exec'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/railties-3.2.13/lib/rails/i
nitializable.rb:30:in `run'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/railties-3.2.13/lib/rails/i
nitializable.rb:55:in `block in run_initializers'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/railties-3.2.13/lib/rails/i
nitializable.rb:54:in `each'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/railties-3.2.13/lib/rails/i
nitializable.rb:54:in `run_initializers'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/railties-3.2.13/lib/rails/a
pplication.rb:136:in `initialize!'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/railties-3.2.13/lib/rails/r
ailtie/configurable.rb:30:in `method_missing'
from C:/Sites/simple_cms/config/environment.rb:5:in `<top (required)>'
from C:/Sites/simple_cms/config.ru:3:in `require'
from C:/Sites/simple_cms/config.ru:3:in `block in <main>'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/rack-1.4.5/lib/rack/builder
.rb:51:in `instance_eval'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/rack-1.4.5/lib/rack/builder
.rb:51:in `initialize'
from C:/Sites/simple_cms/config.ru:in `new'
from C:/Sites/simple_cms/config.ru:in `<main>'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/rack-1.4.5/lib/rack/builder
.rb:40:in `eval'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/rack-1.4.5/lib/rack/builder
.rb:40:in `parse_file'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/rack-1.4.5/lib/rack/server.
rb:200:in `app'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/railties-3.2.13/lib/rails/c
ommands/server.rb:46:in `app'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/rack-1.4.5/lib/rack/server.
rb:304:in `wrapped_app'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/rack-1.4.5/lib/rack/server.
rb:254:in `start'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/railties-3.2.13/lib/rails/c
ommands/server.rb:70:in `start'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/railties-3.2.13/lib/rails/c
ommands.rb:55:in `block in <top (required)>'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/railties-3.2.13/lib/rails/c
ommands.rb:50:in `tap'
from C:/Ruby200-x64/lib/ruby/gems/2.0.0/gems/railties-3.2.13/lib/rails/c
ommands.rb:50:in `<top (required)>'
from script/rails:6:in `require'
from script/rails:6:in `<main>'
Any help will be appreciated as I have followed all other threads with no joy. Thanks in advance

you have to read the error message carefully, it's in there ;)
Please install the mysql2 adapter: `gem install activerecord-mysql2-adapter` (mysql2 is not part of the bundle. Add it to Gemfile.) (LoadError)
just add gem 'mysql2' to your Gemfile, and run bundle install.

Related

Updating to Ruby 3.0.x with Rails: symbol not found in flat namespace '_RHASH_EMPTY_P'

Having issues upgrading my rails project on my M1 Mac related to Debase not compiling due to symbol not found in flat namespace '_RHASH_EMPTY_P'
OS: Monterey 12.0.1
Machine: Mac mini (m1, 2020)
Ruby version: 3.0.2
Rails: 6.1.4.1
I've tried removing Gemfile.lock and totally reinstalling brew/rbenv/rails. The app runs successfully on the Ruby:3.0.2 docker image.
When I run rails s, I get the following stack trace:
/Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require': dlopen(/Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/debase-0.2.4.1/lib/debase_internals.bundle, 0x0009): symbol not found in flat namespace '_RHASH_EMPTY_P' - /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/debase-0.2.4.1/lib/debase_internals.bundle (LoadError)
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.1/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/activesupport-6.1.4.1/lib/active_support/dependencies.rb:332:in `block in require'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/activesupport-6.1.4.1/lib/active_support/dependencies.rb:299:in `load_dependency'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/activesupport-6.1.4.1/lib/active_support/dependencies.rb:332:in `require'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/debase-0.2.4.1/lib/debase.rb:4:in `<main>'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.1/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/activesupport-6.1.4.1/lib/active_support/dependencies.rb:332:in `block in require'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/activesupport-6.1.4.1/lib/active_support/dependencies.rb:299:in `load_dependency'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/activesupport-6.1.4.1/lib/active_support/dependencies.rb:332:in `require'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/ruby-debug-ide-0.7.3/lib/ruby-debug-ide.rb:9:in `<main>'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.1/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bundler-2.2.31/lib/bundler/runtime.rb:60:in `block (2 levels) in require'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bundler-2.2.31/lib/bundler/runtime.rb:55:in `each'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bundler-2.2.31/lib/bundler/runtime.rb:55:in `block in require'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bundler-2.2.31/lib/bundler/runtime.rb:44:in `each'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bundler-2.2.31/lib/bundler/runtime.rb:44:in `require'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bundler-2.2.31/lib/bundler.rb:175:in `require'
from /Users/josh/Documents/Development/hub/config/application.rb:20:in `<main>'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.1/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/activesupport-6.1.4.1/lib/active_support/dependencies.rb:332:in `block in require'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/activesupport-6.1.4.1/lib/active_support/dependencies.rb:299:in `load_dependency'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/activesupport-6.1.4.1/lib/active_support/dependencies.rb:332:in `require'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/railties-6.1.4.1/lib/rails/commands/server/server_command.rb:138:in `block in perform'
from <internal:kernel>:90:in `tap'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/railties-6.1.4.1/lib/rails/commands/server/server_command.rb:135:in `perform'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/thor-1.1.0/lib/thor/command.rb:27:in `run'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/thor-1.1.0/lib/thor/invocation.rb:127:in `invoke_command'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/thor-1.1.0/lib/thor.rb:392:in `dispatch'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/railties-6.1.4.1/lib/rails/command/base.rb:69:in `perform'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/railties-6.1.4.1/lib/rails/command.rb:48:in `invoke'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/railties-6.1.4.1/lib/rails/commands.rb:18:in `<main>'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `require'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:23:in `block in require_with_bootsnap_lfi'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.1/lib/bootsnap/load_path_cache/loaded_features_index.rb:92:in `register'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:22:in `require_with_bootsnap_lfi'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/bootsnap-1.9.1/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:31:in `require'
from /Users/josh/Documents/Development/hub/bin/rails:9:in `<top (required)>'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/spring-2.1.1/lib/spring/client/rails.rb:28:in `load'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/spring-2.1.1/lib/spring/client/rails.rb:28:in `call'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/spring-2.1.1/lib/spring/client/command.rb:7:in `call'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/spring-2.1.1/lib/spring/client.rb:30:in `run'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/spring-2.1.1/bin/spring:49:in `<top (required)>'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/spring-2.1.1/lib/spring/binstub.rb:11:in `load'
from /Users/josh/.rbenv/versions/3.0.2/lib/ruby/gems/3.0.0/gems/spring-2.1.1/lib/spring/binstub.rb:11:in `<top (required)>'
from <internal:/Users/josh/.rbenv/versions/3.0.2/lib/ruby/3.0.0/rubygems/core_ext/kernel_require.rb>:85:in `require'
from <internal:/Users/josh/.rbenv/versions/3.0.2/lib/ruby/3.0.0/rubygems/core_ext/kernel_require.rb>:85:in `require'
from /Users/josh/Documents/Development/hub/bin/spring:15:in `<top (required)>'
from bin/rails:3:in `load'
from bin/rails:3:in `<main>'
From I can tell, debase isn't compatible yet with ruby 3, neither I see is well maintained like other similar gems. Personally, I'd move to pry-byebug or at least byebug.
Your other options I can see are removing the gem, downgrading to ruby 2.7 or simply contributing with a PR to fix debase and make it compatible with ruby 3.

unicorn fails to start

I am trying to start a unicorn server. It was working fine before. Suddenly after a server restart, this error popped.
I, [2014-05-25T17:04:20.480271 #13922] INFO -- : Refreshing Gem list
/home/quarterback/apps/quarterback-rails/shared/bundle/ruby/2.1.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:247:in `require': No such file to load -- Token (LoadError)
from /home/quarterback/apps/quarterback-rails/shared/bundle/ruby/2.1.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:247:in `block in require'
from /home/quarterback/apps/quarterback-rails/shared/bundle/ruby/2.1.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:232:in `load_dependency'
from /home/quarterback/apps/quarterback-rails/shared/bundle/ruby/2.1.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:247:in `require'
from /home/quarterback/apps/quarterback-rails/releases/20140525165531/app/controllers/domains_controller.rb:1:in `<top (required)>'
from /home/quarterback/apps/quarterback-rails/shared/bundle/ruby/2.1.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:247:in `require'
from /home/quarterback/apps/quarterback-rails/shared/bundle/ruby/2.1.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:247:in `block in require'
from /home/quarterback/apps/quarterback-rails/shared/bundle/ruby/2.1.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:232:in `load_dependency'
from /home/quarterback/apps/quarterback-rails/shared/bundle/ruby/2.1.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:247:in `require'
from /home/quarterback/apps/quarterback-rails/shared/bundle/ruby/2.1.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:348:in `require_or_load'
from /home/quarterback/apps/quarterback-rails/shared/bundle/ruby/2.1.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:307:in `depend_on'
from /home/quarterback/apps/quarterback-rails/shared/bundle/ruby/2.1.0/gems/activesupport-4.1.1/lib/active_support/dependencies.rb:225:in `require_dependency'
from /home/quarterback/apps/quarterback-rails/shared/bundle/ruby/2.1.0/gems/railties-4.1.1/lib/rails/engine.rb:468:in `block (2 levels) in eager_load!'
from /home/quarterback/apps/quarterback-rails/shared/bundle/ruby/2.1.0/gems/railties-4.1.1/lib/rails/engine.rb:467:in `each'
from /home/quarterback/apps/quarterback-rails/shared/bundle/ruby/2.1.0/gems/railties-4.1.1/lib/rails/engine.rb:467:in `block in eager_load!'
from /home/quarterback/apps/quarterback-rails/shared/bundle/ruby/2.1.0/gems/railties-4.1.1/lib/rails/engine.rb:465:in `each'
from /home/quarterback/apps/quarterback-rails/shared/bundle/ruby/2.1.0/gems/railties-4.1.1/lib/rails/engine.rb:465:in `eager_load!'
from /home/quarterback/apps/quarterback-rails/shared/bundle/ruby/2.1.0/gems/railties-4.1.1/lib/rails/engine.rb:346:in `eager_load!'
from /home/quarterback/apps/quarterback-rails/shared/bundle/ruby/2.1.0/gems/railties-4.1.1/lib/rails/application/finisher.rb:58:in `each'
from /home/quarterback/apps/quarterback-rails/shared/bundle/ruby/2.1.0/gems/railties-4.1.1/lib/rails/application/finisher.rb:58:in `block in <module:Finisher>'
from /home/quarterback/apps/quarterback-rails/shared/bundle/ruby/2.1.0/gems/railties-4.1.1/lib/rails/initializable.rb:30:in `instance_exec'**strong text**
Silly one. I had a require 'Token' in one of my files.

`method_missing': undefined method `user_class=' for #<Forem::Engine:0x9de6bc0>

When i run rails server,i encountered this error.
'bundle install' has been success.My RVM use ruby 1.9.3 and rails 3.2 but the project need rails 3.1.I think the bundle has already solved the because of the bundle.The rails and ruby might not be the reason.
Anything would be help.Thanks
Your bundle is complete!
It was installed into ./vendor/bundle
magic#magic-ThinkPad-T430u:~/Documents/rails/ticketee-book$ rails server
=> Booting WEBrick
=> Rails 3.1.0.rc2 application starting in development on http://0.0.0.0:3000
=> Call with -d to detach
=> Ctrl-C to shutdown server
Exiting
/home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/railties/lib/rails/railtie/configurable.rb:30:in `method_missing': undefined method `user_class=' for #<Forem::Engine:0x9de6bc0> (NoMethodError)
from /home/magic/Documents/rails/ticketee-book/config/initializers/forem.rb:1:in `<top (required)>'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/activesupport/lib/active_support/dependencies.rb:235:in `load'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/activesupport/lib/active_support/dependencies.rb:235:in `block in load'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/activesupport/lib/active_support/dependencies.rb:225:in `block in load_dependency'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/activesupport/lib/active_support/dependencies.rb:641:in `new_constants_in'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/activesupport/lib/active_support/dependencies.rb:225:in `load_dependency'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/activesupport/lib/active_support/dependencies.rb:235:in `load'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/railties/lib/rails/engine.rb:544:in `block (2 levels) in <class:Engine>'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/railties/lib/rails/engine.rb:543:in `each'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/railties/lib/rails/engine.rb:543:in `block in <class:Engine>'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/railties/lib/rails/initializable.rb:25:in `instance_exec'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/railties/lib/rails/initializable.rb:25:in `run'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/railties/lib/rails/initializable.rb:50:in `block in run_initializers'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/railties/lib/rails/initializable.rb:49:in `each'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/railties/lib/rails/initializable.rb:49:in `run_initializers'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/railties/lib/rails/application.rb:96:in `initialize!'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/railties/lib/rails/railtie/configurable.rb:30:in `method_missing'
from /home/magic/Documents/rails/ticketee-book/config/environment.rb:5:in `<top (required)>'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/activesupport/lib/active_support/dependencies.rb:239:in `require'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/activesupport/lib/active_support/dependencies.rb:239:in `block in require'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/activesupport/lib/active_support/dependencies.rb:225:in `block in load_dependency'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/activesupport/lib/active_support/dependencies.rb:641:in `new_constants_in'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/activesupport/lib/active_support/dependencies.rb:225:in `load_dependency'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/activesupport/lib/active_support/dependencies.rb:239:in `require'
from /home/magic/Documents/rails/ticketee-book/config.ru:4:in `block in <main>'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/gems/rack-1.3.0/lib/rack/builder.rb:51:in `instance_eval'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/gems/rack-1.3.0/lib/rack/builder.rb:51:in `initialize'
from /home/magic/Documents/rails/ticketee-book/config.ru:1:in `new'
from /home/magic/Documents/rails/ticketee-book/config.ru:1:in `<main>'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/gems/rack-1.3.0/lib/rack/builder.rb:40:in `eval'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/gems/rack-1.3.0/lib/rack/builder.rb:40:in `parse_file'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/gems/rack-1.3.0/lib/rack/server.rb:200:in `app'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/railties/lib/rails/commands/server.rb:46:in `app'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/gems/rack-1.3.0/lib/rack/server.rb:301:in `wrapped_app'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/gems/rack-1.3.0/lib/rack/server.rb:252:in `start'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/railties/lib/rails/commands/server.rb:70:in `start'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/railties/lib/rails/commands.rb:54:in `block in <top (required)>'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/railties/lib/rails/commands.rb:49:in `tap'
from /home/magic/Documents/rails/ticketee-book/vendor/bundle/ruby/1.9.1/bundler/gems/rails-623c16f4f8b7/railties/lib/rails/commands.rb:49:in `<top (required)>'
from script/rails:6:in `require'
from script/rails:6:in `<main>'
Try running server with bundle command. It will use all gems that are defined in your Gemfile then:
bundle exec rails server

Error on db:migrate

I am trying to modify a rails app built on an another computer ,I ran bundle install
and all gems got installed.But when I run rake db:migrate ,it throws down a bunch of errors ,I am new to rail and cant understand what those error messages
rake aborted!
/home/diadara/.rvm/gems/ruby-1.9.3-p374#saasrails3.1/gems/ruby-debug-base19-0.11.25/lib/ruby_debug.so: undefined symbol: ruby_current_thread - /home/diadara/.rvm/gems/ruby-1.9.3-p374#saasrails3.1/gems/ruby-debug-base19-0.11.25/lib/ruby_debug.so
/home/diadara/.rvm/gems/ruby-1.9.3-p374#saasrails3.1/gems/ruby-debug-base19-0.11.25/lib/ruby-debug-base.rb:1:in `require'
/home/diadara/.rvm/gems/ruby-1.9.3-p374#saasrails3.1/gems/ruby-debug-base19-0.11.25/lib/ruby-debug-base.rb:1:in `<top (required)>'
/home/diadara/.rvm/gems/ruby-1.9.3-p374#saasrails3.1/gems/ruby-debug19-0.11.6/cli/ruby-debug.rb:5:in `require'
/home/diadara/.rvm/gems/ruby-1.9.3-p374#saasrails3.1/gems/ruby-debug19-0.11.6/cli/ruby-debug.rb:5:in `<top (required)>'
/home/diadara/.rvm/gems/ruby-1.9.3-p374#global/gems/bundler-1.2.3/lib/bundler/runtime.rb:68:in `require'
/home/diadara/.rvm/gems/ruby-1.9.3-p374#global/gems/bundler-1.2.3/lib/bundler/runtime.rb:68:in `block (2 levels) in require'
/home/diadara/.rvm/gems/ruby-1.9.3-p374#global/gems/bundler-1.2.3/lib/bundler/runtime.rb:66:in `each'
/home/diadara/.rvm/gems/ruby-1.9.3-p374#global/gems/bundler-1.2.3/lib/bundler/runtime.rb:66:in `block in require'
/home/diadara/.rvm/gems/ruby-1.9.3-p374#global/gems/bundler-1.2.3/lib/bundler/runtime.rb:55:in `each'
/home/diadara/.rvm/gems/ruby-1.9.3-p374#global/gems/bundler-1.2.3/lib/bundler/runtime.rb:55:in `require'
/home/diadara/.rvm/gems/ruby-1.9.3-p374#global/gems/bundler-1.2.3/lib/bundler.rb:128:in `require'
/home/diadara/hw3_rottenpotatoes/config/application.rb:13:in `<top (required)>'
/home/diadara/hw3_rottenpotatoes/Rakefile:5:in `require'
/home/diadara/hw3_rottenpotatoes/Rakefile:5:in `<top (required)>'
/home/diadara/.rvm/gems/ruby-1.9.3-p374#saasrails3.1/gems/rake-0.9.2.2/lib/rake/rake_module.rb:25:in `load'
/home/diadara/.rvm/gems/ruby-1.9.3-p374#saasrails3.1/gems/rake-0.9.2.2/lib/rake/rake_module.rb:25:in `load_rakefile'
/home/diadara/.rvm/gems/ruby-1.9.3-p374#saasrails3.1/gems/rake-0.9.2.2/lib/rake/application.rb:501:in `raw_load_rakefile'
/home/diadara/.rvm/gems/ruby-1.9.3-p374#saasrails3.1/gems/rake-0.9.2.2/lib/rake/application.rb:82:in `block in load_rakefile'
/home/diadara/.rvm/gems/ruby-1.9.3-p374#saasrails3.1/gems/rake-0.9.2.2/lib/rake/application.rb:133:in `standard_exception_handling'
/home/diadara/.rvm/gems/ruby-1.9.3-p374#saasrails3.1/gems/rake-0.9.2.2/lib/rake/application.rb:81:in `load_rakefile'
/home/diadara/.rvm/gems/ruby-1.9.3-p374#saasrails3.1/gems/rake-0.9.2.2/lib/rake/application.rb:65:in `block in run'
/home/diadara/.rvm/gems/ruby-1.9.3-p374#saasrails3.1/gems/rake-0.9.2.2/lib/rake/application.rb:133:in `standard_exception_handling'
/home/diadara/.rvm/gems/ruby-1.9.3-p374#saasrails3.1/gems/rake-0.9.2.2/lib/rake/application.rb:63:in `run'
/home/diadara/.rvm/gems/ruby-1.9.3-p374#saasrails3.1/gems/rake-0.9.2.2/bin/rake:33:in `<top (required)>'
/home/diadara/.rvm/gems/ruby-1.9.3-p374#saasrails3.1/bin/rake:19:in `<main>'
/home/diadara/.rvm/gems/ruby-1.9.3-p374#saasrails3.1/bin/ruby_noexec_wrapper:14:in `eval'
/home/diadara/.rvm/gems/ruby-1.9.3-p374#saasrails3.1/bin/ruby_noexec_wrapper:14:in `<main>'
it looks like you did not properly install ruby-debug in your project. remove it from the gemfile if it is not needed or have a look at this answer to fix it: Cannot use ruby-debug19 with 1.9.3-p0?

Couldn't parse YAML at line 7 - RefineryCMS / Rails Issue

Please could someone help me understand what has gone wrong, and how I can lookout/debug these things in the future. I have set-up a RefineryCMS app in Rails, worked on it, uploaded it to Heroku and have had both the local and remote copies working fine. After a period of about a month I return to the local copy to work on it, but it won't load. I can't understand why as nothing has changed. I tried deleting the local copy and cloning again from heroku but same issue exists. The error code is below when I try and create a rails server locally to run the app.
I would welcome help with the error, and perhaps how to spot/avoid these things in the future
/home/adam/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/1.9.1/psych.rb:148:in `parse': couldn't parse YAML at line 7 column 0 (Psych::SyntaxError)
from /home/adam/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/1.9.1/psych.rb:148:in `parse_stream'
from /home/adam/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/1.9.1/psych.rb:119:in `parse'
from /home/adam/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/1.9.1/psych.rb:106:in `load'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/activerecord-3.0.11/lib/active_record/base.rb:1868:in `object_from_yaml'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/activerecord-3.0.11/lib/active_record/attribute_methods/read.rb:129:in `unserialize_attribute'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/activerecord-3.0.11/lib/active_record/attribute_methods/read.rb:112:in `_read_attribute'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/activerecord-3.0.11/lib/active_record/attribute_methods/read.rb:101:in `read_attribute'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/activerecord-3.0.11/lib/active_record/base.rb:1525:in `[]'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/refinerycms-settings-1.0.9/app/models/refinery_setting.rb:158:in `value'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/refinerycms-settings-1.0.9/app/models/refinery_setting.rb:61:in `block in to_cache'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/refinerycms-settings-1.0.9/app/models/refinery_setting.rb:58:in `collect'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/refinerycms-settings-1.0.9/app/models/refinery_setting.rb:58:in `to_cache'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/refinerycms-settings-1.0.9/app/models/refinery_setting.rb:73:in `rewrite_cache'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/refinerycms-settings-1.0.9/app/models/refinery_setting.rb:36:in `ensure_cache_exists!'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/refinerycms-settings-1.0.9/app/models/refinery_setting.rb:44:in `cache_read'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/refinerycms-settings-1.0.9/app/models/refinery_setting.rb:109:in `get'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/refinerycms-settings-1.0.9/app/models/refinery_setting.rb:95:in `find_or_set'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/refinerycms-images-1.0.9/lib/refinerycms-images.rb:33:in `block (2 levels) in <class:Engine>'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/dragonfly-0.9.8/lib/dragonfly/configurable.rb:35:in `configure'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/dragonfly-0.9.8/lib/dragonfly/configurable.rb:42:in `configure_with'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/refinerycms-images-1.0.9/lib/refinerycms-images.rb:24:in `block in <class:Engine>'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/railties-3.0.11/lib/rails/initializable.rb:25:in `instance_exec'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/railties-3.0.11/lib/rails/initializable.rb:25:in `run'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/railties-3.0.11/lib/rails/initializable.rb:50:in `block in run_initializers'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/railties-3.0.11/lib/rails/initializable.rb:49:in `each'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/railties-3.0.11/lib/rails/initializable.rb:49:in `run_initializers'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/railties-3.0.11/lib/rails/application.rb:134:in `initialize!'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/railties-3.0.11/lib/rails/application.rb:77:in `method_missing'
from /home/adam/web/beloved/config/environment.rb:5:in `<top (required)>'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/activesupport-3.0.11/lib/active_support/dependencies.rb:239:in `require'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/activesupport-3.0.11/lib/active_support/dependencies.rb:239:in `block in require'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/activesupport-3.0.11/lib/active_support/dependencies.rb:225:in `block in load_dependency'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/activesupport-3.0.11/lib/active_support/dependencies.rb:593:in `new_constants_in'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/activesupport-3.0.11/lib/active_support/dependencies.rb:225:in `load_dependency'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/activesupport-3.0.11/lib/active_support/dependencies.rb:239:in `require'
from /home/adam/web/beloved/config.ru:3:in `block in <main>'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/rack-1.2.4/lib/rack/builder.rb:46:in `instance_eval'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/rack-1.2.4/lib/rack/builder.rb:46:in `initialize'
from /home/adam/web/beloved/config.ru:1:in `new'
from /home/adam/web/beloved/config.ru:1:in `<main>'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/rack-1.2.4/lib/rack/builder.rb:35:in `eval'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/rack-1.2.4/lib/rack/builder.rb:35:in `parse_file'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/rack-1.2.4/lib/rack/server.rb:162:in `app'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/rack-1.2.4/lib/rack/server.rb:253:in `wrapped_app'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/rack-1.2.4/lib/rack/server.rb:204:in `start'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/railties-3.0.11/lib/rails/commands/server.rb:65:in `start'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/railties-3.0.11/lib/rails/commands.rb:30:in `block in <top (required)>'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/railties-3.0.11/lib/rails/commands.rb:27:in `tap'
from /home/adam/.rvm/gems/ruby-1.9.2-p290#beloved2/gems/railties-3.0.11/lib/rails/commands.rb:27:in `<top (required)>'
from script/rails:6:in `require'
from script/rails:6:in `<main>'
Thanks for your help,
Adam
Add to config/boot.rb:
require 'yaml'
YAML::ENGINE.yamler = 'syck'
Read more here