更新:此問題已使用相關DevKit
的RubyInstaller
和固定。請參閱下面的答案。紅寶石:角度來說,Hpricot問題 - rb_hash_lookup不能位於MSVCRT-ruby18.dll
在新的WinXP,我們正在努力建立的回報率。我們在運行rails應用程序時遇到了一些問題。調試Hpricot寶石被發現是罪魁禍首。如果我們在一個簡單的Ruby程序中使用Hpricot,會發生同樣的問題。當我們運行其中使用角度來說,Hpricot任何Ruby程序與下面的消息會出現
一個消息框:
The procedure entry point rb_hash_lookup could not be located in the dynamic link library msvcrt-ruby18.dll.
這裏是堆棧跟蹤:
C:/Ruby/lib/ruby/gems/1.8/gems/hpricot-0.8.6-x86-mswin32/lib/hpricot_scan/1.8/hpricot_scan.so: 127: The specified procedure could not be found.
- C:/Ruby/lib/ruby/gems/1.8/gems/hpricot-0.8.6-x86-mswin32/lib/hpricot_scan/1.8/hpricot_scan.so (LoadError)
from C:/Ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in `require'
from C:/Ruby/lib/ruby/gems/1.8/gems/hpricot-0.8.6-x86-mswin32/lib/hpricot_scan.rb:1
from C:/Ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in `gem_original_require'
from C:/Ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in `require'
from C:/Ruby/lib/ruby/gems/1.8/gems/hpricot-0.8.6-x86-mswin32/lib/hpricot.rb:20
from C:/Ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:36:in `gem_original_require'
from C:/Ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:36:in `require'
from hp_test.rb:3
紅寶石:紅寶石1.8.6 (2008-08-11 PATCHLEVEL 287)[I386-mswin32]
紅寶石寶石:1.3.2
Hpricot:0.8.6(它被安裝using gem install hpricot
沒有任何問題)
任何線索?
謝謝。
Hpricot是棄用軟件。你應該考慮使用nokogiri。 – pguardiario 2012-04-19 13:59:22
這是一年的生產,所以搬到nokogiri現在不是一個選項。可能稍晚一些。感謝您的建議。 – Saim 2012-04-19 14:30:03