From 2d9a7e2af92536768577fc13b6683e45e4353e0d Mon Sep 17 00:00:00 2001 From: Tomas Votruba Date: Wed, 7 Jan 2026 13:45:50 +0100 Subject: [PATCH 1/2] remove duplciated ci job --- .github/workflows/code_analysis.yaml | 4 ---- composer.json | 3 ++- src/PHPStan/IgnoreAllErrorsExceptArgTyperErrorExtension.php | 2 +- 3 files changed, 3 insertions(+), 6 deletions(-) diff --git a/.github/workflows/code_analysis.yaml b/.github/workflows/code_analysis.yaml index f7fca2a2..4ca71ea6 100644 --- a/.github/workflows/code_analysis.yaml +++ b/.github/workflows/code_analysis.yaml @@ -28,10 +28,6 @@ jobs: name: 'Coding Standard' run: composer fix-cs --ansi - - - name: 'Class Leak' - run: vendor/bin/class-leak check src tests --skip-path=Fixture --skip-path=Source --skip-type="Rector\\ArgTyper\\PHPStan\\IgnoreAllErrorsExceptArgTyperErrorExtension" - - name: 'Tests' run: vendor/bin/phpunit diff --git a/composer.json b/composer.json index 60dba8d2..95df6bbc 100644 --- a/composer.json +++ b/composer.json @@ -21,11 +21,12 @@ "phpecs/phpecs": "^2.2", "phpstan/extension-installer": "^1.4", "phpunit/phpunit": "^11.5", + "rector/jack": "^0.5.1", "shipmonk/composer-dependency-analyser": "^1.8", "symplify/phpstan-extensions": "^12.0", "tomasvotruba/class-leak": "^2.1", "tomasvotruba/unused-public": "^2.1", - "tracy/tracy": "^2.10" + "tracy/tracy": "^2.11" }, "autoload": { "psr-4": { diff --git a/src/PHPStan/IgnoreAllErrorsExceptArgTyperErrorExtension.php b/src/PHPStan/IgnoreAllErrorsExceptArgTyperErrorExtension.php index 2b09b5de..dc12a032 100644 --- a/src/PHPStan/IgnoreAllErrorsExceptArgTyperErrorExtension.php +++ b/src/PHPStan/IgnoreAllErrorsExceptArgTyperErrorExtension.php @@ -13,7 +13,7 @@ final class IgnoreAllErrorsExceptArgTyperErrorExtension implements IgnoreErrorEx { public function shouldIgnore(Error $error, Node $node, Scope $scope): bool { - // Ignore all errors since ArgTyper only collects types and doesn't throw errors + // Ignore all errors since ArgTyper only collects types and doesn't throw errors return true; } } From 95d0c451a1180a68892fb814377a3df2ec63a585 Mon Sep 17 00:00:00 2001 From: Tomas Votruba Date: Wed, 7 Jan 2026 13:47:56 +0100 Subject: [PATCH 2/2] raise to PHP 8.3 --- .github/workflows/code_analysis.yaml | 2 +- .github/workflows/downgraded_release.yaml | 2 +- composer.json | 16 ++++++++-------- src/Helpers/ProjectDirectoryFinder.php | 2 +- .../CollectCallLikeArgTypesRuleTest.php | 1 + .../CollectFuncCallArgTypesRuleTest.php | 1 + 6 files changed, 13 insertions(+), 11 deletions(-) diff --git a/.github/workflows/code_analysis.yaml b/.github/workflows/code_analysis.yaml index 4ca71ea6..c4f9ee8c 100644 --- a/.github/workflows/code_analysis.yaml +++ b/.github/workflows/code_analysis.yaml @@ -52,7 +52,7 @@ jobs: # see https://github.com/shivammathur/setup-php - uses: shivammathur/setup-php@v2 with: - php-version: 8.2 + php-version: 8.3 coverage: none # composer install cache - https://github.com/ramsey/composer-install diff --git a/.github/workflows/downgraded_release.yaml b/.github/workflows/downgraded_release.yaml index c3900662..3176712b 100644 --- a/.github/workflows/downgraded_release.yaml +++ b/.github/workflows/downgraded_release.yaml @@ -17,7 +17,7 @@ jobs: - uses: "shivammathur/setup-php@v2" with: - php-version: 8.2 + php-version: 8.3 coverage: none # invoke patches diff --git a/composer.json b/composer.json index 95df6bbc..46127fb4 100644 --- a/composer.json +++ b/composer.json @@ -6,19 +6,19 @@ "bin/argtyper" ], "require": { - "php": "^8.2", - "illuminate/container": "^12.39", - "nette/utils": "^4.0", + "php": "^8.3", + "illuminate/container": "12.39.*", + "nette/utils": "^4.1", "phpstan/phpstan": "^2.1", - "rector/rector": "^2.2", + "rector/rector": "^2.3", "symfony/console": "^6.4", - "symfony/finder": "^7.3", - "symfony/process": "^7.3", - "webmozart/assert": "^1.12" + "symfony/finder": "^7.4", + "symfony/process": "^7.4", + "webmozart/assert": "^1.12|^2.0" }, "require-dev": { "php-parallel-lint/php-parallel-lint": "^1.4", - "phpecs/phpecs": "^2.2", + "phpecs/phpecs": "^2.3", "phpstan/extension-installer": "^1.4", "phpunit/phpunit": "^11.5", "rector/jack": "^0.5.1", diff --git a/src/Helpers/ProjectDirectoryFinder.php b/src/Helpers/ProjectDirectoryFinder.php index 7e944f91..5171737e 100644 --- a/src/Helpers/ProjectDirectoryFinder.php +++ b/src/Helpers/ProjectDirectoryFinder.php @@ -14,7 +14,7 @@ final class ProjectDirectoryFinder * Directory names commonly used as PHP source directories * @var string[] */ - private const POSSIBLE_CODE_DIRECTORIES = ['src', 'lib', 'app', 'test', 'tests']; + private const array POSSIBLE_CODE_DIRECTORIES = ['src', 'lib', 'app', 'test', 'tests']; /** * @return string[] diff --git a/tests/PHPStan/CollectCallLikeArgTypesRule/CollectCallLikeArgTypesRuleTest.php b/tests/PHPStan/CollectCallLikeArgTypesRule/CollectCallLikeArgTypesRuleTest.php index 9d8f110f..e134b47c 100644 --- a/tests/PHPStan/CollectCallLikeArgTypesRule/CollectCallLikeArgTypesRuleTest.php +++ b/tests/PHPStan/CollectCallLikeArgTypesRule/CollectCallLikeArgTypesRuleTest.php @@ -104,6 +104,7 @@ public function testFloatAsInt(): void /** * @return string[] */ + #[\Override] public static function getAdditionalConfigFiles(): array { return [__DIR__ . '/../../../config/phpstan-collecting-data.neon']; diff --git a/tests/PHPStan/CollectFuncCallArgTypesRule/CollectFuncCallArgTypesRuleTest.php b/tests/PHPStan/CollectFuncCallArgTypesRule/CollectFuncCallArgTypesRuleTest.php index ffbe9df1..32f4f39f 100644 --- a/tests/PHPStan/CollectFuncCallArgTypesRule/CollectFuncCallArgTypesRuleTest.php +++ b/tests/PHPStan/CollectFuncCallArgTypesRule/CollectFuncCallArgTypesRuleTest.php @@ -38,6 +38,7 @@ public function test(): void /** * @return string[] */ + #[\Override] public static function getAdditionalConfigFiles(): array { return [__DIR__ . '/../../../config/phpstan-collecting-data.neon'];