本文介绍了Ruby无法从open3模块中找到方法capture2e的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我尝试使用脚本和我只是不能得到它的工作。它一直给我的错误:


脚本在开始时执行需要Open3 。我不明白问题在哪里!我不知道Ruby。但是,我可以智能地读取和编辑代码。

脚本需要1.9。 有一个 popen3 类方法,没有别的。 的 capture2 capture2e 您正在查找的类方法。所以你需要升级你的Ruby到1.9或者找到另一个脚本。


I am trying to use the script blogger.rb and I just can't get it work. It keeps giving me the error :

The script does a require Open3 in the beginning. I don't understand where is the problem ! I have no knowledge of Ruby. However, I can intelligently read and edit codes in general.

解决方案

I'd guess that you're using Ruby 1.8 but the script requires 1.9. The Open3 class in 1.8.7 has a popen3 class method and nothing else. The Ruby 1.9 Open3 has the capture2 and capture2e class methods that you're looking for. So you need to upgrade your Ruby to 1.9 or find another script.

这篇关于Ruby无法从open3模块中找到方法capture2e的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

10-28 19:17