Problem/Motivation
Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 524288 bytes) in .../www/web/core/lib/Drupal/Core/Database/Query/Condition.php on line 324
I worked around by reverting to version 4.4.4.
Steps to reproduce
I haven't yet been able to reproduce this with a new view. Will keep trying.
Issue fork views_bulk_operations-3591877
Show commands
Start within a Git clone of the project using the version control instructions.
Or, if you do not have SSH keys set up on git.drupalcode.org:
Comments
Comment #3
graber commentedThank you for reporting this, I'm quite sure #3530311: Add additional sort by langcode in ViewsBulkOperationsActionProcessor::getPageList() to avoid non-deterministic database query behavior is the cause here. I'll try to refactor that.
Comment #5
graber commentedPlease test with the fix applied.
Comment #6
hughworm commentedThanks @graber. I applied the change in 3591877-out-of-memory but still got the out of memory.
If it helps, I noticed that, even though I selected one node to process, the count query in Drupal\views\Plugin\views\query\Sql::execute() (line 1576) returned over 20,000, which makes $this->loadEntities($view->result) to cause the out of memory error.
Comment #7
graber commentedIt should help a lot. I suspect there may be an OR condition group applied instead of AND somehow.
The strange thing though is that you’re the only one reporting the issue so far.
Comment #8
graber commentedOk, try this please.
Comment #9
graber commentedSince this is a major issue (I'd probably even make it critical if there was at least one more person reporting but looks like nobody uses a global OR condition making this a very edgy edge case) and the solution is a performance improvement, I'm going to merge it and release a fix now.
Comment #11
graber commentedOk, maybe We'll wait just a bit before releasing.
Comment #13
hughworm commentedI applied the patch to 4.4.5 and got error
"Exception: Unsupported query type: Drupal\views\Plugin\views\query\Sql in Drupal\views_bulk_operations\Service\ViewsBulkOperationsActionProcessor->populateQueue() (line 357 of modules/contrib/views_bulk_operations/src/Service/ViewsBulkOperationsActionProcessor.php)."
If I remove the instanceof check at line 356 the fix works.
Using php 8.2
Comment #14
hughworm commentedAdding
use Drupal\Core\Database\Query\SelectInterface;
to ViewsBulkOperationsActionProcessor.php fixed it.
Comment #15
graber commentedReopening, can you create a MR?
Comment #16
graber commentedhttps://git.drupalcode.org/project/views_bulk_operations/-/blob/4.4.x/sr...