I'm getting this in watchdog:
Internal error: Vocabulary 3 () is not our dedicated classified ads vocabulary - someone has tampered with the vocabulary, or our stored variables.
What is its purpose?
Using category module for terms and also added cck fields to the ed_classifieds type.
It throws four errors per page view.

CommentFileSizeAuthor
#7 ed_classified_utils.inc_.patch1.14 KBmcurry

Comments

inforeto’s picture

Found more.
It is on line 480 of ed_classified.module version 1.1.4.41 of 2007/08/05.
In function _ed_tid_is_classified_term($tid) { ... }

The conditional leading to it is:

if ($vocab->hierarchy && $vocab->module == EDI_CLASSIFIED_MODULE_NAME) {

which on my site returns empty, however, using array brackets return the values as normal:

if ($vocab['hierarchy'] && $vocab['module'] == EDI_CLASSIFIED_MODULE_NAME) {

Could it be the category wrapper module that should return the array as object?
or should classified ads module not assume it is an object and use array?

Anyways, the function is used in function ed_classified_link_alter().
It modifies any links to taxonomy terms in either the categories or the nodes, but there's none when using category module.
Those were replaced by category module to links of the form "node/nid" rather than "taxonomy/term" thus classifieds finds no place to insert its own links.

Category has the option to hide the links, so perhaps it wouldn't it be easier if classifieds just inserts its own links, with an equally handy option to hide them.

mcurry’s picture

It's a sanity check to ensure that the expected vocabulary is actually assigned as the classified ads base vocabulary.

Regarding the object vs. array issue, I find it hard to believe that this is a widespread problem, the module has been in use for a long time on Drupal 5, and I've never heard of (nor have I seen) any of these error conditions. I've not tested against latest D5 versions, though

In any case, I'm open to patches to address this, but I'll have to test/verify the changes.

mcurry’s picture

Oh, and if I read your post correctly, you are using the category module - if that is the case, then it'll be a while before I can get around to evaluating any submitted patches, because non-core module support is low on my priority list. If you can submit a patch that fixes this problem when used with the Category module as well as a standard D5 installation, then I'll check it out.

Thanks!

ajzz’s picture

Just upgraded a server from 4.x to 5.x and the above error shows up when accessing individual nodes be it from the ed-classifieds interface or any other custom view. There were also be some issues related to "ed_classifieds" moving to "ed-classifieds"... between the two versions, but that is a different issue by itself

Type	ed_classified
Date	Tuesday, July 1, 2008 - 12:34am
User	anonymous
Location	http://www.xxx.xxx.xxx/node/xxxx
Referrer	
Message	Internal error: Vocabulary 3 (Classified Ads) is not our dedicated classified ads vocabulary - someone has tampered with the vocabulary, or our stored variables.
Severity	error

Note I don't have the category module installed... just taxonomy and ed-classifieds (and other hopefully unrelated modules). Site runs off Drupal CVS (DRUPAL-5) and ed_classifieds (also CVS) currently ed_classified.module/1.1.4.45

ajzz’s picture

Watchdog is getting a lot of bones with these errors on a recently upgraded website (details above). Pls help. Even a workaround hack that disables the check unless unsafe or until a fix is found would do. I tried the brackets in #1 but that did not work.

Thanks in advance.

mcurry’s picture

Status: Needs review » Active

@ajzz: I'll investigate, but I can't promise anything immediate (I have other commitments that are much higher priority right now.)

My advice, if this is a major problem, is to disable the module until a fix is available.

mcurry’s picture

Assigned: Unassigned » mcurry
Priority: Normal » Critical
Status: Active » Needs review
StatusFileSize
new1.14 KB

Ok, here's a quick patch. I'll try to roll it in to the dev branch so it's in an installable package.

ajzz’s picture

Status: Active » Reviewed & tested by the community

Patch tested by changing the category name and accessing ads through taxonomy views instead of the ed-classified default view. Works as intended with breadcrumbs showing correctly on individual nodes as per taxonomy category name and no errors generated. Thanks a ton inactivist for the fix and maintaining the module!

mcurry’s picture

I will try to integrate this patch as soon as I can dedicate some time to testing and CVS work.

mcurry’s picture

Assigned: mcurry » Unassigned
fgm’s picture

Status: Reviewed & tested by the community » Closed (won't fix)

5.x has been dead since Drupal 7 was released. In addition, this was only a problem with Category module, which is actually obsolete itself, with no activity since 2009 and no D7 release. Since the patch does not actually fix the alleged problem but only hide it, closing as won't fix.

fgm’s picture

Priority: Critical » Minor

Forgot to mention that, since it only involved a little-used contrib module and did not prevent Classified Ads from working, this was actually a minor issue, not a critical one.