宝石'设计','〜> 4.2'
宝石'rolify','〜> 5.1'
宝石'cancancan','〜> 1.15'
导轨5.0
ruby 2.3.0
我正在关注rolify教程以学习rolify。 https://github.com/RolifyCommunity/rolify/wiki/Devise---CanCanCan---rolify-Tutorial
我按照教程指示完成了每一步。在安装和配置之后,当我转到使用并在控制台中运行user = User.new
时,它向我显示了数千行这样的错误。任何人都可以告诉我如何解决这个问题?
1681 /Users/Cy/.rvm/rubies/ruby-2.3.0/lib/ruby/2.3.0/irb/extend-command.rb
1682 /Users/Cy/.rvm/rubies/ruby-2.3.0/lib/ruby/2.3.0/irb/output-method.rb
1683 /Users/Cy/.rvm/rubies/ruby-2.3.0/lib/ruby/2.3.0/irb/notifier.rb
1684 /Users/Cy/.rvm/rubies/ruby-2.3.0/lib/ruby/2.3.0/irb/slex.rb
1685 /Users/Cy/.rvm/rubies/ruby-2.3.0/lib/ruby/2.3.0/irb/ruby-token.rb
1686 /Users/Cy/.rvm/rubies/ruby-2.3.0/lib/ruby/2.3.0/irb/ruby-lex.rb
1687 /Users/Cy/.rvm/rubies/ruby-2.3.0/lib/ruby/2.3.0/irb/src_encoding.rb
1688 /Users/Cy/.rvm/rubies/ruby-2.3.0/lib/ruby/2.3.0/irb/magic-file.rb
1689 /Users/Cy/.rvm/rubies/ruby-2.3.0/lib/ruby/2.3.0/irb/input-method.rb
1690 /Users/Cy/.rvm/rubies/ruby-2.3.0/lib/ruby/2.3.0/irb/locale.rb
1691 /Users/Cy/.rvm/rubies/ruby-2.3.0/lib/ruby/2.3.0/irb.rb
1692 /Users/Cy/.rvm/rubies/ruby-2.3.0/lib/ruby/2.3.0/irb/completion.rb
1693 /Users/Cy/.rvm/gems/ruby-2.3.0/gems/railties-5.0.0.1/lib/rails/commands/console_helper.rb
1694 /Users/Cy/.rvm/gems/ruby-2.3.0/gems/railties-5.0.0.1/lib/rails/commands/console.rb
1695 /Users/Cy/.rvm/gems/ruby-2.3.0/gems/railties-5.0.0.1/lib/rails/console/app.rb
1696 /Users/Cy/.rvm/gems/ruby-2.3.0/gems/railties-5.0.0.1/lib/rails/console/helpers.rb
1697 /Users/Cy/.rvm/rubies/ruby-2.3.0/lib/ruby/2.3.0/psych/y.rb
1698 /Users/Cy/.rvm/scripts/irbrc.rb
[NOTE]
You may have encountered a bug in the Ruby interpreter or extension libraries.
Bug reports are welcome.
For details: http://www.ruby-lang.org/bugreport.html
答案 0 :(得分:1)
我发现它可能是Spring Gem触发的错误。
所以我的解决方案是在spring stop
rails c
或者只是在Gemfile中删除gem spring
,如果你不需要它。
试试吧!
在这里您可以找到更多相关信息: