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.
Comment | File | Size | Author |
---|---|---|---|
Screen Shot 2014-04-05 at 6.03.30 PM.png | 23.35 KB | agentrickard | |
Screen Shot 2014-04-05 at 6.03.16 PM.png | 8.05 KB | agentrickard | |
Screen Shot 2014-04-05 at 6.02.58 PM.png | 55.5 KB | agentrickard | |
Screen Shot 2014-04-05 at 6.02.15 PM.png | 47.07 KB | agentrickard | |
add product2.png | 69.03 KB | agentrickard |
Comments
Comment #1
Dave ReidI 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.
Comment #2
Dave ReidConfirmed this is a core bug and would be fixed by #1525176: Using array_diff_assoc() for multilevel arrays in DrupalDefaultEntityController->cacheGet()
Comment #3
agentrickardDave Reid++