rails 5.2 启动警告 warning: previous definition of VERSION was here和bootsnap

bootsnap依赖问题

1 You should add gem 'bootsnap' to your gemfile to install it or remove the line require 'bootsnap/setup' in config/boot.rb

or

1 using rails new myapp --skip-bootsnap
1 If the app doesn’t contain the bootsnap gem already then we will need to add it manually since rails app:update task adds the bootsnap/setup line to boot.rb regardless of its presence in the Gemfile.

 

or

1 https://blog.bigbinary.com/2018/01/01/rails-5-2-adds-bootsnap-to-the-app-to-speed-up-boot-time.html

 

 

warning: previous definition of VERSION was here

 

1 https://github.com/ruby/fileutils/issues/22
 1 Ran into this, and the solution here works: https://stackoverflow.com/questions/51334732/rails-5-2-0-with-ruby-2-5-1-console-warning-already-initialized-constant
 2 
 3 I understand 1.0.2 stays installed as the default, 1.1.0 being installed too. Hence the issue.
 4 
 5 When installed automatically, I get the warnings. Following command shows (new rails app, 2.5.1) :
 6 
 7 gem list | grep fileutils
 8 fileutils (1.1.0, default: 1.0.2)
 9 
10 Then doing:
11 
12 gem uninstall fileutils
13 gem update fileutils --default
14 
15 makes the warnings disappear. And btw, it shows:
16 
17 gem list | grep fileutils
18 fileutils (default: 1.1.0, default: 1.0.2)
19 
20 Hope it will help fixing this annoyance. Sorry I cannot be of more help, not really a wizard with those versioning topics!

 

转载于:https://www.cnblogs.com/or2-/p/9929299.html

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值