【问题标题】:Does TinyTDS support Ruby 2.0.0?TinyTDS 是否支持 Ruby 2.0.0?
【发布时间】:2013-05-26 01:00:33
【问题描述】:

我在尝试让 TinyTDS 在 Windows 7 上与 Ruby 2.0.0 一起工作时遇到了真正的麻烦。

当我从irb 运行rails c(或require tiny_tds)时,我得到以下信息:

D:/Ruby/Ruby200/lib/ruby/gems/2.0.0/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:251:in `require': cannot load such file -- tiny_tds/tiny_tds (LoadError)
            from D:/Ruby/Ruby200/lib/ruby/gems/2.0.0/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:251:in `block in require'
            from D:/Ruby/Ruby200/lib/ruby/gems/2.0.0/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:236:in `load_dependency'
            from D:/Ruby/Ruby200/lib/ruby/gems/2.0.0/gems/activesupport-3.2.13/lib/active_support/dependencies.rb:251:in `require'
            from D:/Ruby/Ruby200/lib/ruby/gems/2.0.0/gems/tiny_tds-0.5.1-x86-mingw32/lib/tiny_tds.rb:16:in `rescue in <top (required)>'
            from D:/Ruby/Ruby200/lib/ruby/gems/2.0.0/gems/tiny_tds-0.5.1-x86-mingw32/lib/tiny_tds.rb:12:in `<top (required)>'
            from D:/Ruby/Ruby200/lib/ruby/gems/2.0.0/gems/bundler-1.3.5/lib/bundler/runtime.rb:72:in `require'
            from D:/Ruby/Ruby200/lib/ruby/gems/2.0.0/gems/bundler-1.3.5/lib/bundler/runtime.rb:72:in `block (2 levels) in require'
            from D:/Ruby/Ruby200/lib/ruby/gems/2.0.0/gems/bundler-1.3.5/lib/bundler/runtime.rb:70:in `each'
            from D:/Ruby/Ruby200/lib/ruby/gems/2.0.0/gems/bundler-1.3.5/lib/bundler/runtime.rb:70:in `block in require'
            from D:/Ruby/Ruby200/lib/ruby/gems/2.0.0/gems/bundler-1.3.5/lib/bundler/runtime.rb:59:in `each'
            from D:/Ruby/Ruby200/lib/ruby/gems/2.0.0/gems/bundler-1.3.5/lib/bundler/runtime.rb:59:in `require'
            from D:/Ruby/Ruby200/lib/ruby/gems/2.0.0/gems/bundler-1.3.5/lib/bundler.rb:132:in `require'
            from S:/code/user/app/ruby2_test/config/application.rb:7:in `<top (required)>'
            from D:/Ruby/Ruby200/lib/ruby/gems/2.0.0/gems/railties-3.2.13/lib/rails/commands.rb:39:in `require'
            from D:/Ruby/Ruby200/lib/ruby/gems/2.0.0/gems/railties-3.2.13/lib/rails/commands.rb:39:in `<top (required)>'
            from script/rails:6:in `require'
            from script/rails:6:in `<main>'

我已尝试安装最新版本的 gem:

gem install tiny_tds --pre

往里看:

D:\Ruby\Ruby200\lib\ruby\gems\2.0.0\gems\tiny_tds-0.6.0.rc1-x86-mingw32\lib\tiny_tds

我可以看到没有 2.0 目录,这让我相信不支持 2.0 版。但是,我在 TinyTDS github 或任何其他网站上看不到有关此问题的任何提及。

那么,是我遗漏了什么还是 TinyTDS 目前无法与 Ruby 2.0 一起使用?

【问题讨论】:

  • Windows 7,x64。抱歉会更新问题
  • 你可以尝试卸载gem uninstall tiny_tds然后用gem install tiny_tds --platform=ruby重新安装
  • 也来自以下 GitHub 问题:github.com/rails-sqlserver/tiny_tds/issues/110。 MetaSkills 他说Windows users, we are going to have to wait for rake-compiler to be solved. 所以我相信这是我担心的 Windows 的依赖问题。
  • gem install tiny_tds --platform=ruby 给出libiconv is missing 错误。关于 rake-compiler - 它是什么? bundle show rake-compilerCould not find gem 'rake-compiler'
  • 我相信这是您使用的操作系统的问题,因为另一个人也有同样的问题。如前所述,我认为这是 Windows 的依赖问题。请看MetaSkills-github.com/rails-sqlserver/tiny_tds/issues/…的评论

标签: ruby-on-rails ruby ruby-2.0 tiny-tds


【解决方案1】:

从 cmets 复制答案,以便从“未回答”过滤器中删除此问题:

我认为这是您用作另一个操作系统的问题 个人有同样的问题。如前所述,我相信这是一个 Windows 的依赖问题。请参阅 MetaSkills 的评论 - https://github.com/rails-sqlserver/tiny_tds/issues/110#issuecomment-15503928

~回答David

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2018-12-30
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2011-05-31
    • 2013-06-24
    • 2023-04-10
    • 2011-01-13
    相关资源
    最近更新 更多