When editing nodes I get a "Fatal error: Call to undefined method AlchemyAPI::TextGetRankedConcepts() in /home/xxxxxx/sites/all/modules/alchemy/alchemy.module on line 99"

Drupal 6.20
Alchemy rc5

CommentFileSizeAuthor
#6 AlchemyAPI.zip2.56 KBjsheppard
#5 AlchemyAPI_PHP5-0.6.tar_.gz55.02 KBjsheppard

Comments

TomDude48’s picture

Status: Active » Needs review

I can't reproduce this issue. Check your AlchemyAPI.php file from the SDK from alchemyapi.com. On line 118 you should have this method:

public function TextGetRankedConcepts($text, $outputMode = self::XML_OUTPUT_MODE, $conceptParams = null)

If you don't see it, make sure you have the correct SDK from Alchemy.

If you are still having a problem, submit the AlchemyAPI.php file so I can get a better handle on what is going on.

jsheppard’s picture

I have a similar issue (though referring to a different line in the module code)

Fatal error: Call to undefined method AlchemyAPI::TextGetRankedConcepts() in /home1/database_name/public_html/mysite/sites/all/modules/alchemy/alchemy.module on line 101.

Originally I had questions about the proper install directory for the API as well and was receiving a similar fatal error only for line 119 as this Drupal user has experienced.

Reading through the Issues board, I saw the response given to another user who shared my question (Where do I install the API?). So, I turned off the Alchemy module and made sure to install the API in the directory you showed in the screenshot. I then re-enabled the Alchemy modules and have attempted to access and/or save a node. Now, I receive this fatal error (now on line 101 rather than line 119).

I would welcome any advice you can provide.

Have a great day,

rastarr’s picture

Version: 6.x-1.0-rc5 » 6.x-1.0-rc6

Subscribing - same error as jsheppard

TomDude48’s picture

Hi jsheppard and rastarr,

Can one of you upload your AlchemyAPI.php file so I can look at it.

jsheppard’s picture

StatusFileSize
new55.02 KB

Sure. I've attached it here.

jsheppard’s picture

StatusFileSize
new2.56 KB

Actually here's the actual file.

MrStas’s picture

same issue.
after some debugging I found that in alchemy.module in
function alchemy_include_alchemy_class() we have following code
.
.
if (class_exists('AlchemyAPI')) {
return TRUE;
}
.
.
this code always return true (for first load)
I did not find any other place than alchemy_include_alchemy_class() where alchemyAPI is loading. Btw I delete all from AlchemyAPI directory and class_exists('AlchemyAPI') still return true
UPDATE:
Have found that this module conflicted whith module "Tagging" (which also use AlchemyAPI), after disable Tagging my error dissapear.

jsheppard’s picture

MrStas,

This is helpful. Thank you. Are you leaving the Tagging module itself enabled and just turning off the Alchemy sub modules that depend on the Tagging module (Alchemy tagging suggestions and Tagging AlchemyAPI suggestions)? Or, are you also turning off Tagging, Tagging vocab extractor suggestions, and Tagging full-vocabulary suggestion)?

Thank you in advance,

proindustries’s picture

Hey John - What I'm seeing with the issue is if I enable the "Tagging AlchemyAPI suggestions" module, I'll get

PHP Fatal error: Call to undefined method AlchemyAPI::TextGetRankedConcepts() in ...modules/alchemy/alchemy.module on line 101

Disabling that module, the issue Goes Away.

Not directly related, but for others attempting to re-create this, make sure Alchemy is not configured to use cached data, as that'll produce a false negative when trying to reproduce this.

Marko B’s picture

Had the same problem, went away when i disabled "Tagging AlchemyAPI suggestions" module. But only if i used previously cached page with terms. On new page i didnt get any terms when i disabled this.

technologywon’s picture

Issue summary: View changes
Status: Needs review » Closed (outdated)

Drupal 6 is no longer supported