我刚刚安装了rvm并安装了jruby 和宝石安装导轨 铁轨5.1 然后创建一个新的rails 发生在下一个......
ruby bin/rails server
拿起_JAVA_OPTIONS:-Dawt.useSystemAAFontSettings = gasp
Bundler :: GemRequireError:尝试加载gem' activerecord-jdbcsqlite3-adapter'时出错。
宝石加载错误是:未定义的方法alias_method_chain' for #<Class:ActiveRecord::Base>
Did you mean? alias_method
Backtrace for gem load error is:
org/jruby/RubyBasicObject.java:1653:in
method_missing&#39;
/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/activerecord-jdbc-adapter-1.3.22/lib/arjdbc/jdbc/base_ext.rb:13:in singleton class'
/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/activerecord-jdbc-adapter-1.3.22/lib/arjdbc/jdbc/base_ext.rb:4:in
阻止ActiveRecord&# 39;
org / jruby / RubyModule.java:2831:in module_eval'
/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/activerecord-jdbc-adapter-1.3.22/lib/arjdbc/jdbc/base_ext.rb:3:in
&#39;
/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/activerecord-jdbc-adapter-1.3.22/lib/arjdbc/jdbc/base_ext.rb:1:in <main>'
org/jruby/RubyKernel.java:961:in
要求&#39;
/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/activerecord-jdbc-adapter-1.3.22/lib/arjdbc/jdbc/adapter.rb:1:in <main>'
org/jruby/RubyKernel.java:961:in
要求&#39;
/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/activerecord-jdbc-adapter-1.3.22/lib/arjdbc/jdbc/adapter.rb:6:in <module:(root)>'
/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/activerecord-jdbc-adapter-1.3.22/lib/arjdbc/jdbc.rb:1:in
&#39;
org / jruby / RubyKernel.java:961:require'
/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/activerecord-jdbc-adapter-1.3.22/lib/arjdbc/jdbc.rb:52:in
&#39;
org / jruby / RubyKernel.java:961:require'
/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/activerecord-jdbc-adapter-1.3.22/lib/arjdbc/jdbc.rb:3:in
&#39;
org / jruby / RubyKernel.java:961:在require'
/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/activerecord-jdbc-adapter-1.3.22/lib/arjdbc.rb:1:in
块中(根)&#39;
org / jruby / RubyArray.java:1733:在each'
/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/activerecord-jdbc-adapter-1.3.22/lib/arjdbc.rb:9:in
块中(根)&#39;
org / jruby / RubyArray.java:1733:在each'
/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/activerecord-jdbcsqlite3-adapter-1.3.22/lib/activerecord-jdbcsqlite3-adapter.rb:1:in
(root)&#39;
/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/activerecord-jdbcsqlite3-adapter-1.3.22/lib/activerecord-jdbcsqlite3-adapter.rb:2:in (root)'
/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/bundler-1.15.4/lib/bundler/runtime.rb:1:in
&#39;
org / jruby / RubyKernel.java:961:在require'
/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/bundler-1.15.4/lib/bundler/runtime.rb:82:in
块中的require&#39;
org / jruby / RubyKernel.java:1747:在tap'
/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/bundler-1.15.4/lib/bundler/runtime.rb:77:in
中需要&#39;
/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/bundler-1.15.4/lib/bundler/runtime.rb:66:in require'
/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/bundler-1.15.4/lib/bundler.rb:108:in
要求&#39;
/home/jack_zhang/Desktop/jrubyrails/config/application.rb:7:in (root)'
/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/railties-5.1.4.rc1/lib/rails/commands/server/server_command.rb:1:in
(root)&#39;
/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/railties-5.1.4.rc1/lib/rails/commands/server/server_command.rb:133:in perform'
/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/railties-5.1.4.rc1/lib/rails/commands/server/server_command.rb:130:in
&#39;
org / jruby / RubyKernel.java:961:require'
bin/rails:4:in
&#39;
Bundler Error Backtrace:
阻止在/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/bundler-1.15.4/lib/bundler/runtime.rb:86 每个在org / jruby / RubyArray.java:1733 阻止在/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/bundler-1.15.4/lib/bundler/runtime.rb:77 每个在org / jruby / RubyArray.java:1733 需要在/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/bundler-1.15.4/lib/bundler/runtime.rb:66 需要在/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/bundler-1.15.4/lib/bundler.rb:108 在/home/jack_zhang/Desktop/jrubyrails/config/application.rb:7 需要在org / jruby / RubyKernel.java:961 阻止在(root)/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/railties-5.1.4.rc1/lib/rails/commands/server/server_command.rb:1 点击org / jruby / RubyKernel.java:1747 在/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/railties-5.1.4.rc1/lib/rails/commands/server/server_command.rb:133执行 在/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/railties-5.1.4.rc1/lib/rails/commands/server/server_command.rb:130执行 在/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/thor-0.20.0/lib/thor/command.rb:27运行 invoke_command at /home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/thor-0.20.0/lib/thor/invocation.rb:126 发送到/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/thor-0.20.0/lib/thor.rb:387 在/home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/railties-5.1.4.rc1/lib/rails/command/base.rb:63执行 at /home/jack_zhang/.rvm/gems/jruby-9.1.7.0/gems/railties-5.1.4.rc1/lib/rails/command.rb:44 需要在org / jruby / RubyKernel.java:961 在bin / rails:4
答案 0 :(得分:0)
activerecord -jdbc-adapter-1.3.22 与Rails 5.x不兼容
...你应该尝试使用gem-5分支形成gem的git存储库