Could not find gem 'audited-activerecord ' error when starting foreman-1.0.0-0.7

I ran "bundle install --local" as foreman, and now I got this error when
starting foreman

[root@puppet share]# service foreman start
Starting foreman: Libvirt binding are missing - hypervisor management is
disabled
DEPRECATION WARNING: RAILS_DEFAULT_LOGGER is deprecated. Please use
::Rails.logger. (called from /usr/share/foreman/config/application.rb:11)
/usr/lib64/ruby/gems/1.8/gems/railties-3.0.15/lib/rails/deprecation.rb:33:in
method_missing': private methodwarn' called for
nil:Rails::DeprecatedConstant (NoMethodError)
from
/usr/lib64/ruby/gems/1.8/gems/has_many_polymorphs-2.13/lib/has_many_polymorphs/support_methods.rb:69:in
_logger_warn' from /usr/lib64/ruby/gems/1.8/gems/has_many_polymorphs-2.13/lib/has_many_polymorphs.rb:22 from /usr/lib64/ruby/gems/1.8/gems/bundler-1.1.5/lib/bundler/runtime.rb:68:inrequire'
from
/usr/lib64/ruby/gems/1.8/gems/bundler-1.1.5/lib/bundler/runtime.rb:68:in
require' from /usr/lib64/ruby/gems/1.8/gems/bundler-1.1.5/lib/bundler/runtime.rb:66:ineach'
from
/usr/lib64/ruby/gems/1.8/gems/bundler-1.1.5/lib/bundler/runtime.rb:66:in
require' from /usr/lib64/ruby/gems/1.8/gems/bundler-1.1.5/lib/bundler/runtime.rb:55:ineach'
from
/usr/lib64/ruby/gems/1.8/gems/bundler-1.1.5/lib/bundler/runtime.rb:55:in
require' from /usr/lib64/ruby/gems/1.8/gems/bundler-1.1.5/lib/bundler.rb:119:inrequire'
from /usr/share/foreman/config/application.rb:11
from
/usr/lib64/ruby/gems/1.8/gems/railties-3.0.15/lib/rails/commands.rb:28:in
require' from /usr/lib64/ruby/gems/1.8/gems/railties-3.0.15/lib/rails/commands.rb:28 from /usr/lib64/ruby/gems/1.8/gems/railties-3.0.15/lib/rails/commands.rb:27:intap'
from
/usr/lib64/ruby/gems/1.8/gems/railties-3.0.15/lib/rails/commands.rb:27
from /usr/share/foreman/script/rails:6:in `require'
from /usr/share/foreman/script/rails:6

I got that same error when I installed the 1.0.0-0.6 RPMs over a git
checkout of Foreman. I ended up moving /usr/share/foreman to
/usr/share/foreman-old and reinstalling all foreman RPMs. That solved my
problem. This was likely because I had outdated gems in my vendor/
directory from git installation. The block looks to be in
has_many_polymorphs. The version git revision required by Foreman's
Gemfile should come up as has_many_polymorphs-3.0.0.beta1 (
https://github.com/jystewart/has_many_polymorphs/blob/03429a61e511f394e9f96af0c8998268ca99d42b/has_many_polymorphs.gemspec).
Looks like it's using an old version of has_many_polymorphs that may have
been installed previously.

What does your gem list show as installed for has_many_polymorphs?

  • Trey
ยทยทยท On Thursday, July 19, 2012 3:08:03 PM UTC-5, Clay wrote: > > > I ran "bundle install --local" as foreman, and now I got this error when > starting foreman > > [root@puppet share]# service foreman start > Starting foreman: Libvirt binding are missing - hypervisor management is > disabled > DEPRECATION WARNING: RAILS_DEFAULT_LOGGER is deprecated. Please use > ::Rails.logger. (called from /usr/share/foreman/config/application.rb:11) > /usr/lib64/ruby/gems/1.8/gems/railties-3.0.15/lib/rails/deprecation.rb:33:in > `method_missing': private method `warn' called for > nil:Rails::DeprecatedConstant (NoMethodError) > from > /usr/lib64/ruby/gems/1.8/gems/has_many_polymorphs-2.13/lib/has_many_polymorphs/support_methods.rb:69:in > `_logger_warn' > from > /usr/lib64/ruby/gems/1.8/gems/has_many_polymorphs-2.13/lib/has_many_polymorphs.rb:22 > from > /usr/lib64/ruby/gems/1.8/gems/bundler-1.1.5/lib/bundler/runtime.rb:68:in > `require' > from > /usr/lib64/ruby/gems/1.8/gems/bundler-1.1.5/lib/bundler/runtime.rb:68:in > `require' > from > /usr/lib64/ruby/gems/1.8/gems/bundler-1.1.5/lib/bundler/runtime.rb:66:in > `each' > from > /usr/lib64/ruby/gems/1.8/gems/bundler-1.1.5/lib/bundler/runtime.rb:66:in > `require' > from > /usr/lib64/ruby/gems/1.8/gems/bundler-1.1.5/lib/bundler/runtime.rb:55:in > `each' > from > /usr/lib64/ruby/gems/1.8/gems/bundler-1.1.5/lib/bundler/runtime.rb:55:in > `require' > from > /usr/lib64/ruby/gems/1.8/gems/bundler-1.1.5/lib/bundler.rb:119:in `require' > from /usr/share/foreman/config/application.rb:11 > from > /usr/lib64/ruby/gems/1.8/gems/railties-3.0.15/lib/rails/commands.rb:28:in > `require' > from > /usr/lib64/ruby/gems/1.8/gems/railties-3.0.15/lib/rails/commands.rb:28 > from > /usr/lib64/ruby/gems/1.8/gems/railties-3.0.15/lib/rails/commands.rb:27:in > `tap' > from > /usr/lib64/ruby/gems/1.8/gems/railties-3.0.15/lib/rails/commands.rb:27 > from /usr/share/foreman/script/rails:6:in `require' > from /usr/share/foreman/script/rails:6 >