Skip to content

Commit

Permalink
Always return bool from messenger amqp conncetion nack
Browse files Browse the repository at this point in the history
  • Loading branch information
Danielss89 authored Aug 9, 2023
1 parent 9d69dd6 commit 24e5cc9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Transport/Connection.php
Original file line number Diff line number Diff line change
Expand Up @@ -461,7 +461,7 @@ public function ack(\AMQPEnvelope $message, string $queueName): bool

public function nack(\AMQPEnvelope $message, string $queueName, int $flags = \AMQP_NOPARAM): bool
{
return $this->queue($queueName)->nack($message->getDeliveryTag(), $flags);
return $this->queue($queueName)->nack($message->getDeliveryTag(), $flags) ?? true;
}

public function setup(): void
Expand Down

8 comments on commit 24e5cc9

@luciancodeman
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you please tag this commit as v5.4.23?

@vvrein
Copy link

@vvrein vvrein commented on 24e5cc9 Aug 21, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you please tag this commit as v5.4.23?

@luciancodeman as a quick fix, you can use 24e5cc90da041e0e1b7bbe15b82ad7f27a508c01 instead of 6343af983ba7460f7ea984aacb95d1ed382f6e40 in your composer.lock

@luciancodeman
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you @vvrein!

@Pum-purum
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please tag this commit. Composer install + hash does change nothing

@StaffNowa
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey, do we have another bug?

Symfony\Component\Messenger\Bridge\Amqp\Transport\Connection::ack(): Return value must be of type bool, null returned 

@Nicolas-Open
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi, thanks for the fix, it works for me.
Please can you release this fix in 5.4.23 tag ?
Thanks

@omrqs
Copy link

@omrqs omrqs commented on 24e5cc9 Aug 24, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Up

@adrienHoareau
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In my case, to prevent this error, I locked the php extension amqp to version 1.11.0 in my docker file so that it does not update to the new version
install-php-extensions amqp-1.11.0

Please sign in to comment.