草庐IT

mongodb - mongoDB安装错误

全部标签

jquery - Ruby 1.9.1、Rails 2.3.2 和 jrails 0.4 出现 "rescue in const_missing"错误

我最近开始了一个项目,团队决定我们希望使用jQuery而不是Prototype/Scriptaculous来满足我们的javascript需求。我们设置了我们的项目,并开始切换。插件已安装viatheseinstructions,一切都按计划进行。不久之后,当尝试运行“./script/server”时,我们收到以下错误:=>Rails2.3.2applicationstartingonhttp://0.0.0.0:3000/usr/local/lib/ruby/gems/1.9.1/gems/activesupport-2.3.2/lib/active_support/depende

ruby - 在我的 Mac 上安装 ruby​​ gem json 时遇到问题

我在尝试通过ruby​​gems安装json模块时收到此警告。有什么想法吗?Mac-Minipoulh$sudogeminstalljsonPassword:WARNING:File'/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/gems/1.8/specifications/json-1.2.0.gemspec'doesnotevaluatetoagemspecificationBuildingnativeextensions.Thiscouldtakeawhile...ERROR:Errori

ruby - 无法安装任何 gem

我已经使用JavaScript和一些Erlang大约六个月了,最近我没有进行任何Rails编程。今天在我的新电脑上我去安装Rails但出现了这个错误:geminstallrailsWARNING:RubyGems1.2+indexnotfoundfor:http://gems.rubyforge.org/RubyGemswillreverttolegacyindexesdegradingperformance.BulkupdatingGemsourceindexfor:htp://gems.rubyforge.org/ERROR:Whileexecutinggem...(Gem::Re

ruby - 错误的参数类型字符串(应为数组)

我正在尝试使用Octopress(Jekyll之上的博客引擎)在我的新Macbook上,当我运行bundleexecjekyll--server时出现此错误:(缩短路径)/path/to/markdown.rb:118:in`to_html':wrongargumenttypeString(expectedArray)(TypeError)from/path/to/markdown.rb:118:in`convert'...(完整路径)/usr/local/rvm/gems/ruby-1.9.2-p290/gems/jekyll-0.11.0/lib/jekyll/converters

ruby - 调用 instance_eval(&lambda) 传递当前上下文时出现错误 'wrong number of arguments'

要清楚-此代码运行完美-codewithproc但如果我将Proc.new更改为lambda,则会出现错误ArgumentError:wrongnumberofarguments(1for0)这可能是因为instance_eval想要将self作为参数传递,而lambda将其视为一种方法并且不接受未知参数?有两个例子-第一个是工作:classRuledefget_ruleProc.new{putsname}endendclassPersonattr_accessor:namedefinit_rule@name="ruby"instance_eval(&Rule.new.get_rule

ruby-on-rails - 带有内联附件的 Rails 邮件程序错误

我在ActionMailer中有一个非常罕见的行为,我在5个月前实现了一个邮件程序操作并且它工作正常,但昨天,由于一些奇怪的原因,它崩溃了。问题我有一个邮件布局,为了在我所有的电子邮件中使用它,我在其中渲染了一张之前由前置过滤器附加的图像Layout=app/views/layouts/email.html.erbVisionamos>......用户邮件程序=app/mailers/users.rbclassUsuariosMailer"monitoreo@visionamos.com"layout"mail"#Setemaillayoutbefore_filter:add_inli

ruby - 如何解决错误消息 "Cannot find module ' abbrev'

我的问题与HowdoIresolve"Cannotfindmodule"errorusingNode.js?非常相似,但我无法使用给出的答案中提供的信息解决我的问题。我尝试运行UNCSSgrunt插件,但是当我尝试安装它时(npminstallgrunt-uncss--save-dev),我收到以下错误:$npminstallgrunt-uncss--save-devmodule.js:340throwerr;^Error:Cannotfindmodule'abbrev'atFunction.Module._resolveFilename(module.js:338:15)atFunc

ruby - 使用 watir-webdriver 打开多个线程导致 'Connection refused' 错误

我有这个简单的例子:require'watir-webdriver'arr=[]sites=["www.google.com","www.bbc.com","www.cnn.com","www.gmail.com"]sites.eachdo|site|arr每次我运行这个脚本,我都会得到ruby/2.1.0/net/http.rb:879:in`initialize':Connectionrefused-connect(2)for"127.0.0.1"port9517(Errno::ECONNREFUSED)或者其中一个浏览器在至少一个线程上意外关闭。另一方面,如果我在每个循环周期结束

ruby - Rails+ActiveAdmin - 使用 ransacker 过滤会抛出错误 PG::SyntaxError: ERROR: syntax error at or near ","

我在RubyonRails4.1.4上有一个项目,使用来自git://github.com/activeadmin/activeadmin的activeadmin1.0.0.pre,pg0.17.1,PostgreSQL9.3在项目中我有这些模型:类用户has_one:账户类账户属于:用户有很多:project_accountshas_many:项目,:through=>:project_accounts类项目#该项目有一个bool属性'archive'has_many:project_accounts类ProjectAccount属于:帐户属于:项目我有一个任务是在索引页面上实现一个

ruby - 在 Ubuntu 14.04 上使用 RVM 安装 Ruby 2.2.2 时出错

这是什么。我首先做了:rvmgetstablervminstallruby-2.2.2没有交易。它向我展示了以下内容:$rvminstallruby-2.2.2Searchingforbinaryrubies,thismighttakesometime.Nobinaryrubiesavailablefor:ubuntu/14.04/i386/ruby-2.2.2.Continuingwithcompilation.Pleaseread'rvmhelpmount'togetmoreinformationonbinaryrubies.Checkingrequirementsforubunt