开发者

RedMine + gem_dependency.rb:119:Warning: Gem::Dependency#version_requirements is deprecated and will be removed on or after August 2010

/redmine$ ruby script/server -e production => Booting WEBrick => Rails 2.3.5 application starting on http://0.0.0.0:3000 /home/siya/.rvm/gems/ruby-1.8.7-p330/gems/rails-2.3.5/lib/rails/gem_dependency.rb:119:Warning: Gem::Dependency#version_requirements is deprecated and will be removed on or after August 2010. Use #requirement /home/siya/.rvm/gems/ruby-1.8.7-p330/gems/activerecord-2.3.5/lib/active_record/connection_adapters/mysql_adapter.rb:589:in real_connect': Can't connect to local MySQL server through socket '/var/run/mysqld/mysqld.sock' (2) (Mysql::Error) from /home/siya/.rvm/gems/ruby-1.8.7-p330/gems/activerecord-2.3.5/lib/active_record/connection_adapters/mysql_adapter.rb:589:inconnect'

This issue occur's when I restart my application. In fact yesterday it was running fine. But today I tried a lot and searched the web, but could not get success.

After googling, I got one command to update the system ie sudo gem update --system

Now new error occurs:

/home/siya/.rvm/gems/ruby-1.8.7-p330/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:55: uninitialized constant ActiveS开发者_运维技巧upport::Dependencies::Mutex (NameError)
    from /home/siya/.rvm/rubies/ruby-1.8.7-p330/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:36:in `gem_original_require'


Upgrade rails to the latest version (2.3.5 is fairly old).

gem install rails --version 2.3.11

You will also need to update your dependencies in your environment.rb, to set RAILS_GEM_VERSION to 2.3.11

Run rake rails:update

Test! Rails upgrades seem to rarely be seamless. You do have an extensive suite of unit tests, don't you... :)


Some-time, In resolving such type of issues. We again raise any other conflict.

So best part is that,just take the bakcup of application folder and public folder. Re-install the whole rails and ruby.

Because after investing whole day to resolve this issue. I followed this procedure. Please do not waste time.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜