There may not be anything to be done here, but I'm interested to see if anyone can replicate.

We have a node type that includes a multifield. That multifield includes a taxonomy reference field that uses autocomplete.

Works fine if only one element can be selected, but if multiple submissions are made, the entity cache misfires and throws out a notice (see attached).

This error seems to happen because the static caching in entity.inc can't properly account for the loading of multiple multifield entities while the node is being validated. Removing the static cache from taxonomy terms fixes the error.

To reproduce:

* Create a multifield with a taxonomy autocomplete widget.
* Attach that multifield to a node type.
* Allow multiple (unlimited) entries to that multifield.
* Create a node
* Choose more than one taxonomy autocomplete selection.
* Save the node.

I have also attached a bunch of screenshots of the field settings.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Dave Reid’s picture

Version: 7.x-1.0-unstable9 » 7.x-1.x-dev

I can replicate the error, but it might actually be a taxonomy module error. The error stems from taxonomy_autocomplete_validate() calling taxonomy_term_load_multiple(). If I run the same term load twice I get the same error without multifield, but I'm guessing this is exposed due to multifield calling some validation twice.

taxonomy_term_load_multiple(array(), array('name' => 'test1', 'vid' => array(1)));
taxonomy_term_load_multiple(array(), array('name' => 'test1', 'vid' => array(1)));
Dave Reid’s picture

agentrickard’s picture

Dave Reid++