From 5afbd95b1b11d60002638b6cfc1ee98266f13676 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=9C=D0=B0=D0=BA=D1=81=D0=B8=D0=BC=20=D0=A1=D0=BF=D0=B8?= =?UTF-8?q?=D1=80=D0=BA=D0=BE=D0=B2?= Date: Sat, 1 Aug 2026 14:53:16 +0400 Subject: [PATCH 1/4] Generate `@property` annotations --- phpstan-baseline.neon | 12 ++++++------ src/cli/InfoAction.php | 1 - src/drivers/amqp_interop/Queue.php | 1 - src/drivers/beanstalk/Queue.php | 3 +-- src/drivers/db/Queue.php | 2 +- src/drivers/file/Queue.php | 2 +- src/drivers/redis/Queue.php | 2 +- 7 files changed, 10 insertions(+), 13 deletions(-) diff --git a/phpstan-baseline.neon b/phpstan-baseline.neon index 7a708c6e6..c6d9defa7 100644 --- a/phpstan-baseline.neon +++ b/phpstan-baseline.neon @@ -54,6 +54,12 @@ parameters: count: 1 path: src/cli/Command.php + - + message: '#^Call to an undefined method yii\\base\\Controller\:\:stdout\(\)\.$#' + identifier: method.notFound + count: 9 + path: src/cli/InfoAction.php + - message: '#^Cannot call method getComponents\(\) on yii\\console\\Application\|yii\\web\\Application\\|null\.$#' identifier: method.nonObject @@ -1331,9 +1337,3 @@ parameters: identifier: missingType.iterableValue count: 1 path: tests/serializers/TestCase.php - - - - message: '#^Access to constant ATTR_INIT_COMMAND on an unknown class Pdo\\Mysql\.$#' - identifier: class.notFound - count: 1 - path: tests/app/config/main.php diff --git a/src/cli/InfoAction.php b/src/cli/InfoAction.php index cd47a4d9b..d078f7b50 100644 --- a/src/cli/InfoAction.php +++ b/src/cli/InfoAction.php @@ -24,7 +24,6 @@ * * @author Kalmer Kaurson * - * @property Controller $controller */ class InfoAction extends Action { diff --git a/src/drivers/amqp_interop/Queue.php b/src/drivers/amqp_interop/Queue.php index 62a2553c1..6f10abe64 100644 --- a/src/drivers/amqp_interop/Queue.php +++ b/src/drivers/amqp_interop/Queue.php @@ -34,7 +34,6 @@ * Amqp Queue. * * @property-read AmqpContext $context - * @property-read AmqpQueue $queue * * @author Maksym Kotliar * @since 2.0.2 diff --git a/src/drivers/beanstalk/Queue.php b/src/drivers/beanstalk/Queue.php index 3984a76e4..ab0e8c265 100644 --- a/src/drivers/beanstalk/Queue.php +++ b/src/drivers/beanstalk/Queue.php @@ -24,8 +24,7 @@ /** * Beanstalk Queue. * - * @property-read TubeName $tubeName - * @property-read object $statsTube Tube statistics. + * @property-read TubeStats $statsTube Tube statistics. * * @author Roman Zhuravlev */ diff --git a/src/drivers/db/Queue.php b/src/drivers/db/Queue.php index 500babcc5..84003c0f8 100644 --- a/src/drivers/db/Queue.php +++ b/src/drivers/db/Queue.php @@ -23,7 +23,7 @@ /** * Db Queue. * - * @property-read StatisticsProvider $statisticsProvider + * @property-read StatisticsInterface $statisticsProvider * * @author Roman Zhuravlev */ diff --git a/src/drivers/file/Queue.php b/src/drivers/file/Queue.php index 8caaa0075..3edf52b36 100644 --- a/src/drivers/file/Queue.php +++ b/src/drivers/file/Queue.php @@ -22,7 +22,7 @@ /** * File Queue. * - * @property-read StatisticsProvider $statisticsProvider + * @property-read StatisticsInterface $statisticsProvider * * @author Roman Zhuravlev */ diff --git a/src/drivers/redis/Queue.php b/src/drivers/redis/Queue.php index 0c17a1f67..11ce0fc45 100644 --- a/src/drivers/redis/Queue.php +++ b/src/drivers/redis/Queue.php @@ -21,7 +21,7 @@ /** * Redis Queue. * - * @property-read StatisticsProvider $statisticsProvider + * @property-read StatisticsInterface $statisticsProvider * * @author Roman Zhuravlev */ From 7dd6a05382bf8691e2255fe4e35305cd8a84a87a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=9C=D0=B0=D0=BA=D1=81=D0=B8=D0=BC=20=D0=A1=D0=BF=D0=B8?= =?UTF-8?q?=D1=80=D0=BA=D0=BE=D0=B2?= Date: Sat, 1 Aug 2026 14:53:31 +0400 Subject: [PATCH 2/4] changelog --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 7b166d322..0d8e180af 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -14,6 +14,7 @@ Yii2 Queue Extension Change Log - Enh #503: All dependent packages for supported drivers have been updated to the latest versions (@s1lver) - Enh #503: The `opis/closure` package did not support PHP 8.1 and was replaced by the `laravel/serializable-closure` package (@s1lver) - Enh #544: Applying Yii2 coding standards (@s1lver) +- Bug #TBD: Fix `@property` annotations in `InfoAction` and `Queue` drivers (mspirkov) 2.3.8 January 08, 2026 ---------------------- From d678fae58da2fa2f1a34a42d336fa90bfafd2276 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=9C=D0=B0=D0=BA=D1=81=D0=B8=D0=BC=20=D0=A1=D0=BF=D0=B8?= =?UTF-8?q?=D1=80=D0=BA=D0=BE=D0=B2?= Date: Sat, 1 Aug 2026 15:04:35 +0400 Subject: [PATCH 3/4] changelog --- CHANGELOG.md | 3 ++- src/cli/InfoAction.php | 1 - 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 0d8e180af..f81187ba8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,7 @@ Yii2 Queue Extension Change Log 3.0.0 under development --- + - Enh #542: The minimum supported PHP version is 8.3 (@s1lver) - Enh #503, #546: Added PHPStan for static code analysis. Error level set to 8 (@s1lver) - Enh #503: Added strict typing (@s1lver) @@ -14,7 +15,7 @@ Yii2 Queue Extension Change Log - Enh #503: All dependent packages for supported drivers have been updated to the latest versions (@s1lver) - Enh #503: The `opis/closure` package did not support PHP 8.1 and was replaced by the `laravel/serializable-closure` package (@s1lver) - Enh #544: Applying Yii2 coding standards (@s1lver) -- Bug #TBD: Fix `@property` annotations in `InfoAction` and `Queue` drivers (mspirkov) +- Bug #563: Fix `@property` annotations in `InfoAction` and `Queue` drivers (mspirkov) 2.3.8 January 08, 2026 ---------------------- diff --git a/src/cli/InfoAction.php b/src/cli/InfoAction.php index d078f7b50..d13e99c97 100644 --- a/src/cli/InfoAction.php +++ b/src/cli/InfoAction.php @@ -23,7 +23,6 @@ * Info about queue status. * * @author Kalmer Kaurson - * */ class InfoAction extends Action { From 4eccf8cc98fd744ec745c640409e2a3bc19c7ae3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=9C=D0=B0=D0=BA=D1=81=D0=B8=D0=BC=20=D0=A1=D0=BF=D0=B8?= =?UTF-8?q?=D1=80=D0=BA=D0=BE=D0=B2?= Date: Sat, 1 Aug 2026 15:08:42 +0400 Subject: [PATCH 4/4] update baseline --- phpstan-baseline.neon | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/phpstan-baseline.neon b/phpstan-baseline.neon index c6d9defa7..ae437f2f7 100644 --- a/phpstan-baseline.neon +++ b/phpstan-baseline.neon @@ -1337,3 +1337,9 @@ parameters: identifier: missingType.iterableValue count: 1 path: tests/serializers/TestCase.php + + - + message: '#^Access to constant ATTR_INIT_COMMAND on an unknown class Pdo\\Mysql\.$#' + identifier: class.notFound + count: 1 + path: tests/app/config/main.php