简体   繁体   English

Ruby on Rails Gem或插件Rails版本

[英]Ruby on Rails Gem or Plugin Rails Version

I am working on a rails 2.3.4 application that I am trying to port over to run with IIS and Helicon Zoo. 我正在尝试将Rails 2.3.4应用程序移植到IIS和Helicon Zoo上运行。 The problem I am encountering is an exception in: 我遇到的问题是以下情况的例外:

c:\Zoo\Workers\ruby\lib\app.rb

where the following exception is getting raised on line ~32: 〜32行引发以下异常:

 STDERR
[tid-21079944] Only Rails 2.3.x and Rails 3.x are currently supported. (RuntimeError)    
C:/Zoo/Workers/ruby/lib/app.rb:33:in `build_app' 
C:/Zoo/Workers/ruby/lib/app.rb:16:in `initialize' 
C:/Zoo/Workers/ruby/lib/worker.rb:4:in `new' 
C:/Zoo/Workers/ruby/lib/worker.rb:4:in `initialize' 
C:/Zoo/Workers/ruby/zoorack.rb:30:in `new' 
C:/Zoo/Workers/ruby/zoorack.rb:30

This is puzzling for me since the version of rails this application was running on previously was 2.3.4. 这让我感到困惑,因为此应用程序以前运行的Rails版本是2.3.4。 The working hypothesis I am going on is that rails somehow can run plugins in a legacy mode? 我要进行的工作假设是,rails可以以旧模式运行插件吗? Does this make sense? 这有意义吗? I am thinking that Helicon Zoo does not support rolling back in this legacy mode prior to 2.3.4. 我认为Helicon Zoo不支持在2.3.4之前的旧模式下回滚。

I hacked up the app.rb file a bit to get at the rails version. 我稍微修改了app.rb文件以获得Rails版本。

Invoking: Rails.version.to_s I am getting: 2.2.2 调用:Rails.version.to_s我正在:2.2.2

Searching the code base for '2.2.2' I see that this project depends on an actionpack lib version 2.2.2. 在代码库中搜索“ 2.2.2”,我看到该项目依赖于actionpack lib版本2.2.2。

Further, do rails plugin versions typically follow the 'rails' version they depend on? 此外,rails插件版本是否通常遵循它们所依赖的“ rails”版本? Is it possible to run plugins that depend on an older 'rails' version than what they run with? 是否可以运行依赖于比其运行版本更旧的“ rails”版本的插件?

The problem here was that I had installed rails 2.3.4 with gem but had copied a 2.2.2 version of rails with the project to the Helicon Zoo web root directory. 这里的问题是我在gem上安装了Rails 2.3.4,但是将项目的2.2.2版本的rails复制到了Helicon Zoo Web根目录中。 The actionpack lib is part of rails. actionpack库是rails的一部分。 I was thinking it was a separate library. 我当时以为这是一个独立的图书馆。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM