我最近升级了我的gemfile,试图让Rails 3.1与Jruby 3.1一起使用。
这是我的Gemfile:
来源'http://rubygems.org' 来源'http://gems.engineyard.com'
gem 'rails', '~> 3.1.0.rc4'
gem 'sass-rails'
gem 'compass', :git => 'https://github.com/chriseppstein/compass.git', :branch => 'rails31'
gem 'fancy-buttons'
gem 'haml'
gem 'authlogic', :git => 'https://github.com/AndreasWurm/authlogic.git'#, :branch => 'rails3'
gem 'nokogiri'
gem 'bundler'
gem 'resque'
gem 'resque-meta'
gem 'jquery-rails'
gem 'rake'#, '~> 0.8.7'
gem 'eventmachine'
gem 'em-websocket'
gem 'json'
gem 'coffee-script'
gem 'uglifier'
platforms :jruby do
gem 'activerecord-jdbc-adapter'
gem 'activerecord-jdbcsqlite3-adapter'
gem 'jruby-openssl'
gem 'jdbc-mysql'
gem 'jruby-rack'
gem 'warbler'
#gem 'glassfish', '1.0.3.dev'
end
group :test, :development do
platforms :jruby do
gem 'jdbc-sqlite3', :require => false
gem 'fastercsv'
gem 'ruby-debug'
end
platforms :ruby do
gem 'sqlite3-ruby', :require => 'sqlite3'
end
gem 'mocha'
gem 'factory_girl'
gem 'fakeweb'
gem 'shoulda', :require => 'shoulda'
end
问题是当我运行rake db:migrate时,我收到以下错误消息:
耙子流产了!发生了错误,此错误以及稍后的所有迁移 取消:nil的未定义方法`rows':NilClass
有没有其他人经历过这个。
答案 0 :(得分:0)
升级到rails 5使我的迁移无论如何都能从jruby 1.6.3构建:
来源'http://rubygems.org' 来源'http://gems.engineyard.com'
gem 'rails', '~> 3.1.0.rc5'
gem 'sass-rails'
gem 'compass', git: 'https://github.com/chriseppstein/compass.git',branch: 'rails31'
gem 'fancy-buttons'
gem 'haml'
gem 'authlogic', :git => 'https://github.com/AndreasWurm/authlogic.git'#, :branch => 'rails3'
gem 'nokogiri'
gem 'bundler'
gem 'resque'
gem 'resque-meta'
gem 'jquery-rails'
gem 'rake'#, '~> 0.8.7'
gem 'eventmachine'
gem 'em-websocket'
gem 'json'
gem 'coffee-script'
gem 'uglifier'
platforms :jruby do
gem 'activerecord-jdbc-adapter'
gem 'activerecord-jdbcsqlite3-adapter'
gem 'jruby-openssl'
gem 'jdbc-mysql'
gem 'jruby-rack'
gem 'warbler'
#gem 'glassfish', '1.0.3.dev'
end