diff --git a/composer.json b/composer.json index 1a51e9a6..0dafd6e8 100644 --- a/composer.json +++ b/composer.json @@ -22,7 +22,7 @@ "ext-filter": "*", "ext-json": "*", "ext-pcntl": "*", - "symfony/console": "6.0.0", + "symfony/console": "6.0.1", "php-di/php-di": "6.3.5", "amphp/parallel": "1.4.1", "amphp/amp": "2.6.1", @@ -33,12 +33,12 @@ }, "require-dev": { "ext-posix": "*", - "phpunit/phpunit": "9.5.10", - "vimeo/psalm": "4.14.0", - "squizlabs/php_codesniffer": "3.6.1", + "phpunit/phpunit": "9.5.11", + "vimeo/psalm": "4.15.0", + "squizlabs/php_codesniffer": "3.6.2", "mockery/mockery": "1.4.4", "psalm/plugin-mockery": "0.9.1", - "jetbrains/phpstorm-stubs": "2021.2", + "jetbrains/phpstorm-stubs": "2021.3", "php-coveralls/php-coveralls": "2.5.2" }, "autoload": { diff --git a/composer.lock b/composer.lock index 702a08d5..a913431b 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "151fae859915fba8b25170d1a4686556", + "content-hash": "8a6fbb6459d371d37ba248006582f38d", "packages": [ { "name": "amphp/amp", @@ -303,16 +303,16 @@ }, { "name": "amphp/process", - "version": "v1.1.2", + "version": "v1.1.3", "source": { "type": "git", "url": "https://github.com/amphp/process.git", - "reference": "3d36327bf9b4c158cf3010f8f65c00854ec3a8b7" + "reference": "f09e3ed3b0a953ccbfff1140f12be4a884f0aa83" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/amphp/process/zipball/3d36327bf9b4c158cf3010f8f65c00854ec3a8b7", - "reference": "3d36327bf9b4c158cf3010f8f65c00854ec3a8b7", + "url": "https://api.github.com/repos/amphp/process/zipball/f09e3ed3b0a953ccbfff1140f12be4a884f0aa83", + "reference": "f09e3ed3b0a953ccbfff1140f12be4a884f0aa83", "shasum": "" }, "require": { @@ -356,7 +356,7 @@ "homepage": "https://github.com/amphp/process", "support": { "issues": "https://github.com/amphp/process/issues", - "source": "https://github.com/amphp/process/tree/v1.1.2" + "source": "https://github.com/amphp/process/tree/v1.1.3" }, "funding": [ { @@ -364,7 +364,7 @@ "type": "github" } ], - "time": "2021-10-08T15:55:53+00:00" + "time": "2021-12-17T19:09:33+00:00" }, { "name": "amphp/serialization", @@ -780,16 +780,16 @@ }, { "name": "php-di/invoker", - "version": "2.3.2", + "version": "2.3.3", "source": { "type": "git", "url": "https://github.com/PHP-DI/Invoker.git", - "reference": "5214cbe5aad066022cd845dbf313f0e47aed928f" + "reference": "cd6d9f267d1a3474bdddf1be1da079f01b942786" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/PHP-DI/Invoker/zipball/5214cbe5aad066022cd845dbf313f0e47aed928f", - "reference": "5214cbe5aad066022cd845dbf313f0e47aed928f", + "url": "https://api.github.com/repos/PHP-DI/Invoker/zipball/cd6d9f267d1a3474bdddf1be1da079f01b942786", + "reference": "cd6d9f267d1a3474bdddf1be1da079f01b942786", "shasum": "" }, "require": { @@ -823,7 +823,7 @@ ], "support": { "issues": "https://github.com/PHP-DI/Invoker/issues", - "source": "https://github.com/PHP-DI/Invoker/tree/2.3.2" + "source": "https://github.com/PHP-DI/Invoker/tree/2.3.3" }, "funding": [ { @@ -831,7 +831,7 @@ "type": "github" } ], - "time": "2021-07-30T15:05:32+00:00" + "time": "2021-12-13T09:22:56+00:00" }, { "name": "php-di/php-di", @@ -1098,16 +1098,16 @@ }, { "name": "symfony/console", - "version": "v6.0.0", + "version": "v6.0.1", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "675a4e6b05029a02ac43d3daf5aa73f039e876ea" + "reference": "fafd9802d386bf1c267e0249ddb7ceb14dcfdad4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/675a4e6b05029a02ac43d3daf5aa73f039e876ea", - "reference": "675a4e6b05029a02ac43d3daf5aa73f039e876ea", + "url": "https://api.github.com/repos/symfony/console/zipball/fafd9802d386bf1c267e0249ddb7ceb14dcfdad4", + "reference": "fafd9802d386bf1c267e0249ddb7ceb14dcfdad4", "shasum": "" }, "require": { @@ -1173,7 +1173,7 @@ "terminal" ], "support": { - "source": "https://github.com/symfony/console/tree/v6.0.0" + "source": "https://github.com/symfony/console/tree/v6.0.1" }, "funding": [ { @@ -1189,7 +1189,7 @@ "type": "tidelift" } ], - "time": "2021-11-29T15:32:57+00:00" + "time": "2021-12-09T12:47:37+00:00" }, { "name": "symfony/deprecation-contracts", @@ -1667,16 +1667,16 @@ }, { "name": "symfony/string", - "version": "v6.0.0", + "version": "v6.0.1", "source": { "type": "git", "url": "https://github.com/symfony/string.git", - "reference": "ba727797426af0f587f4800566300bdc0cda0777" + "reference": "0cfed595758ec6e0a25591bdc8ca733c1896af32" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/string/zipball/ba727797426af0f587f4800566300bdc0cda0777", - "reference": "ba727797426af0f587f4800566300bdc0cda0777", + "url": "https://api.github.com/repos/symfony/string/zipball/0cfed595758ec6e0a25591bdc8ca733c1896af32", + "reference": "0cfed595758ec6e0a25591bdc8ca733c1896af32", "shasum": "" }, "require": { @@ -1732,7 +1732,7 @@ "utf8" ], "support": { - "source": "https://github.com/symfony/string/tree/v6.0.0" + "source": "https://github.com/symfony/string/tree/v6.0.1" }, "funding": [ { @@ -1748,7 +1748,7 @@ "type": "tidelift" } ], - "time": "2021-10-29T07:35:21+00:00" + "time": "2021-12-08T15:13:44+00:00" } ], "packages-dev": [ @@ -1825,6 +1825,77 @@ ], "time": "2021-09-13T08:41:34+00:00" }, + { + "name": "composer/pcre", + "version": "1.0.0", + "source": { + "type": "git", + "url": "https://github.com/composer/pcre.git", + "reference": "3d322d715c43a1ac36c7fe215fa59336265500f2" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/composer/pcre/zipball/3d322d715c43a1ac36c7fe215fa59336265500f2", + "reference": "3d322d715c43a1ac36c7fe215fa59336265500f2", + "shasum": "" + }, + "require": { + "php": "^5.3.2 || ^7.0 || ^8.0" + }, + "require-dev": { + "phpstan/phpstan": "^1", + "phpstan/phpstan-strict-rules": "^1.1", + "symfony/phpunit-bridge": "^4.2 || ^5" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "1.x-dev" + } + }, + "autoload": { + "psr-4": { + "Composer\\Pcre\\": "src" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Jordi Boggiano", + "email": "j.boggiano@seld.be", + "homepage": "http://seld.be" + } + ], + "description": "PCRE wrapping library that offers type-safe preg_* replacements.", + "keywords": [ + "PCRE", + "preg", + "regex", + "regular expression" + ], + "support": { + "issues": "https://github.com/composer/pcre/issues", + "source": "https://github.com/composer/pcre/tree/1.0.0" + }, + "funding": [ + { + "url": "https://packagist.com", + "type": "custom" + }, + { + "url": "https://github.com/composer", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/composer/composer", + "type": "tidelift" + } + ], + "time": "2021-12-06T15:17:27+00:00" + }, { "name": "composer/semver", "version": "3.2.6", @@ -1908,25 +1979,27 @@ }, { "name": "composer/xdebug-handler", - "version": "2.0.2", + "version": "2.0.3", "source": { "type": "git", "url": "https://github.com/composer/xdebug-handler.git", - "reference": "84674dd3a7575ba617f5a76d7e9e29a7d3891339" + "reference": "6555461e76962fd0379c444c46fd558a0fcfb65e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/xdebug-handler/zipball/84674dd3a7575ba617f5a76d7e9e29a7d3891339", - "reference": "84674dd3a7575ba617f5a76d7e9e29a7d3891339", + "url": "https://api.github.com/repos/composer/xdebug-handler/zipball/6555461e76962fd0379c444c46fd558a0fcfb65e", + "reference": "6555461e76962fd0379c444c46fd558a0fcfb65e", "shasum": "" }, "require": { + "composer/pcre": "^1", "php": "^5.3.2 || ^7.0 || ^8.0", "psr/log": "^1 || ^2 || ^3" }, "require-dev": { - "phpstan/phpstan": "^0.12.55", - "symfony/phpunit-bridge": "^4.2 || ^5" + "phpstan/phpstan": "^1.0", + "phpstan/phpstan-strict-rules": "^1.1", + "symfony/phpunit-bridge": "^4.2 || ^5.0 || ^6.0" }, "type": "library", "autoload": { @@ -1952,7 +2025,7 @@ "support": { "irc": "irc://irc.freenode.org/composer", "issues": "https://github.com/composer/xdebug-handler/issues", - "source": "https://github.com/composer/xdebug-handler/tree/2.0.2" + "source": "https://github.com/composer/xdebug-handler/tree/2.0.3" }, "funding": [ { @@ -1968,7 +2041,7 @@ "type": "tidelift" } ], - "time": "2021-07-31T17:03:58+00:00" + "time": "2021-12-08T13:07:32+00:00" }, { "name": "dnoegel/php-xdg-base-dir", @@ -2179,16 +2252,16 @@ }, { "name": "guzzlehttp/guzzle", - "version": "7.4.0", + "version": "7.4.1", "source": { "type": "git", "url": "https://github.com/guzzle/guzzle.git", - "reference": "868b3571a039f0ebc11ac8f344f4080babe2cb94" + "reference": "ee0a041b1760e6a53d2a39c8c34115adc2af2c79" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/guzzle/guzzle/zipball/868b3571a039f0ebc11ac8f344f4080babe2cb94", - "reference": "868b3571a039f0ebc11ac8f344f4080babe2cb94", + "url": "https://api.github.com/repos/guzzle/guzzle/zipball/ee0a041b1760e6a53d2a39c8c34115adc2af2c79", + "reference": "ee0a041b1760e6a53d2a39c8c34115adc2af2c79", "shasum": "" }, "require": { @@ -2197,7 +2270,7 @@ "guzzlehttp/psr7": "^1.8.3 || ^2.1", "php": "^7.2.5 || ^8.0", "psr/http-client": "^1.0", - "symfony/deprecation-contracts": "^2.2" + "symfony/deprecation-contracts": "^2.2 || ^3.0" }, "provide": { "psr/http-client-implementation": "1.0" @@ -2283,7 +2356,7 @@ ], "support": { "issues": "https://github.com/guzzle/guzzle/issues", - "source": "https://github.com/guzzle/guzzle/tree/7.4.0" + "source": "https://github.com/guzzle/guzzle/tree/7.4.1" }, "funding": [ { @@ -2299,7 +2372,7 @@ "type": "tidelift" } ], - "time": "2021-10-18T09:52:00+00:00" + "time": "2021-12-06T18:43:05+00:00" }, { "name": "guzzlehttp/promises", @@ -2553,20 +2626,20 @@ }, { "name": "jetbrains/phpstorm-stubs", - "version": "v2021.2", + "version": "v2021.3", "source": { "type": "git", "url": "https://github.com/JetBrains/phpstorm-stubs.git", - "reference": "a09a014a1984d2ac875c6b1220b7f17ca7d0a873" + "reference": "c790a8fa467ff5d3f11b0e7c1f3698abbe37b182" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/JetBrains/phpstorm-stubs/zipball/a09a014a1984d2ac875c6b1220b7f17ca7d0a873", - "reference": "a09a014a1984d2ac875c6b1220b7f17ca7d0a873", + "url": "https://api.github.com/repos/JetBrains/phpstorm-stubs/zipball/c790a8fa467ff5d3f11b0e7c1f3698abbe37b182", + "reference": "c790a8fa467ff5d3f11b0e7c1f3698abbe37b182", "shasum": "" }, "require-dev": { - "friendsofphp/php-cs-fixer": "@stable", + "friendsofphp/php-cs-fixer": "dev-master", "nikic/php-parser": "@stable", "php": "^8.0", "phpdocumentor/reflection-docblock": "@stable", @@ -2595,9 +2668,9 @@ "type" ], "support": { - "source": "https://github.com/JetBrains/phpstorm-stubs/tree/v2021.2" + "source": "https://github.com/JetBrains/phpstorm-stubs/tree/v2021.3" }, - "time": "2021-06-06T20:58:57+00:00" + "time": "2021-10-19T20:06:47+00:00" }, { "name": "mockery/mockery", @@ -2688,9 +2761,6 @@ "require": { "php": "^7.1 || ^8.0" }, - "replace": { - "myclabs/deep-copy": "self.version" - }, "require-dev": { "doctrine/collections": "^1.0", "doctrine/common": "^2.6", @@ -3245,16 +3315,16 @@ }, { "name": "phpspec/prophecy", - "version": "1.14.0", + "version": "v1.15.0", "source": { "type": "git", "url": "https://github.com/phpspec/prophecy.git", - "reference": "d86dfc2e2a3cd366cee475e52c6bb3bbc371aa0e" + "reference": "bbcd7380b0ebf3961ee21409db7b38bc31d69a13" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpspec/prophecy/zipball/d86dfc2e2a3cd366cee475e52c6bb3bbc371aa0e", - "reference": "d86dfc2e2a3cd366cee475e52c6bb3bbc371aa0e", + "url": "https://api.github.com/repos/phpspec/prophecy/zipball/bbcd7380b0ebf3961ee21409db7b38bc31d69a13", + "reference": "bbcd7380b0ebf3961ee21409db7b38bc31d69a13", "shasum": "" }, "require": { @@ -3306,29 +3376,29 @@ ], "support": { "issues": "https://github.com/phpspec/prophecy/issues", - "source": "https://github.com/phpspec/prophecy/tree/1.14.0" + "source": "https://github.com/phpspec/prophecy/tree/v1.15.0" }, - "time": "2021-09-10T09:02:12+00:00" + "time": "2021-12-08T12:19:24+00:00" }, { "name": "phpunit/php-code-coverage", - "version": "9.2.7", + "version": "9.2.10", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "d4c798ed8d51506800b441f7a13ecb0f76f12218" + "reference": "d5850aaf931743067f4bfc1ae4cbd06468400687" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/d4c798ed8d51506800b441f7a13ecb0f76f12218", - "reference": "d4c798ed8d51506800b441f7a13ecb0f76f12218", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/d5850aaf931743067f4bfc1ae4cbd06468400687", + "reference": "d5850aaf931743067f4bfc1ae4cbd06468400687", "shasum": "" }, "require": { "ext-dom": "*", "ext-libxml": "*", "ext-xmlwriter": "*", - "nikic/php-parser": "^4.12.0", + "nikic/php-parser": "^4.13.0", "php": ">=7.3", "phpunit/php-file-iterator": "^3.0.3", "phpunit/php-text-template": "^2.0.2", @@ -3377,7 +3447,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", - "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.7" + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.10" }, "funding": [ { @@ -3385,20 +3455,20 @@ "type": "github" } ], - "time": "2021-09-17T05:39:03+00:00" + "time": "2021-12-05T09:12:13+00:00" }, { "name": "phpunit/php-file-iterator", - "version": "3.0.5", + "version": "3.0.6", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-file-iterator.git", - "reference": "aa4be8575f26070b100fccb67faabb28f21f66f8" + "reference": "cf1c2e7c203ac650e352f4cc675a7021e7d1b3cf" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/aa4be8575f26070b100fccb67faabb28f21f66f8", - "reference": "aa4be8575f26070b100fccb67faabb28f21f66f8", + "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/cf1c2e7c203ac650e352f4cc675a7021e7d1b3cf", + "reference": "cf1c2e7c203ac650e352f4cc675a7021e7d1b3cf", "shasum": "" }, "require": { @@ -3437,7 +3507,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-file-iterator/issues", - "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/3.0.5" + "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/3.0.6" }, "funding": [ { @@ -3445,7 +3515,7 @@ "type": "github" } ], - "time": "2020-09-28T05:57:25+00:00" + "time": "2021-12-02T12:48:52+00:00" }, { "name": "phpunit/php-invoker", @@ -3630,16 +3700,16 @@ }, { "name": "phpunit/phpunit", - "version": "9.5.10", + "version": "9.5.11", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "c814a05837f2edb0d1471d6e3f4ab3501ca3899a" + "reference": "2406855036db1102126125537adb1406f7242fdd" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/c814a05837f2edb0d1471d6e3f4ab3501ca3899a", - "reference": "c814a05837f2edb0d1471d6e3f4ab3501ca3899a", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/2406855036db1102126125537adb1406f7242fdd", + "reference": "2406855036db1102126125537adb1406f7242fdd", "shasum": "" }, "require": { @@ -3717,11 +3787,11 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", - "source": "https://github.com/sebastianbergmann/phpunit/tree/9.5.10" + "source": "https://github.com/sebastianbergmann/phpunit/tree/9.5.11" }, "funding": [ { - "url": "https://phpunit.de/donate.html", + "url": "https://phpunit.de/sponsors.html", "type": "custom" }, { @@ -3729,7 +3799,7 @@ "type": "github" } ], - "time": "2021-09-25T07:38:51+00:00" + "time": "2021-12-25T07:07:57+00:00" }, { "name": "psalm/plugin-mockery", @@ -4418,16 +4488,16 @@ }, { "name": "sebastian/exporter", - "version": "4.0.3", + "version": "4.0.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/exporter.git", - "reference": "d89cc98761b8cb5a1a235a6b703ae50d34080e65" + "reference": "65e8b7db476c5dd267e65eea9cab77584d3cfff9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/d89cc98761b8cb5a1a235a6b703ae50d34080e65", - "reference": "d89cc98761b8cb5a1a235a6b703ae50d34080e65", + "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/65e8b7db476c5dd267e65eea9cab77584d3cfff9", + "reference": "65e8b7db476c5dd267e65eea9cab77584d3cfff9", "shasum": "" }, "require": { @@ -4476,14 +4546,14 @@ } ], "description": "Provides the functionality to export PHP variables for visualization", - "homepage": "http://www.github.com/sebastianbergmann/exporter", + "homepage": "https://www.github.com/sebastianbergmann/exporter", "keywords": [ "export", "exporter" ], "support": { "issues": "https://github.com/sebastianbergmann/exporter/issues", - "source": "https://github.com/sebastianbergmann/exporter/tree/4.0.3" + "source": "https://github.com/sebastianbergmann/exporter/tree/4.0.4" }, "funding": [ { @@ -4491,7 +4561,7 @@ "type": "github" } ], - "time": "2020-09-28T05:24:23+00:00" + "time": "2021-11-11T14:18:36+00:00" }, { "name": "sebastian/global-state", @@ -4955,16 +5025,16 @@ }, { "name": "squizlabs/php_codesniffer", - "version": "3.6.1", + "version": "3.6.2", "source": { "type": "git", "url": "https://github.com/squizlabs/PHP_CodeSniffer.git", - "reference": "f268ca40d54617c6e06757f83f699775c9b3ff2e" + "reference": "5e4e71592f69da17871dba6e80dd51bce74a351a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/f268ca40d54617c6e06757f83f699775c9b3ff2e", - "reference": "f268ca40d54617c6e06757f83f699775c9b3ff2e", + "url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/5e4e71592f69da17871dba6e80dd51bce74a351a", + "reference": "5e4e71592f69da17871dba6e80dd51bce74a351a", "shasum": "" }, "require": { @@ -5007,7 +5077,7 @@ "source": "https://github.com/squizlabs/PHP_CodeSniffer", "wiki": "https://github.com/squizlabs/PHP_CodeSniffer/wiki" }, - "time": "2021-10-11T04:00:11+00:00" + "time": "2021-12-12T21:44:58+00:00" }, { "name": "symfony/config", @@ -5293,16 +5363,16 @@ }, { "name": "symfony/yaml", - "version": "v6.0.0", + "version": "v6.0.1", "source": { "type": "git", "url": "https://github.com/symfony/yaml.git", - "reference": "f3064a2e0b5eabaeaf92db0a5913a77098b3b91e" + "reference": "d34390fe7e8c0fe7e4192c67c27ecf58bc7d3ed7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/yaml/zipball/f3064a2e0b5eabaeaf92db0a5913a77098b3b91e", - "reference": "f3064a2e0b5eabaeaf92db0a5913a77098b3b91e", + "url": "https://api.github.com/repos/symfony/yaml/zipball/d34390fe7e8c0fe7e4192c67c27ecf58bc7d3ed7", + "reference": "d34390fe7e8c0fe7e4192c67c27ecf58bc7d3ed7", "shasum": "" }, "require": { @@ -5347,7 +5417,7 @@ "description": "Loads and dumps YAML files", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/yaml/tree/v6.0.0" + "source": "https://github.com/symfony/yaml/tree/v6.0.1" }, "funding": [ { @@ -5363,7 +5433,7 @@ "type": "tidelift" } ], - "time": "2021-11-28T15:34:37+00:00" + "time": "2021-12-08T15:13:44+00:00" }, { "name": "theseer/tokenizer", @@ -5417,16 +5487,16 @@ }, { "name": "vimeo/psalm", - "version": "v4.14.0", + "version": "v4.15.0", "source": { "type": "git", "url": "https://github.com/vimeo/psalm.git", - "reference": "14dcbc908ab2625cd7a74258ee6c740cbecc6140" + "reference": "a1b5e489e6fcebe40cb804793d964e99fc347820" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/vimeo/psalm/zipball/14dcbc908ab2625cd7a74258ee6c740cbecc6140", - "reference": "14dcbc908ab2625cd7a74258ee6c740cbecc6140", + "url": "https://api.github.com/repos/vimeo/psalm/zipball/a1b5e489e6fcebe40cb804793d964e99fc347820", + "reference": "a1b5e489e6fcebe40cb804793d964e99fc347820", "shasum": "" }, "require": { @@ -5517,9 +5587,9 @@ ], "support": { "issues": "https://github.com/vimeo/psalm/issues", - "source": "https://github.com/vimeo/psalm/tree/v4.14.0" + "source": "https://github.com/vimeo/psalm/tree/v4.15.0" }, - "time": "2021-12-04T17:49:24+00:00" + "time": "2021-12-07T11:25:29+00:00" }, { "name": "webmozart/assert", @@ -5646,5 +5716,5 @@ "platform-dev": { "ext-posix": "*" }, - "plugin-api-version": "2.1.0" + "plugin-api-version": "2.2.0" } diff --git a/src/Lib/Elf/Parser/ElfParserException.php b/src/Lib/Elf/Parser/ElfParserException.php index 0e81b38b..f1e578fd 100644 --- a/src/Lib/Elf/Parser/ElfParserException.php +++ b/src/Lib/Elf/Parser/ElfParserException.php @@ -15,5 +15,4 @@ final class ElfParserException extends \Exception { - } diff --git a/src/Lib/Elf/Process/ProcessSymbolReaderException.php b/src/Lib/Elf/Process/ProcessSymbolReaderException.php index 57621220..c5bb2223 100644 --- a/src/Lib/Elf/Process/ProcessSymbolReaderException.php +++ b/src/Lib/Elf/Process/ProcessSymbolReaderException.php @@ -15,5 +15,4 @@ class ProcessSymbolReaderException extends \Exception { - } diff --git a/src/Lib/FFI/CannotAllocateBufferException.php b/src/Lib/FFI/CannotAllocateBufferException.php new file mode 100644 index 00000000..4aa684c4 --- /dev/null +++ b/src/Lib/FFI/CannotAllocateBufferException.php @@ -0,0 +1,18 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + +declare(strict_types=1); + +namespace PhpProfiler\Lib\FFI; + +final class CannotAllocateBufferException extends \Exception +{ +} diff --git a/src/Lib/FFI/CannotCastCDataException.php b/src/Lib/FFI/CannotCastCDataException.php new file mode 100644 index 00000000..19d9125c --- /dev/null +++ b/src/Lib/FFI/CannotCastCDataException.php @@ -0,0 +1,18 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + +declare(strict_types=1); + +namespace PhpProfiler\Lib\FFI; + +final class CannotCastCDataException extends \Exception +{ +} diff --git a/src/Lib/FFI/CannotGetTypeForCDataException.php b/src/Lib/FFI/CannotGetTypeForCDataException.php new file mode 100644 index 00000000..2bc7b5db --- /dev/null +++ b/src/Lib/FFI/CannotGetTypeForCDataException.php @@ -0,0 +1,28 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + +declare(strict_types=1); + +namespace PhpProfiler\Lib\FFI; + +use Throwable; + +final class CannotGetTypeForCDataException extends \Exception +{ + public function __construct( + string $message = "", + int $code = 0, + ?Throwable $previous = null, + public string $type = '', + ) { + parent::__construct($message, $code, $previous); + } +} diff --git a/src/Lib/FFI/CannotLoadCHeaderException.php b/src/Lib/FFI/CannotLoadCHeaderException.php new file mode 100644 index 00000000..d772e014 --- /dev/null +++ b/src/Lib/FFI/CannotLoadCHeaderException.php @@ -0,0 +1,18 @@ + + * + * For the full copyright and license information, please view the LICENSE + * file that was distributed with this source code. + */ + +declare(strict_types=1); + +namespace PhpProfiler\Lib\FFI; + +final class CannotLoadCHeaderException extends \Exception +{ +} diff --git a/src/Lib/File/NativeFileReader.php b/src/Lib/File/NativeFileReader.php index d2885aff..aa91a20e 100644 --- a/src/Lib/File/NativeFileReader.php +++ b/src/Lib/File/NativeFileReader.php @@ -14,6 +14,7 @@ namespace PhpProfiler\Lib\File; use FFI; +use PhpProfiler\Lib\FFI\CannotAllocateBufferException; class NativeFileReader implements FileReaderInterface { @@ -32,7 +33,8 @@ public function __construct() public function readAll(string $path): string { - $buffer = $this->ffi->new("unsigned char[4096]"); + $buffer = $this->ffi->new("unsigned char[4096]") + ?? throw new CannotAllocateBufferException('cannot allocate buffer'); $fd = $this->ffi->open($path, 0); $result = ""; diff --git a/src/Lib/Libc/Sys/Ptrace/PtraceX64.php b/src/Lib/Libc/Sys/Ptrace/PtraceX64.php index 4e63847c..fc9b856f 100644 --- a/src/Lib/Libc/Sys/Ptrace/PtraceX64.php +++ b/src/Lib/Libc/Sys/Ptrace/PtraceX64.php @@ -15,6 +15,8 @@ use FFI\CData; use FFI\CInteger; +use PhpProfiler\Lib\FFI\CannotAllocateBufferException; +use PhpProfiler\Lib\FFI\CannotCastCDataException; use PhpProfiler\Lib\Libc\Addressable; class PtraceX64 implements Ptrace @@ -95,15 +97,19 @@ public function ptrace( ): int { if (is_null($addr) or is_int($addr)) { /** @var CInteger */ - $addr_holder = \FFI::new('long'); + $addr_holder = \FFI::new('long') + ?? throw new CannotAllocateBufferException('cannot allocate buffer'); $addr_holder->cdata = (int)$addr; - $addr = \FFI::cast('void *', $addr_holder); + $addr = \FFI::cast('void *', $addr_holder) + ?? throw new CannotCastCDataException('cannot cast buffer'); } if (is_null($data) or is_int($data)) { /** @var CInteger */ - $data_holder = \FFI::new('long'); + $data_holder = \FFI::new('long') + ?? throw new CannotAllocateBufferException('cannot allocate buffer'); $data_holder->cdata = (int)$data; - $data = \FFI::cast('void *', $data_holder); + $data = \FFI::cast('void *', $data_holder) + ?? throw new CannotCastCDataException('cannot cast buffer'); } $addr_pointer = $addr instanceof Addressable ? $addr->toVoidPointer() : $addr; diff --git a/src/Lib/PhpInternals/ZendTypeReader.php b/src/Lib/PhpInternals/ZendTypeReader.php index b4eb30fa..507854df 100644 --- a/src/Lib/PhpInternals/ZendTypeReader.php +++ b/src/Lib/PhpInternals/ZendTypeReader.php @@ -15,6 +15,8 @@ use FFI; use FFI\CData; +use PhpProfiler\Lib\FFI\CannotGetTypeForCDataException; +use PhpProfiler\Lib\FFI\CannotLoadCHeaderException; final class ZendTypeReader { @@ -52,7 +54,8 @@ private function loadHeader(string $php_version): FFI if ($php_version === self::V81) { $php_version = self::V80; } - $this->ffi = FFI::load(__DIR__ . "/Headers/{$php_version}.h"); + $this->ffi = FFI::load(__DIR__ . "/Headers/{$php_version}.h") + ?? throw new CannotLoadCHeaderException('cannot load headers for zend engine'); } return $this->ffi; } @@ -66,7 +69,11 @@ public function readAs(string $type, CData $cdata): ZendTypeCData public function sizeOf(string $type): int { $ffi = $this->loadHeader($this->php_version); - $type = $ffi->type($type); - return FFI::sizeof($type); + $cdata_type = $ffi->type($type) + ?? throw new CannotGetTypeForCDataException( + message: 'cannot get type for a C Data', + type: $type + ); + return FFI::sizeof($cdata_type); } } diff --git a/src/Lib/Process/MemoryReader/MemoryReader.php b/src/Lib/Process/MemoryReader/MemoryReader.php index ba4801b7..e60348b1 100644 --- a/src/Lib/Process/MemoryReader/MemoryReader.php +++ b/src/Lib/Process/MemoryReader/MemoryReader.php @@ -15,6 +15,7 @@ use FFI; use FFI\CData; +use PhpProfiler\Lib\FFI\CannotAllocateBufferException; final class MemoryReader implements MemoryReaderInterface { @@ -39,9 +40,12 @@ public function __construct() unsigned long riovcnt, unsigned long flags); ', 'libc.so.6'); - $this->local_iov = $this->ffi->new('struct iovec'); - $this->remote_iov = $this->ffi->new('struct iovec'); - $this->remote_base = $this->ffi->new('long'); + $this->local_iov = $this->ffi->new('struct iovec') + ?? throw new CannotAllocateBufferException('cannot allocate buffer'); + $this->remote_iov = $this->ffi->new('struct iovec') + ?? throw new CannotAllocateBufferException('cannot allocate buffer'); + $this->remote_base = $this->ffi->new('long') + ?? throw new CannotAllocateBufferException('cannot allocate buffer'); } /** @@ -50,7 +54,8 @@ public function __construct() */ public function read(int $pid, int $remote_address, int $size): CData { - $buffer = $this->ffi->new("unsigned char[{$size}]"); + $buffer = $this->ffi->new("unsigned char[{$size}]") + ?? throw new CannotAllocateBufferException('cannot allocate buffer'); /** * @var FFI\Libc\iovec $this->local_iov diff --git a/tests/Command/CommandEnumeratorTestData/Test1Directory/Test1Command.php b/tests/Command/CommandEnumeratorTestData/Test1Directory/Test1Command.php index 4b1ff864..f85df8c7 100644 --- a/tests/Command/CommandEnumeratorTestData/Test1Directory/Test1Command.php +++ b/tests/Command/CommandEnumeratorTestData/Test1Directory/Test1Command.php @@ -15,5 +15,4 @@ final class Test1Command { - } diff --git a/tests/Command/CommandEnumeratorTestData/Test1Directory/Test2Command.php b/tests/Command/CommandEnumeratorTestData/Test1Directory/Test2Command.php index 71e45fff..cc5076ed 100644 --- a/tests/Command/CommandEnumeratorTestData/Test1Directory/Test2Command.php +++ b/tests/Command/CommandEnumeratorTestData/Test1Directory/Test2Command.php @@ -15,5 +15,4 @@ final class Test2Command { - } diff --git a/tests/Command/CommandEnumeratorTestData/Test2Directory/Test3Command.php b/tests/Command/CommandEnumeratorTestData/Test2Directory/Test3Command.php index 7bc1067a..4611a738 100644 --- a/tests/Command/CommandEnumeratorTestData/Test2Directory/Test3Command.php +++ b/tests/Command/CommandEnumeratorTestData/Test2Directory/Test3Command.php @@ -15,5 +15,4 @@ final class Test3Command { - } diff --git a/tests/Command/CommandEnumeratorTestData/Test2Directory/Test4Command.php b/tests/Command/CommandEnumeratorTestData/Test2Directory/Test4Command.php index b67212dc..2fa2062f 100644 --- a/tests/Command/CommandEnumeratorTestData/Test2Directory/Test4Command.php +++ b/tests/Command/CommandEnumeratorTestData/Test2Directory/Test4Command.php @@ -15,5 +15,4 @@ final class Test4Command { - } diff --git a/tests/Inspector/Daemon/Searcher/Context/PhpSearcherContextCreatorTest.php b/tests/Inspector/Daemon/Searcher/Context/PhpSearcherContextCreatorTest.php index 98dde230..31325992 100644 --- a/tests/Inspector/Daemon/Searcher/Context/PhpSearcherContextCreatorTest.php +++ b/tests/Inspector/Daemon/Searcher/Context/PhpSearcherContextCreatorTest.php @@ -24,7 +24,6 @@ class PhpSearcherContextCreatorTest extends TestCase { - public function testCreate() { $context = Mockery::mock(ContextInterface::class); diff --git a/tests/Lib/ByteStream/ByteReaderDisableWriteAccessTraitTest.php b/tests/Lib/ByteStream/ByteReaderDisableWriteAccessTraitTest.php index 21e571c6..2fdd0ef2 100644 --- a/tests/Lib/ByteStream/ByteReaderDisableWriteAccessTraitTest.php +++ b/tests/Lib/ByteStream/ByteReaderDisableWriteAccessTraitTest.php @@ -19,7 +19,6 @@ class ByteReaderDisableWriteAccessTraitTest extends TestCase { - public function testOffsetSet() { $this->expectException(LogicException::class); diff --git a/tests/Lib/Elf/SymbolResolver/Elf64DynamicSymbolResolverTest.php b/tests/Lib/Elf/SymbolResolver/Elf64DynamicSymbolResolverTest.php index e0217c7f..d79a46f0 100644 --- a/tests/Lib/Elf/SymbolResolver/Elf64DynamicSymbolResolverTest.php +++ b/tests/Lib/Elf/SymbolResolver/Elf64DynamicSymbolResolverTest.php @@ -21,7 +21,6 @@ class Elf64DynamicSymbolResolverTest extends TestCase { - public function testLoad() { $php_binary = new StringByteReader(