gpt4 book ai didi

ruby-on-rails - 加载错误 : cannot load such file -- tiny_tds/tiny_tds

转载 作者:数据小太阳 更新时间:2023-10-29 08:11:24 39 4
gpt4 key购买 nike

首先声明我不是 Ruby 开发人员。我只是想在 Windows x64 上安装 Redmine。我在这里发现了类似的问题,我稍后会链接到。但由于我不是 Ruby 开发人员,所以我不理解答案,也无法将它们应用到我的情况中。所以请在您的回答中稍微详细一点,以便我能够完全理解我在做什么。

我进入 Redmine Install 中的第 5 步并生成以下错误:

C:\redmine\redmine-3.2.3>bundle exec rake generate_secret_token
C:/Ruby22-x64/lib/ruby/gems/2.2.0/gems/htmlentities-4.3.1/lib/htmlentities/mappings/expanded.rb:465: warning: duplicated key at line 466 ignored: "inodot"
rake aborted!
LoadError: cannot load such file -- tiny_tds/tiny_tds
C:/redmine/redmine-3.2.3/config/application.rb:5:in `<top (required)>'
C:/redmine/redmine-3.2.3/Rakefile:5:in `require'
C:/redmine/redmine-3.2.3/Rakefile:5:in `<top (required)>'
LoadError: cannot load such file -- tiny_tds/2.2/tiny_tds
C:/redmine/redmine-3.2.3/config/application.rb:5:in `<top (required)>'
C:/redmine/redmine-3.2.3/Rakefile:5:in `require'
C:/redmine/redmine-3.2.3/Rakefile:5:in `<top (required)>'
(See full trace by running task with --trace)

查看this answerthis answer ,我看到查看 Redmine 的 Gemfile 和我的 gem 列表应该提供一些关于问题的见解。

问题似乎出在 tiny_tds 上,Gemfile 中唯一提到的地方是:

when /sqlserver/
gem "tiny_tds", "~> 0.6.2", :platforms => [:mri, :mingw, :x64_mingw]
gem "activerecord-sqlserver-adapter", :platforms => [:mri, :mingw, :x64_mingw]

来 self 的 gem 列表:

rake (11.2.2, default: 10.4.2)
tiny_tds (1.0.4, 0.6.2 x64-mingw32)

在我看来,我安装了多个版本的 raketiny_tds,但它选择了错误的版本。上面链接的一个答案似乎表明需要编辑 Gemfile 以选择正确的版本,另一个似乎表明使用 bundle exec 应该为我解决这个问题。

那么我需要在这里做什么来完成这个安装呢?

最佳答案

我遇到了这个问题(对于 webdev 来说是全新的)但是在四处搜索之后,我通过运行以下命令让一切正常工作

gem install tiny_tds 

# Run these next commands within the tiny_tds directory.

# Now install the dependencies (Requires bundler)
bundle install

# Now compile the gem. (Requires docker toolbox)
rake gem:windows

Here是 tiny_tds 自述文件部分的链接,他在其中介绍了 windows 安装。希望这会有所帮助。

关于ruby-on-rails - 加载错误 : cannot load such file -- tiny_tds/tiny_tds,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/37926292/

39 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com