Trouble using termextraction ge

Posted by mathee on Stack Overflow See other posts from Stack Overflow or by mathee
Published on 2010-06-03T18:35:13Z Indexed on 2010/06/03 18:54 UTC
Read the original article Hit count: 271

Filed under:
|

I'm trying to install this gem: http://github.com/alexrabarts/term_extraction.

It required nokogiri, which I tried installing. I'm getting this as the output:

>gem install nokogiri
Successfully installed nokogiri-1.4.2.1-x86-mswin32
1 gem installed
Installing ri documentation for nokogiri-1.4.2.1-x86-mswin32...

No definition for parse_memory

No definition for parse_file

No definition for parse_with

No definition for get_options

No definition for set_options
Installing RDoc documentation for nokogiri-1.4.2.1-x86-mswin32...

No definition for parse_memory

No definition for parse_file

No definition for parse_with

No definition for get_options

No definition for set_options

I was able to install the termextraction gem (per the README on git repo):

>gem install alexrabarts-term_extraction -s http://gems.github.com
Successfully installed alexrabarts-term_extraction-0.1.4
1 gem installed
Installing ri documentation for alexrabarts-term_extraction-0.1.4...
Installing RDoc documentation for alexrabarts-term_extraction-0.1.4...

The issue is that I'm trying to test it out, but I'm getting an "uninitialized constant" error when I use it:

ActionView::TemplateError (uninitialized constant ApplicationHelper::TermExtraction) on line #3 of app/views/questions/new.
haml:
1: %h1 New question
2: -msg = "testing this context thing let's see what it gives me"
3: -getTerms(msg)
4: #new-question-form
5:   .box-background
6:     -form_for(@question) do |f|

    app/helpers/application_helper.rb:42:in `getTerms'
    app/views/questions/new.haml:3:in `_run_haml_app47views47questions47new46haml'
    haml (2.2.23) lib/haml/helpers/action_view_mods.rb:13:in `render'
    haml (2.2.23) lib/haml/helpers/action_view_mods.rb:13:in `render'
    app/controllers/questions_controller.rb:91:in `new'
    haml (2.2.23) lib/sass/plugin/rails.rb:20:in `process'

Here is application_helper.rb:

module ApplicationHelper
  def getTerms(context)
    yahoo = TermExtraction::Yahoo.new(:api_key => 'myAPIkey', :context => context)
  end
end

I'm not sure what the issue is. Any insight would be greatly appreciated!

© Stack Overflow or respective owner

Related posts about ruby-on-rails

Related posts about rubygems