[drupal-devel] [bug] node_invoke_nodeapi recursion

Iluvatar drupal-devel at drupal.org
Sat Sep 17 13:05:17 UTC 2005

Issue status update for 
Post a follow up: 

 Project:      Drupal
 Version:      cvs
-Component:    module system
+Component:    node system
 Category:     bug reports
 Priority:     critical
 Assigned to:  Anonymous
 Reported by:  Iluvatar
 Updated by:   Iluvatar
 Status:       patch (code needs review)

Sorry, component should be node system not module system.


Previous comments:

Sat, 17 Sep 2005 13:04:31 +0000 : Iluvatar

Attachment: http://drupal.org/files/issues/node.module_12.patch (696 bytes)

I have had some weird problems, most of them involving hook_nodeapi. It
is difficult to explain. For one of the problems see my comment at

Another problem was that I broke the upload module, by calling
node_load in hook_nodeapi($op = 'validate') in some module. This caused
node_invoke_nodeapi to be called recursively, which doesn't work as
expected because of the caching that module_implements does.

Sorry, I know all of this is kind of vague, but I can't explain it any
better. You can take a look at my patch how I solved the problem. I
think this patch does not have any impact on performance, and to
prevent unexpected behavior involving hook_nodeapi this patch should be
committed. If this patch is committed, a comment should be added to the
code so that future developers will not change it back.

More information about the drupal-devel mailing list