Certain modules have their own content type. As an example, take the Forum module, which has the forum content type. Content types often have a taxonomy structure related to them. In case of the Forum module the taxonomy is crucial because the entire forum structure depends on it. A list of node types can be associated with a certain vocabulary. The following problem occurs when a module is disabled:

"when a module is disabled, the corresponding node type is removed from the vocabulary_node_types table."

If a module is enabled again, the corresponding node type is not automatically added in the vocabulary_node_types table. In case of the Forum module this gets even worse, because there is no way to set the node type for the Forum vocabulary (the forum module disables this option for some reason). Only adding the node type manually to the table helps in this case.

Note that Drupal upgrade instructions say that all contributed modules should be disabled before upgrading, which causes the corresponding node types in the vocabulary_node_types table to be deleted. Some contributed modules (e.g. Project Module) don't care whether the Projects vocabulary is assigned to the project node type, but other modules might suffer from this. I'm not a Drupal code expert, but I cannot see the reason for removing the node type and the corresponding vocabulary from the vocabulary_node_types table when a module that supplies the node type is disabled. This causes a lot of problems, see for example:

http://drupal.org/node/185918
http://drupal.org/node/170118
http://drupal.org/node/118157
http://drupal.org/node/84180

or just search the Drupal site for vocabulary_node_types. For the Forum module, there is no way to repair the vocabulary_node_types table using the Categories administration page in Drupal; one has to edit the database manually, so at least for the Forum module this should be considered a bug.

Comments

avskip’s picture

Priority: Normal » Critical

I just went through this with the Forums module. It took a while, but I finally figured out I had to set the #1 record to the word forum in the 'vocabulary_node_types` table.

This is something that I would consider critical!

leop’s picture

Probably there are a lot of contributed modules that suffer from this problem. I can now confirm that the problem also occurs with the bibliography module.

leop’s picture

Version: 5.5 » 5.6

problem persists in 5.6

keesje’s picture

Confirmed

leop’s picture

Version: 5.6 » 5.7

problem persists in 5.7

drumm’s picture

Status: Active » Closed (duplicate)