Mechanize

Posted by muchag | Ruby on Rails | 2012-04-22 (日) 17:33:48

話には聞いていた スクレイピング定番のライブラリらしい。

【環境】
[Ruby] 1.9.3-p194
[Rails] 3.2.3
インストール
  1. > gem install mechanize
  2. Fetching: net-http-digest_auth-1.2.gem (100%)
  3. Fetching: net-http-persistent-2.6.gem (100%)
  4. Fetching: nokogiri-1.5.2-x86-mingw32.gem (100%)
  5. Fetching: ntlm-http-0.1.1.gem (100%)
  6. Fetching: webrobots-0.0.13.gem (100%)
  7. Fetching: unf_ext-0.0.4-x86-mingw32.gem (100%)
  8. Fetching: unf-0.0.5.gem (100%)
  9. Fetching: domain_name-0.5.3.gem (100%)
  10. Fetching: mechanize-2.4.gem (100%)
  11. Successfully installed net-http-digest_auth-1.2
  12. Successfully installed net-http-persistent-2.6
  13. Successfully installed nokogiri-1.5.2-x86-mingw32
  14. Successfully installed ntlm-http-0.1.1
  15. Successfully installed webrobots-0.0.13
  16. Successfully installed unf_ext-0.0.4-x86-mingw32
  17. Successfully installed unf-0.0.5
  18. Successfully installed domain_name-0.5.3
  19. Successfully installed mechanize-2.4
  20. 9 gems installed
  21. Installing ri documentation for net-http-digest_auth-1.2...
  22. Installing ri documentation for net-http-persistent-2.6...
  23. Installing ri documentation for nokogiri-1.5.2-x86-mingw32...
  24. unable to convert "\xE5" to UTF-8 in conversion from ASCII-8BIT to UTF-8 to Windows-31J for CHANGELOG.ja.rdoc, skipping
  25. unable to convert "\xE9" to UTF-8 in conversion from ASCII-8BIT to UTF-8 to Windows-31J for README.ja.rdoc, skipping
  26. unable to convert "\xE8" to UTF-8 in conversion from ASCII-8BIT to UTF-8 to Windows-31J for CHANGELOG.rdoc, skipping
  27. unable to convert "\xE2" to UTF-8 in conversion from ASCII-8BIT to UTF-8 to Windows-31J for ext/nokogiri/xml_node_set.c, skipping
  28. Installing ri documentation for ntlm-http-0.1.1...
  29. Installing ri documentation for webrobots-0.0.13...
  30. Installing ri documentation for unf_ext-0.0.4-x86-mingw32...
  31. Installing ri documentation for unf-0.0.5...
  32. Installing ri documentation for domain_name-0.5.3...
  33. Installing ri documentation for mechanize-2.4...
  34. unable to convert "\xE3" to UTF-8 in conversion from ASCII-8BIT to UTF-8 to Windows-31J for CHANGELOG.rdoc, skipping
  35. Installing RDoc documentation for net-http-digest_auth-1.2...
  36. Installing RDoc documentation for net-http-persistent-2.6...
  37. Installing RDoc documentation for nokogiri-1.5.2-x86-mingw32...
  38. unable to convert "\xE5" to UTF-8 in conversion from ASCII-8BIT to UTF-8 to Windows-31J for CHANGELOG.ja.rdoc, skipping
  39. unable to convert "\xE9" to UTF-8 in conversion from ASCII-8BIT to UTF-8 to Windows-31J for README.ja.rdoc, skipping
  40. unable to convert "\xE8" to UTF-8 in conversion from ASCII-8BIT to UTF-8 to Windows-31J for CHANGELOG.rdoc, skipping
  41. unable to convert "\xE2" to UTF-8 in conversion from ASCII-8BIT to UTF-8 to Windows-31J for ext/nokogiri/xml_node_set.c, skipping
  42. Installing RDoc documentation for ntlm-http-0.1.1...
  43. Installing RDoc documentation for webrobots-0.0.13...
  44. Installing RDoc documentation for unf_ext-0.0.4-x86-mingw32...
  45. Installing RDoc documentation for unf-0.0.5...
  46. Installing RDoc documentation for domain_name-0.5.3...
  47. Installing RDoc documentation for mechanize-2.4...
  48. unable to convert "\xE3" to UTF-8 in conversion from ASCII-8BIT to UTF-8 to Windows-31J for CHANGELOG.rdoc, skipping

また文字コードっぽいエラー。。。

このとき RubyGems と Rails のヴァージョンが古いとエラーになるそうな。
RubyStudyRoom:WWW::Mechanizeをインストール

Ruby on Rails | 2012-04-22 (日) 17:33:48 |

コメントはまだありません »

No comments yet.

RSS feed for comments on this post. TrackBack URI

Leave a comment