Closed
Description
Symfony version(s) affected
5.4 latest used
Description
| messenger:consume [-l|--limit LIMIT] [-f|--failure-limit FAILURE-LIMIT] [-m|--memory-limit MEMORY-LIMIT] [-t|--time-limit TIME-LIMIT] [--sleep SLEEP] [-b|--bus BUS] [--queues QUEUES] [--no-reset] [--] [<receivers>...]
|
|
| In Connection.php line 351:
|
|
| [ErrorException]
| Warning: Undefined array key 0
|
|
| Exception trace:
| at /var/www/vendor/symfony/redis-messenger/Transport/Connection.php:351
| Symfony\Component\Messenger\Bridge\Redis\Transport\Connection->get() at /var/www/vendor/symfony/redis-messenger/Transport/RedisReceiver.php:41
| Symfony\Component\Messenger\Bridge\Redis\Transport\RedisReceiver->get() at /var/www/vendor/symfony/redis-messenger/Transport/RedisTransport.php:42
| Symfony\Component\Messenger\Bridge\Redis\Transport\RedisTransport->get() at /var/www/vendor/symfony/messenger/Worker.php:101
| Symfony\Component\Messenger\Worker->run() at /var/www/vendor/symfony/messenger/Command/ConsumeMessagesCommand.php:225
| Symfony\Component\Messenger\Command\ConsumeMessagesCommand->execute() at /var/www/vendor/symfony/console/Command/Command.php:298
| Symfony\Component\Console\Command\Command->run() at /var/www/vendor/symfony/console/Application.php:1033
| Symfony\Component\Console\Application->doRunCommand() at /var/www/vendor/symfony/framework-bundle/Console/Application.php:96
| Symfony\Bundle\FrameworkBundle\Console\Application->doRunCommand() at /var/www/vendor/symfony/console/Application.php:299
| Symfony\Component\Console\Application->doRun() at /var/www/vendor/symfony/framework-bundle/Console/Application.php:82
| Symfony\Bundle\FrameworkBundle\Console\Application->doRun() at /var/www/vendor/symfony/console/Application.php:171
| Symfony\Component\Console\Application->run() at /var/www/vendor/symfony/runtime/Runner/Symfony/ConsoleApplicationRunner.php:56
| Symfony\Component\Runtime\Runner\Symfony\ConsoleApplicationRunner->run() at /var/www/vendor/autoload_runtime.php:35
| require_once() at /var/www/bin/console:29
How to reproduce
⚠️ This is the most important part of the report⚠️
Sorry... i have absolutely no idea... Ive only observed it today and only in development where Im stopping and starting workers a lot.
I launch 50 message:consume workers in development, and 3-5 of them each time fail with this, and then auto-restart with supervisor)
As its just a warning, Im hoping its a quick obvious fix for someone closer to the code
Warning: Undefined array key 0
The line in question is
if (![$queuedMessage, $expiry] = $this->rawCommand('ZPOPMIN', 1)) {
https://redis.io/commands/zpopmin
Possible Solution
No response
Additional Context
Redis 6.2.6 server