When the PHP memory_limit is specified with a "G" suffix rather than "M" suffix, the queue never runs.
This is down to the \WP_Queue\Cron::get_memory_limit function expecting the string to be in megabytes, effectively lopping off the suffix if present and then multiplying up by 1024 * 1024.
So instead of 2G being returned as 2,147,483,648 bytes, it is returned as just 2,097,152 (2Mb), which generally means "used memory" has exceed the returned value and so queue processing isn't even started.
Props to @polevaultweb for finding and fixing this in the plugin that this library was extracted from.
When the PHP memory_limit is specified with a "G" suffix rather than "M" suffix, the queue never runs.
This is down to the
\WP_Queue\Cron::get_memory_limit
function expecting the string to be in megabytes, effectively lopping off the suffix if present and then multiplying up by1024 * 1024
.So instead of
2G
being returned as 2,147,483,648 bytes, it is returned as just 2,097,152 (2Mb), which generally means "used memory" has exceed the returned value and so queue processing isn't even started.Props to @polevaultweb for finding and fixing this in the plugin that this library was extracted from.