From e028e0a4e0da92de7d2ef8591a0b3fecd685341a Mon Sep 17 00:00:00 2001 From: eldadfux Date: Sun, 22 Feb 2026 10:38:35 +0100 Subject: [PATCH 1/2] feat: enhance logging error handling with Push exception - Updated `composer.json` to require `utopia-php/console`. - Modified `Logger` class to catch `Push` exceptions during log pushes and log detailed error messages. - Updated `Adapter` implementations (AppSignal, LogOwl, Raygun, Sentry) to throw `Push` exceptions on failure instead of returning error codes. --- composer.json | 86 +++-- composer.lock | 569 +++++++++++++++++++------------ src/Logger/Adapter.php | 2 + src/Logger/Adapter/AppSignal.php | 7 +- src/Logger/Adapter/LogOwl.php | 7 +- src/Logger/Adapter/Raygun.php | 7 +- src/Logger/Adapter/Sentry.php | 7 +- src/Logger/Exception/Push.php | 22 ++ src/Logger/Logger.php | 21 +- 9 files changed, 459 insertions(+), 269 deletions(-) create mode 100644 src/Logger/Exception/Push.php diff --git a/composer.json b/composer.json index 6614a56..907a09f 100644 --- a/composer.json +++ b/composer.json @@ -1,37 +1,53 @@ { - "name": "utopia-php/logger", - "description": "Utopia Logger library is simple and lite library for logging information, such as errors or warnings. This library is aiming to be as simple and easy to learn and use.", - "type": "library", - "keywords": ["php","framework", "upf", "utopia", "logger", "logging", "errors", "warnings", "logs", "sentry", "raygun", "appsignal"], - "license": "MIT", - "scripts": { - "check": "./vendor/bin/phpstan analyse --level max src tests", - "lint": "./vendor/bin/pint --test", - "format": "./vendor/bin/pint", - "test-unit": "./vendor/bin/phpunit --configuration phpunit.xml --testsuite unit --debug", - "test-e2e": "./vendor/bin/phpunit --configuration phpunit.xml --testsuite e2e --debug", - "test": [ - "@test-unit", - "@test-e2e" - ] - }, - "autoload": { - "psr-4": {"Utopia\\Logger\\": "src/Logger"} - }, - "autoload-dev": { - "psr-4": { - "Utopia\\Tests\\E2E\\":"tests/e2e", - "Utopia\\Tests\\Unit\\":"tests/unit" - } - }, - "require": { - "php": ">=8.0" - }, - "require-dev": { - "phpunit/phpunit": "^9.3", - "vimeo/psalm": "4.0.1", - "laravel/pint": "1.2.*", - "phpstan/phpstan": "1.9.x-dev" - }, - "minimum-stability": "dev" +"name": "utopia-php/logger", +"description": "Utopia Logger library is simple and lite library for logging information, such as errors or warnings. This library is aiming to be as simple and easy to learn and use.", +"type": "library", +"keywords": [ +"php", +"framework", +"upf", +"utopia", +"logger", +"logging", +"errors", +"warnings", +"logs", +"sentry", +"raygun", +"appsignal" +], +"license": "MIT", +"scripts": { +"check": "./vendor/bin/phpstan analyse --level max src tests", +"lint": "./vendor/bin/pint --test", +"format": "./vendor/bin/pint", +"test-unit": "./vendor/bin/phpunit --configuration phpunit.xml --testsuite unit --debug", +"test-e2e": "./vendor/bin/phpunit --configuration phpunit.xml --testsuite e2e --debug", +"test": [ +"@test-unit", +"@test-e2e" +] +}, +"autoload": { +"psr-4": { +"Utopia\\Logger\\": "src/Logger" } +}, +"autoload-dev": { +"psr-4": { +"Utopia\\Tests\\E2E\\": "tests/e2e", +"Utopia\\Tests\\Unit\\": "tests/unit" +} +}, +"require": { +"php": ">=8.0", +"utopia-php/console": "^0.1" +}, +"require-dev": { +"phpunit/phpunit": "^9.3", +"vimeo/psalm": "4.0.1", +"laravel/pint": "1.2.*", +"phpstan/phpstan": "1.9.x-dev" +}, +"minimum-stability": "dev" +} \ No newline at end of file diff --git a/composer.lock b/composer.lock index 3ead8a5..ef16463 100644 --- a/composer.lock +++ b/composer.lock @@ -4,8 +4,57 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "88a774bf612e62ac45d7a9e72d2bb3e2", - "packages": [], + "content-hash": "adcf9b30b3d8f11659ec02ad1397b06c", + "packages": [ + { + "name": "utopia-php/console", + "version": "0.1.1", + "source": { + "type": "git", + "url": "https://github.com/utopia-php/console.git", + "reference": "d298e43960780e6d76e66de1228c75dc81220e3e" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/utopia-php/console/zipball/d298e43960780e6d76e66de1228c75dc81220e3e", + "reference": "d298e43960780e6d76e66de1228c75dc81220e3e", + "shasum": "" + }, + "require": { + "php": ">=8.0" + }, + "require-dev": { + "laravel/pint": "1.2.*", + "phpstan/phpstan": "^1.10", + "phpunit/phpunit": "^9.3", + "squizlabs/php_codesniffer": "^3.6", + "swoole/ide-helper": "4.8.8" + }, + "type": "library", + "autoload": { + "psr-4": { + "Utopia\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "Console helpers for logging, prompting, and executing commands", + "keywords": [ + "cli", + "console", + "php", + "terminal", + "utopia" + ], + "support": { + "issues": "https://github.com/utopia-php/console/issues", + "source": "https://github.com/utopia-php/console/tree/0.1.1" + }, + "time": "2026-02-10T10:20:29+00:00" + } + ], "packages-dev": [ { "name": "amphp/amp", @@ -13,12 +62,12 @@ "source": { "type": "git", "url": "https://github.com/amphp/amp.git", - "reference": "ded3d9be08f526089eb7ee8d9f16a9768f9dec2d" + "reference": "d7dda98dae26e56f3f6fcfbf1c1f819c9a993207" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/amphp/amp/zipball/ded3d9be08f526089eb7ee8d9f16a9768f9dec2d", - "reference": "ded3d9be08f526089eb7ee8d9f16a9768f9dec2d", + "url": "https://api.github.com/repos/amphp/amp/zipball/d7dda98dae26e56f3f6fcfbf1c1f819c9a993207", + "reference": "d7dda98dae26e56f3f6fcfbf1c1f819c9a993207", "shasum": "" }, "require": { @@ -34,11 +83,6 @@ "vimeo/psalm": "^3.12" }, "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.x-dev" - } - }, "autoload": { "files": [ "lib/functions.php", @@ -94,7 +138,7 @@ "type": "github" } ], - "time": "2024-03-21T18:52:26+00:00" + "time": "2025-09-03T19:41:28+00:00" }, { "name": "amphp/byte-stream", @@ -233,10 +277,6 @@ { "url": "https://github.com/composer", "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/composer/composer", - "type": "tidelift" } ], "time": "2022-01-17T14:14:24+00:00" @@ -247,12 +287,12 @@ "source": { "type": "git", "url": "https://github.com/composer/semver.git", - "reference": "4313d26ada5e0c4edfbd1dc481a92ff7bff91f12" + "reference": "38ccbbfd0098b205e4d947f18e3f1f321803b067" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/semver/zipball/4313d26ada5e0c4edfbd1dc481a92ff7bff91f12", - "reference": "4313d26ada5e0c4edfbd1dc481a92ff7bff91f12", + "url": "https://api.github.com/repos/composer/semver/zipball/38ccbbfd0098b205e4d947f18e3f1f321803b067", + "reference": "38ccbbfd0098b205e4d947f18e3f1f321803b067", "shasum": "" }, "require": { @@ -295,7 +335,7 @@ "homepage": "http://robbast.nl" } ], - "description": "Semver library that offers utilities, version constraint parsing and validation.", + "description": "Version comparison library that offers utilities, version constraint parsing and validation.", "keywords": [ "semantic", "semver", @@ -305,7 +345,7 @@ "support": { "irc": "ircs://irc.libera.chat:6697/composer", "issues": "https://github.com/composer/semver/issues", - "source": "https://github.com/composer/semver/tree/3.4.3" + "source": "https://github.com/composer/semver/tree/main" }, "funding": [ { @@ -315,13 +355,9 @@ { "url": "https://github.com/composer", "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/composer/composer", - "type": "tidelift" } ], - "time": "2024-09-19T14:15:21+00:00" + "time": "2025-12-03T10:22:06+00:00" }, { "name": "composer/xdebug-handler", @@ -426,38 +462,38 @@ }, { "name": "doctrine/deprecations", - "version": "1.1.x-dev", + "version": "1.2.x-dev", "source": { "type": "git", "url": "https://github.com/doctrine/deprecations.git", - "reference": "dfbaa3c2d2e9a9df1118213f3b8b0c597bb99fab" + "reference": "a2d13f1c09db71b0688cbdbcd17e569ec489c44b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/deprecations/zipball/dfbaa3c2d2e9a9df1118213f3b8b0c597bb99fab", - "reference": "dfbaa3c2d2e9a9df1118213f3b8b0c597bb99fab", + "url": "https://api.github.com/repos/doctrine/deprecations/zipball/a2d13f1c09db71b0688cbdbcd17e569ec489c44b", + "reference": "a2d13f1c09db71b0688cbdbcd17e569ec489c44b", "shasum": "" }, "require": { "php": "^7.1 || ^8.0" }, + "conflict": { + "phpunit/phpunit": "<=7.5 || >=14" + }, "require-dev": { - "doctrine/coding-standard": "^9", - "phpstan/phpstan": "1.4.10 || 1.10.15", - "phpstan/phpstan-phpunit": "^1.0", - "phpunit/phpunit": "^7.5 || ^8.5 || ^9.5", - "psalm/plugin-phpunit": "0.18.4", - "psr/log": "^1 || ^2 || ^3", - "vimeo/psalm": "4.30.0 || 5.12.0" + "doctrine/coding-standard": "^9 || ^12 || ^14", + "phpstan/phpstan": "1.4.10 || 2.1.30", + "phpstan/phpstan-phpunit": "^1.0 || ^2", + "phpunit/phpunit": "^7.5 || ^8.5 || ^9.6 || ^10.5 || ^11.5 || ^12.4 || ^13.0", + "psr/log": "^1 || ^2 || ^3" }, "suggest": { "psr/log": "Allows logging deprecations via PSR-3 logger implementation" }, - "default-branch": true, "type": "library", "autoload": { "psr-4": { - "Doctrine\\Deprecations\\": "lib/Doctrine/Deprecations" + "Doctrine\\Deprecations\\": "src" } }, "notification-url": "https://packagist.org/downloads/", @@ -468,38 +504,36 @@ "homepage": "https://www.doctrine-project.org/", "support": { "issues": "https://github.com/doctrine/deprecations/issues", - "source": "https://github.com/doctrine/deprecations/tree/1.1.3" + "source": "https://github.com/doctrine/deprecations/tree/1.2.x" }, - "time": "2024-01-30T19:34:25+00:00" + "time": "2026-02-07T07:33:44+00:00" }, { "name": "doctrine/instantiator", - "version": "2.0.x-dev", + "version": "2.2.x-dev", "source": { "type": "git", "url": "https://github.com/doctrine/instantiator.git", - "reference": "acc12399c90611e3cb478d0ec72f2c2ebbc429d1" + "reference": "78f5d718c7f52afc31e59434f625b34c52875d72" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/instantiator/zipball/acc12399c90611e3cb478d0ec72f2c2ebbc429d1", - "reference": "acc12399c90611e3cb478d0ec72f2c2ebbc429d1", + "url": "https://api.github.com/repos/doctrine/instantiator/zipball/78f5d718c7f52afc31e59434f625b34c52875d72", + "reference": "78f5d718c7f52afc31e59434f625b34c52875d72", "shasum": "" }, "require": { - "php": "^8.1" + "php": "^8.4" }, "require-dev": { - "doctrine/coding-standard": "^12", + "doctrine/coding-standard": "^14", "ext-pdo": "*", "ext-phar": "*", "phpbench/phpbench": "^1.2", - "phpstan/phpstan": "^1.9.4", - "phpstan/phpstan-phpunit": "^1.3", - "phpunit/phpunit": "^10.5", - "vimeo/psalm": "^5.4" + "phpstan/phpstan": "^2.1", + "phpstan/phpstan-phpunit": "^2.0", + "phpunit/phpunit": "^10.5.58" }, - "default-branch": true, "type": "library", "autoload": { "psr-4": { @@ -525,7 +559,7 @@ ], "support": { "issues": "https://github.com/doctrine/instantiator/issues", - "source": "https://github.com/doctrine/instantiator/tree/2.0.x" + "source": "https://github.com/doctrine/instantiator/tree/2.2.x" }, "funding": [ { @@ -541,7 +575,7 @@ "type": "tidelift" } ], - "time": "2024-09-30T20:32:32+00:00" + "time": "2026-01-14T07:50:32+00:00" }, { "name": "felixfbecker/advanced-json-rpc", @@ -717,12 +751,12 @@ "source": { "type": "git", "url": "https://github.com/myclabs/DeepCopy.git", - "reference": "3a6b9a42cd8f8771bd4295d13e1423fa7f3d942c" + "reference": "5ee4e978b7fec6dbd844282126a5a32daa2044c6" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/3a6b9a42cd8f8771bd4295d13e1423fa7f3d942c", - "reference": "3a6b9a42cd8f8771bd4295d13e1423fa7f3d942c", + "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/5ee4e978b7fec6dbd844282126a5a32daa2044c6", + "reference": "5ee4e978b7fec6dbd844282126a5a32daa2044c6", "shasum": "" }, "require": { @@ -762,7 +796,7 @@ ], "support": { "issues": "https://github.com/myclabs/DeepCopy/issues", - "source": "https://github.com/myclabs/DeepCopy/tree/1.12.0" + "source": "https://github.com/myclabs/DeepCopy/tree/1.x" }, "funding": [ { @@ -770,7 +804,7 @@ "type": "tidelift" } ], - "time": "2024-06-12T14:39:25+00:00" + "time": "2025-12-30T16:10:21+00:00" }, { "name": "netresearch/jsonmapper", @@ -829,12 +863,12 @@ "source": { "type": "git", "url": "https://github.com/nikic/PHP-Parser.git", - "reference": "715f4d25e225bc47b293a8b997fe6ce99bf987d2" + "reference": "51bd93cc741b7fc3d63d20b6bdcd99fdaa359837" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/715f4d25e225bc47b293a8b997fe6ce99bf987d2", - "reference": "715f4d25e225bc47b293a8b997fe6ce99bf987d2", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/51bd93cc741b7fc3d63d20b6bdcd99fdaa359837", + "reference": "51bd93cc741b7fc3d63d20b6bdcd99fdaa359837", "shasum": "" }, "require": { @@ -849,11 +883,6 @@ "bin/php-parse" ], "type": "library", - "extra": { - "branch-alias": { - "dev-master": "4.9-dev" - } - }, "autoload": { "psr-4": { "PhpParser\\": "lib/PhpParser" @@ -877,7 +906,7 @@ "issues": "https://github.com/nikic/PHP-Parser/issues", "source": "https://github.com/nikic/PHP-Parser/tree/4.x" }, - "time": "2024-09-29T15:01:53+00:00" + "time": "2025-12-06T11:45:25+00:00" }, { "name": "openlss/lib-array2xml", @@ -938,12 +967,12 @@ "source": { "type": "git", "url": "https://github.com/phar-io/manifest.git", - "reference": "54750ef60c58e43759730615a392c31c80e23176" + "reference": "c581d4941e196459bf76c945a8ca922963a66708" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phar-io/manifest/zipball/54750ef60c58e43759730615a392c31c80e23176", - "reference": "54750ef60c58e43759730615a392c31c80e23176", + "url": "https://api.github.com/repos/phar-io/manifest/zipball/c581d4941e196459bf76c945a8ca922963a66708", + "reference": "c581d4941e196459bf76c945a8ca922963a66708", "shasum": "" }, "require": { @@ -990,7 +1019,7 @@ "description": "Component for reading phar.io manifest information from a PHP Archive (PHAR)", "support": { "issues": "https://github.com/phar-io/manifest/issues", - "source": "https://github.com/phar-io/manifest/tree/2.0.4" + "source": "https://github.com/phar-io/manifest/tree/master" }, "funding": [ { @@ -998,7 +1027,7 @@ "type": "github" } ], - "time": "2024-03-03T12:33:53+00:00" + "time": "2025-11-27T15:23:09+00:00" }, { "name": "phar-io/version", @@ -1110,12 +1139,12 @@ "source": { "type": "git", "url": "https://github.com/phpDocumentor/ReflectionDocBlock.git", - "reference": "60741fe3871f40e44ca10a28ce85d08b7ed841cd" + "reference": "5cee1d3dfc2d2aa6599834520911d246f656bcb8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/60741fe3871f40e44ca10a28ce85d08b7ed841cd", - "reference": "60741fe3871f40e44ca10a28ce85d08b7ed841cd", + "url": "https://api.github.com/repos/phpDocumentor/ReflectionDocBlock/zipball/5cee1d3dfc2d2aa6599834520911d246f656bcb8", + "reference": "5cee1d3dfc2d2aa6599834520911d246f656bcb8", "shasum": "" }, "require": { @@ -1124,19 +1153,18 @@ "php": "^7.4 || ^8.0", "phpdocumentor/reflection-common": "^2.2", "phpdocumentor/type-resolver": "^1.7", - "phpstan/phpdoc-parser": "^1.7", - "webmozart/assert": "^1.9.1" + "phpstan/phpdoc-parser": "^1.7|^2.0", + "webmozart/assert": "^1.9.1 || ^2" }, "require-dev": { - "mockery/mockery": "~1.3.5", + "mockery/mockery": "~1.3.5 || ~1.6.0", "phpstan/extension-installer": "^1.1", "phpstan/phpstan": "^1.8", "phpstan/phpstan-mockery": "^1.1", "phpstan/phpstan-webmozart-assert": "^1.2", "phpunit/phpunit": "^9.5", - "vimeo/psalm": "^5.13" + "psalm/phar": "^5.26" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -1165,9 +1193,9 @@ "description": "With this component, a library can provide support for annotations via DocBlocks or otherwise retrieve information that is embedded in a DocBlock.", "support": { "issues": "https://github.com/phpDocumentor/ReflectionDocBlock/issues", - "source": "https://github.com/phpDocumentor/ReflectionDocBlock/tree/5.x" + "source": "https://github.com/phpDocumentor/ReflectionDocBlock/tree/5.6.6" }, - "time": "2024-08-14T20:00:37+00:00" + "time": "2025-12-22T21:13:58+00:00" }, { "name": "phpdocumentor/type-resolver", @@ -1175,19 +1203,19 @@ "source": { "type": "git", "url": "https://github.com/phpDocumentor/TypeResolver.git", - "reference": "eee054a3d40f09920f5b27c9b09a6483f88d9d24" + "reference": "fb05a34cd192e7987c18c06ef47dce6c2e2ec39f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/eee054a3d40f09920f5b27c9b09a6483f88d9d24", - "reference": "eee054a3d40f09920f5b27c9b09a6483f88d9d24", + "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/fb05a34cd192e7987c18c06ef47dce6c2e2ec39f", + "reference": "fb05a34cd192e7987c18c06ef47dce6c2e2ec39f", "shasum": "" }, "require": { "doctrine/deprecations": "^1.0", "php": "^7.3 || ^8.0", "phpdocumentor/reflection-common": "^2.0", - "phpstan/phpdoc-parser": "^1.18" + "phpstan/phpdoc-parser": "^1.18|^2.0" }, "require-dev": { "ext-tokenizer": "*", @@ -1199,7 +1227,6 @@ "rector/rector": "^0.13.9", "vimeo/psalm": "^4.25" }, - "default-branch": true, "type": "library", "extra": { "branch-alias": { @@ -1226,36 +1253,37 @@ "issues": "https://github.com/phpDocumentor/TypeResolver/issues", "source": "https://github.com/phpDocumentor/TypeResolver/tree/1.x" }, - "time": "2024-05-24T14:24:30+00:00" + "time": "2025-11-28T09:29:02+00:00" }, { "name": "phpstan/phpdoc-parser", - "version": "1.32.0", + "version": "2.3.x-dev", "source": { "type": "git", "url": "https://github.com/phpstan/phpdoc-parser.git", - "reference": "6ca22b154efdd9e3c68c56f5d94670920a1c19a4" + "reference": "53945a7da9a8b2807e645fa6d1647c247bac20e4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpstan/phpdoc-parser/zipball/6ca22b154efdd9e3c68c56f5d94670920a1c19a4", - "reference": "6ca22b154efdd9e3c68c56f5d94670920a1c19a4", + "url": "https://api.github.com/repos/phpstan/phpdoc-parser/zipball/53945a7da9a8b2807e645fa6d1647c247bac20e4", + "reference": "53945a7da9a8b2807e645fa6d1647c247bac20e4", "shasum": "" }, "require": { - "php": "^7.2 || ^8.0" + "php": "^7.4 || ^8.0" }, "require-dev": { "doctrine/annotations": "^2.0", - "nikic/php-parser": "^4.15", + "nikic/php-parser": "^5.3.0", "php-parallel-lint/php-parallel-lint": "^1.2", "phpstan/extension-installer": "^1.0", - "phpstan/phpstan": "^1.5", - "phpstan/phpstan-phpunit": "^1.1", - "phpstan/phpstan-strict-rules": "^1.0", - "phpunit/phpunit": "^9.5", + "phpstan/phpstan": "^2.0", + "phpstan/phpstan-phpunit": "^2.0", + "phpstan/phpstan-strict-rules": "^2.0", + "phpunit/phpunit": "^9.6", "symfony/process": "^5.2" }, + "default-branch": true, "type": "library", "autoload": { "psr-4": { @@ -1271,9 +1299,9 @@ "description": "PHPDoc parser with support for nullable, intersection and generic types", "support": { "issues": "https://github.com/phpstan/phpdoc-parser/issues", - "source": "https://github.com/phpstan/phpdoc-parser/tree/1.32.0" + "source": "https://github.com/phpstan/phpdoc-parser/tree/2.3.x" }, - "time": "2024-09-26T07:23:32+00:00" + "time": "2026-02-19T09:22:24+00:00" }, { "name": "phpstan/phpstan", @@ -1340,12 +1368,12 @@ "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "85402a822d1ecf1db1096959413d35e1c37cf1a5" + "reference": "653bca7ea05439961818f429a2a49ec8a8c7d2fb" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/85402a822d1ecf1db1096959413d35e1c37cf1a5", - "reference": "85402a822d1ecf1db1096959413d35e1c37cf1a5", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/653bca7ea05439961818f429a2a49ec8a8c7d2fb", + "reference": "653bca7ea05439961818f429a2a49ec8a8c7d2fb", "shasum": "" }, "require": { @@ -1402,15 +1430,27 @@ "support": { "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", "security": "https://github.com/sebastianbergmann/php-code-coverage/security/policy", - "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.32" + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2" }, "funding": [ { "url": "https://github.com/sebastianbergmann", "type": "github" + }, + { + "url": "https://liberapay.com/sebastianbergmann", + "type": "liberapay" + }, + { + "url": "https://thanks.dev/u/gh/sebastianbergmann", + "type": "thanks_dev" + }, + { + "url": "https://tidelift.com/funding/github/packagist/phpunit/php-code-coverage", + "type": "tidelift" } ], - "time": "2024-08-22T04:23:01+00:00" + "time": "2025-11-26T14:28:02+00:00" }, { "name": "phpunit/php-file-iterator", @@ -1659,12 +1699,12 @@ "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "857d98630470c48a353f673060dec98e8c0686b2" + "reference": "0b4e91d9534b05365591e59bbb369a301bd13524" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/857d98630470c48a353f673060dec98e8c0686b2", - "reference": "857d98630470c48a353f673060dec98e8c0686b2", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/0b4e91d9534b05365591e59bbb369a301bd13524", + "reference": "0b4e91d9534b05365591e59bbb369a301bd13524", "shasum": "" }, "require": { @@ -1675,7 +1715,7 @@ "ext-mbstring": "*", "ext-xml": "*", "ext-xmlwriter": "*", - "myclabs/deep-copy": "^1.12.0", + "myclabs/deep-copy": "^1.13.4", "phar-io/manifest": "^2.0.4", "phar-io/version": "^3.2.1", "php": ">=7.3", @@ -1686,11 +1726,11 @@ "phpunit/php-timer": "^5.0.3", "sebastian/cli-parser": "^1.0.2", "sebastian/code-unit": "^1.0.8", - "sebastian/comparator": "^4.0.8", + "sebastian/comparator": "^4.0.10", "sebastian/diff": "^4.0.6", "sebastian/environment": "^5.1.5", - "sebastian/exporter": "^4.0.6", - "sebastian/global-state": "^5.0.7", + "sebastian/exporter": "^4.0.8", + "sebastian/global-state": "^5.0.8", "sebastian/object-enumerator": "^4.0.4", "sebastian/resource-operations": "^3.0.4", "sebastian/type": "^3.2.1", @@ -1749,12 +1789,20 @@ "url": "https://github.com/sebastianbergmann", "type": "github" }, + { + "url": "https://liberapay.com/sebastianbergmann", + "type": "liberapay" + }, + { + "url": "https://thanks.dev/u/gh/sebastianbergmann", + "type": "thanks_dev" + }, { "url": "https://tidelift.com/funding/github/packagist/phpunit/phpunit", "type": "tidelift" } ], - "time": "2024-10-08T05:58:25+00:00" + "time": "2026-02-19T12:07:17+00:00" }, { "name": "psr/container", @@ -2033,12 +2081,12 @@ "source": { "type": "git", "url": "https://github.com/sebastianbergmann/comparator.git", - "reference": "b247957a1c8dc81a671770f74b479c0a78a818f1" + "reference": "e4df00b9b3571187db2831ae9aada2c6efbd715d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/b247957a1c8dc81a671770f74b479c0a78a818f1", - "reference": "b247957a1c8dc81a671770f74b479c0a78a818f1", + "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/e4df00b9b3571187db2831ae9aada2c6efbd715d", + "reference": "e4df00b9b3571187db2831ae9aada2c6efbd715d", "shasum": "" }, "require": { @@ -2091,15 +2139,27 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/comparator/issues", - "source": "https://github.com/sebastianbergmann/comparator/tree/4.0" + "source": "https://github.com/sebastianbergmann/comparator/tree/4.0.10" }, "funding": [ { "url": "https://github.com/sebastianbergmann", "type": "github" + }, + { + "url": "https://liberapay.com/sebastianbergmann", + "type": "liberapay" + }, + { + "url": "https://thanks.dev/u/gh/sebastianbergmann", + "type": "thanks_dev" + }, + { + "url": "https://tidelift.com/funding/github/packagist/sebastian/comparator", + "type": "tidelift" } ], - "time": "2022-09-14T12:46:14+00:00" + "time": "2026-01-24T09:22:56+00:00" }, { "name": "sebastian/complexity", @@ -2293,12 +2353,12 @@ "source": { "type": "git", "url": "https://github.com/sebastianbergmann/exporter.git", - "reference": "78c00df8f170e02473b682df15bfcdacc3d32d72" + "reference": "14c6ba52f95a36c3d27c835d65efc7123c446e8c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/78c00df8f170e02473b682df15bfcdacc3d32d72", - "reference": "78c00df8f170e02473b682df15bfcdacc3d32d72", + "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/14c6ba52f95a36c3d27c835d65efc7123c446e8c", + "reference": "14c6ba52f95a36c3d27c835d65efc7123c446e8c", "shasum": "" }, "require": { @@ -2354,15 +2414,27 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/exporter/issues", - "source": "https://github.com/sebastianbergmann/exporter/tree/4.0.6" + "source": "https://github.com/sebastianbergmann/exporter/tree/4.0.8" }, "funding": [ { "url": "https://github.com/sebastianbergmann", "type": "github" + }, + { + "url": "https://liberapay.com/sebastianbergmann", + "type": "liberapay" + }, + { + "url": "https://thanks.dev/u/gh/sebastianbergmann", + "type": "thanks_dev" + }, + { + "url": "https://tidelift.com/funding/github/packagist/sebastian/exporter", + "type": "tidelift" } ], - "time": "2024-03-02T06:33:00+00:00" + "time": "2025-09-24T06:03:27+00:00" }, { "name": "sebastian/global-state", @@ -2370,12 +2442,12 @@ "source": { "type": "git", "url": "https://github.com/sebastianbergmann/global-state.git", - "reference": "bca7df1f32ee6fe93b4d4a9abbf69e13a4ada2c9" + "reference": "b6781316bdcd28260904e7cc18ec983d0d2ef4f6" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/bca7df1f32ee6fe93b4d4a9abbf69e13a4ada2c9", - "reference": "bca7df1f32ee6fe93b4d4a9abbf69e13a4ada2c9", + "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/b6781316bdcd28260904e7cc18ec983d0d2ef4f6", + "reference": "b6781316bdcd28260904e7cc18ec983d0d2ef4f6", "shasum": "" }, "require": { @@ -2418,15 +2490,27 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/global-state/issues", - "source": "https://github.com/sebastianbergmann/global-state/tree/5.0.7" + "source": "https://github.com/sebastianbergmann/global-state/tree/5.0.8" }, "funding": [ { "url": "https://github.com/sebastianbergmann", "type": "github" + }, + { + "url": "https://liberapay.com/sebastianbergmann", + "type": "liberapay" + }, + { + "url": "https://thanks.dev/u/gh/sebastianbergmann", + "type": "thanks_dev" + }, + { + "url": "https://tidelift.com/funding/github/packagist/sebastian/global-state", + "type": "tidelift" } ], - "time": "2024-03-02T06:35:11+00:00" + "time": "2025-08-10T07:10:35+00:00" }, { "name": "sebastian/lines-of-code", @@ -2603,12 +2687,12 @@ "source": { "type": "git", "url": "https://github.com/sebastianbergmann/recursion-context.git", - "reference": "e75bd0f07204fec2a0af9b0f3cfe97d05f92efc1" + "reference": "539c6691e0623af6dc6f9c20384c120f963465a0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/e75bd0f07204fec2a0af9b0f3cfe97d05f92efc1", - "reference": "e75bd0f07204fec2a0af9b0f3cfe97d05f92efc1", + "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/539c6691e0623af6dc6f9c20384c120f963465a0", + "reference": "539c6691e0623af6dc6f9c20384c120f963465a0", "shasum": "" }, "require": { @@ -2650,15 +2734,27 @@ "homepage": "https://github.com/sebastianbergmann/recursion-context", "support": { "issues": "https://github.com/sebastianbergmann/recursion-context/issues", - "source": "https://github.com/sebastianbergmann/recursion-context/tree/4.0.5" + "source": "https://github.com/sebastianbergmann/recursion-context/tree/4.0.6" }, "funding": [ { "url": "https://github.com/sebastianbergmann", "type": "github" + }, + { + "url": "https://liberapay.com/sebastianbergmann", + "type": "liberapay" + }, + { + "url": "https://thanks.dev/u/gh/sebastianbergmann", + "type": "thanks_dev" + }, + { + "url": "https://tidelift.com/funding/github/packagist/sebastian/recursion-context", + "type": "tidelift" } ], - "time": "2023-02-03T06:07:39+00:00" + "time": "2025-08-10T06:57:39+00:00" }, { "name": "sebastian/resource-operations", @@ -2830,12 +2926,12 @@ "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "108d436c2af470858bdaba3257baab3a74172017" + "reference": "c4ba980ca61a9eb18ee6bcc73f28e475852bb1ed" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/108d436c2af470858bdaba3257baab3a74172017", - "reference": "108d436c2af470858bdaba3257baab3a74172017", + "url": "https://api.github.com/repos/symfony/console/zipball/c4ba980ca61a9eb18ee6bcc73f28e475852bb1ed", + "reference": "c4ba980ca61a9eb18ee6bcc73f28e475852bb1ed", "shasum": "" }, "require": { @@ -2921,7 +3017,7 @@ "type": "tidelift" } ], - "time": "2024-10-08T07:27:17+00:00" + "time": "2024-11-06T11:30:55+00:00" }, { "name": "symfony/deprecation-contracts", @@ -2929,12 +3025,12 @@ "source": { "type": "git", "url": "https://github.com/symfony/deprecation-contracts.git", - "reference": "0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1" + "reference": "bbd66f9d55454b9b7a66a9cebe77523806a3288a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1", - "reference": "0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1", + "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/bbd66f9d55454b9b7a66a9cebe77523806a3288a", + "reference": "bbd66f9d55454b9b7a66a9cebe77523806a3288a", "shasum": "" }, "require": { @@ -2943,12 +3039,12 @@ "default-branch": true, "type": "library", "extra": { - "branch-alias": { - "dev-main": "3.5-dev" - }, "thanks": { - "name": "symfony/contracts", - "url": "https://github.com/symfony/contracts" + "url": "https://github.com/symfony/contracts", + "name": "symfony/contracts" + }, + "branch-alias": { + "dev-main": "3.7-dev" } }, "autoload": { @@ -2973,7 +3069,7 @@ "description": "A generic function and convention to trigger deprecation notices", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/deprecation-contracts/tree/v3.5.0" + "source": "https://github.com/symfony/deprecation-contracts/tree/main" }, "funding": [ { @@ -2984,12 +3080,16 @@ "url": "https://github.com/fabpot", "type": "github" }, + { + "url": "https://github.com/nicolas-grekas", + "type": "github" + }, { "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", "type": "tidelift" } ], - "time": "2024-04-18T09:32:20+00:00" + "time": "2026-01-05T13:30:16+00:00" }, { "name": "symfony/polyfill-ctype", @@ -3018,8 +3118,8 @@ "type": "library", "extra": { "thanks": { - "name": "symfony/polyfill", - "url": "https://github.com/symfony/polyfill" + "url": "https://github.com/symfony/polyfill", + "name": "symfony/polyfill" } }, "autoload": { @@ -3053,7 +3153,7 @@ "portable" ], "support": { - "source": "https://github.com/symfony/polyfill-ctype/tree/v1.31.0" + "source": "https://github.com/symfony/polyfill-ctype/tree/v1.33.0" }, "funding": [ { @@ -3064,6 +3164,10 @@ "url": "https://github.com/fabpot", "type": "github" }, + { + "url": "https://github.com/nicolas-grekas", + "type": "github" + }, { "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", "type": "tidelift" @@ -3077,12 +3181,12 @@ "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-grapheme.git", - "reference": "b9123926e3b7bc2f98c02ad54f6a4b02b91a8abe" + "reference": "380872130d3a5dd3ace2f4010d95125fde5d5c70" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-intl-grapheme/zipball/b9123926e3b7bc2f98c02ad54f6a4b02b91a8abe", - "reference": "b9123926e3b7bc2f98c02ad54f6a4b02b91a8abe", + "url": "https://api.github.com/repos/symfony/polyfill-intl-grapheme/zipball/380872130d3a5dd3ace2f4010d95125fde5d5c70", + "reference": "380872130d3a5dd3ace2f4010d95125fde5d5c70", "shasum": "" }, "require": { @@ -3095,8 +3199,8 @@ "type": "library", "extra": { "thanks": { - "name": "symfony/polyfill", - "url": "https://github.com/symfony/polyfill" + "url": "https://github.com/symfony/polyfill", + "name": "symfony/polyfill" } }, "autoload": { @@ -3132,7 +3236,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-intl-grapheme/tree/v1.31.0" + "source": "https://github.com/symfony/polyfill-intl-grapheme/tree/v1.33.0" }, "funding": [ { @@ -3143,12 +3247,16 @@ "url": "https://github.com/fabpot", "type": "github" }, + { + "url": "https://github.com/nicolas-grekas", + "type": "github" + }, { "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", "type": "tidelift" } ], - "time": "2024-09-09T11:45:10+00:00" + "time": "2025-06-27T09:58:17+00:00" }, { "name": "symfony/polyfill-intl-normalizer", @@ -3174,8 +3282,8 @@ "type": "library", "extra": { "thanks": { - "name": "symfony/polyfill", - "url": "https://github.com/symfony/polyfill" + "url": "https://github.com/symfony/polyfill", + "name": "symfony/polyfill" } }, "autoload": { @@ -3214,7 +3322,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-intl-normalizer/tree/v1.31.0" + "source": "https://github.com/symfony/polyfill-intl-normalizer/tree/v1.33.0" }, "funding": [ { @@ -3225,6 +3333,10 @@ "url": "https://github.com/fabpot", "type": "github" }, + { + "url": "https://github.com/nicolas-grekas", + "type": "github" + }, { "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", "type": "tidelift" @@ -3238,15 +3350,16 @@ "source": { "type": "git", "url": "https://github.com/symfony/polyfill-mbstring.git", - "reference": "2369cb908b33d7b7518cce042615de430142497f" + "reference": "6d857f4d76bd4b343eac26d6b539585d2bc56493" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/2369cb908b33d7b7518cce042615de430142497f", - "reference": "2369cb908b33d7b7518cce042615de430142497f", + "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/6d857f4d76bd4b343eac26d6b539585d2bc56493", + "reference": "6d857f4d76bd4b343eac26d6b539585d2bc56493", "shasum": "" }, "require": { + "ext-iconv": "*", "php": ">=7.2" }, "provide": { @@ -3259,8 +3372,8 @@ "type": "library", "extra": { "thanks": { - "name": "symfony/polyfill", - "url": "https://github.com/symfony/polyfill" + "url": "https://github.com/symfony/polyfill", + "name": "symfony/polyfill" } }, "autoload": { @@ -3295,7 +3408,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-mbstring/tree/1.x" + "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.33.0" }, "funding": [ { @@ -3306,12 +3419,16 @@ "url": "https://github.com/fabpot", "type": "github" }, + { + "url": "https://github.com/nicolas-grekas", + "type": "github" + }, { "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", "type": "tidelift" } ], - "time": "2024-09-10T14:38:51+00:00" + "time": "2024-12-23T08:48:59+00:00" }, { "name": "symfony/polyfill-php73", @@ -3334,8 +3451,8 @@ "type": "library", "extra": { "thanks": { - "name": "symfony/polyfill", - "url": "https://github.com/symfony/polyfill" + "url": "https://github.com/symfony/polyfill", + "name": "symfony/polyfill" } }, "autoload": { @@ -3372,7 +3489,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-php73/tree/v1.31.0" + "source": "https://github.com/symfony/polyfill-php73/tree/v1.33.0" }, "funding": [ { @@ -3383,6 +3500,10 @@ "url": "https://github.com/fabpot", "type": "github" }, + { + "url": "https://github.com/nicolas-grekas", + "type": "github" + }, { "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", "type": "tidelift" @@ -3396,12 +3517,12 @@ "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php80.git", - "reference": "60328e362d4c2c802a54fcbf04f9d3fb892b4cf8" + "reference": "0cc9dd0f17f61d8131e7df6b84bd344899fe2608" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/60328e362d4c2c802a54fcbf04f9d3fb892b4cf8", - "reference": "60328e362d4c2c802a54fcbf04f9d3fb892b4cf8", + "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/0cc9dd0f17f61d8131e7df6b84bd344899fe2608", + "reference": "0cc9dd0f17f61d8131e7df6b84bd344899fe2608", "shasum": "" }, "require": { @@ -3411,8 +3532,8 @@ "type": "library", "extra": { "thanks": { - "name": "symfony/polyfill", - "url": "https://github.com/symfony/polyfill" + "url": "https://github.com/symfony/polyfill", + "name": "symfony/polyfill" } }, "autoload": { @@ -3453,7 +3574,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-php80/tree/v1.31.0" + "source": "https://github.com/symfony/polyfill-php80/tree/v1.33.0" }, "funding": [ { @@ -3464,12 +3585,16 @@ "url": "https://github.com/fabpot", "type": "github" }, + { + "url": "https://github.com/nicolas-grekas", + "type": "github" + }, { "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", "type": "tidelift" } ], - "time": "2024-09-09T11:45:10+00:00" + "time": "2025-01-02T08:10:11+00:00" }, { "name": "symfony/service-contracts", @@ -3477,12 +3602,12 @@ "source": { "type": "git", "url": "https://github.com/symfony/service-contracts.git", - "reference": "bd1d9e59a81d8fa4acdcea3f617c581f7475a80f" + "reference": "639fa48ea277babeb67e1432ce60a029d795bd63" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/service-contracts/zipball/bd1d9e59a81d8fa4acdcea3f617c581f7475a80f", - "reference": "bd1d9e59a81d8fa4acdcea3f617c581f7475a80f", + "url": "https://api.github.com/repos/symfony/service-contracts/zipball/639fa48ea277babeb67e1432ce60a029d795bd63", + "reference": "639fa48ea277babeb67e1432ce60a029d795bd63", "shasum": "" }, "require": { @@ -3496,12 +3621,12 @@ "default-branch": true, "type": "library", "extra": { - "branch-alias": { - "dev-main": "3.5-dev" - }, "thanks": { - "name": "symfony/contracts", - "url": "https://github.com/symfony/contracts" + "url": "https://github.com/symfony/contracts", + "name": "symfony/contracts" + }, + "branch-alias": { + "dev-main": "3.7-dev" } }, "autoload": { @@ -3537,7 +3662,7 @@ "standards" ], "support": { - "source": "https://github.com/symfony/service-contracts/tree/v3.5.0" + "source": "https://github.com/symfony/service-contracts/tree/main" }, "funding": [ { @@ -3548,12 +3673,16 @@ "url": "https://github.com/fabpot", "type": "github" }, + { + "url": "https://github.com/nicolas-grekas", + "type": "github" + }, { "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", "type": "tidelift" } ], - "time": "2024-04-18T09:32:20+00:00" + "time": "2026-02-13T20:42:21+00:00" }, { "name": "symfony/string", @@ -3561,12 +3690,12 @@ "source": { "type": "git", "url": "https://github.com/symfony/string.git", - "reference": "38371c60c71c72b3d64d8d76f6b1bb81a2cc3627" + "reference": "2adaf4106f2ef4c67271971bde6d3fe0a6936432" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/string/zipball/38371c60c71c72b3d64d8d76f6b1bb81a2cc3627", - "reference": "38371c60c71c72b3d64d8d76f6b1bb81a2cc3627", + "url": "https://api.github.com/repos/symfony/string/zipball/2adaf4106f2ef4c67271971bde6d3fe0a6936432", + "reference": "2adaf4106f2ef4c67271971bde6d3fe0a6936432", "shasum": "" }, "require": { @@ -3580,7 +3709,6 @@ "symfony/translation-contracts": "<2.5" }, "require-dev": { - "symfony/error-handler": "^5.4|^6.0|^7.0", "symfony/http-client": "^5.4|^6.0|^7.0", "symfony/intl": "^6.2|^7.0", "symfony/translation-contracts": "^2.5|^3.0", @@ -3634,25 +3762,29 @@ "url": "https://github.com/fabpot", "type": "github" }, + { + "url": "https://github.com/nicolas-grekas", + "type": "github" + }, { "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", "type": "tidelift" } ], - "time": "2024-09-25T14:18:03+00:00" + "time": "2026-02-08T20:44:54+00:00" }, { "name": "theseer/tokenizer", - "version": "1.2.3", + "version": "1.3.1", "source": { "type": "git", "url": "https://github.com/theseer/tokenizer.git", - "reference": "737eda637ed5e28c3413cb1ebe8bb52cbf1ca7a2" + "reference": "b7489ce515e168639d17feec34b8847c326b0b3c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/theseer/tokenizer/zipball/737eda637ed5e28c3413cb1ebe8bb52cbf1ca7a2", - "reference": "737eda637ed5e28c3413cb1ebe8bb52cbf1ca7a2", + "url": "https://api.github.com/repos/theseer/tokenizer/zipball/b7489ce515e168639d17feec34b8847c326b0b3c", + "reference": "b7489ce515e168639d17feec34b8847c326b0b3c", "shasum": "" }, "require": { @@ -3681,7 +3813,7 @@ "description": "A small library for converting tokenized PHP source code into XML and potentially other formats", "support": { "issues": "https://github.com/theseer/tokenizer/issues", - "source": "https://github.com/theseer/tokenizer/tree/1.2.3" + "source": "https://github.com/theseer/tokenizer/tree/1.3.1" }, "funding": [ { @@ -3689,7 +3821,7 @@ "type": "github" } ], - "time": "2024-03-03T12:36:25+00:00" + "time": "2025-11-17T20:03:58+00:00" }, { "name": "vimeo/psalm", @@ -3760,10 +3892,10 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "4.x-dev", - "dev-3.x": "3.x-dev", + "dev-1.x": "1.x-dev", "dev-2.x": "2.x-dev", - "dev-1.x": "1.x-dev" + "dev-3.x": "3.x-dev", + "dev-master": "4.x-dev" } }, "autoload": { @@ -3798,30 +3930,35 @@ }, { "name": "webmozart/assert", - "version": "1.9.1", + "version": "1.12.1", "source": { "type": "git", "url": "https://github.com/webmozarts/assert.git", - "reference": "bafc69caeb4d49c39fd0779086c03a3738cbb389" + "reference": "9be6926d8b485f55b9229203f962b51ed377ba68" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/webmozarts/assert/zipball/bafc69caeb4d49c39fd0779086c03a3738cbb389", - "reference": "bafc69caeb4d49c39fd0779086c03a3738cbb389", + "url": "https://api.github.com/repos/webmozarts/assert/zipball/9be6926d8b485f55b9229203f962b51ed377ba68", + "reference": "9be6926d8b485f55b9229203f962b51ed377ba68", "shasum": "" }, "require": { - "php": "^5.3.3 || ^7.0 || ^8.0", - "symfony/polyfill-ctype": "^1.8" - }, - "conflict": { - "phpstan/phpstan": "<0.12.20", - "vimeo/psalm": "<3.9.1" + "ext-ctype": "*", + "ext-date": "*", + "ext-filter": "*", + "php": "^7.2 || ^8.0" }, - "require-dev": { - "phpunit/phpunit": "^4.8.36 || ^7.5.13" + "suggest": { + "ext-intl": "", + "ext-simplexml": "", + "ext-spl": "" }, "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.10-dev" + } + }, "autoload": { "psr-4": { "Webmozart\\Assert\\": "src/" @@ -3845,9 +3982,9 @@ ], "support": { "issues": "https://github.com/webmozarts/assert/issues", - "source": "https://github.com/webmozarts/assert/tree/1.9.1" + "source": "https://github.com/webmozarts/assert/tree/1.12.1" }, - "time": "2020-07-08T17:02:28+00:00" + "time": "2025-10-29T15:56:20+00:00" }, { "name": "webmozart/glob", @@ -3962,6 +4099,6 @@ "platform": { "php": ">=8.0" }, - "platform-dev": [], + "platform-dev": {}, "plugin-api-version": "2.6.0" } diff --git a/src/Logger/Adapter.php b/src/Logger/Adapter.php index d756406..79ec9a1 100644 --- a/src/Logger/Adapter.php +++ b/src/Logger/Adapter.php @@ -3,6 +3,7 @@ namespace Utopia\Logger; use Exception; +use Utopia\Logger\Exception\Push; abstract class Adapter { @@ -20,6 +21,7 @@ abstract public static function getName(): string; * @return int * * @throws Exception + * @throws Push When the remote provider rejects or cannot receive the log (e.g. 4xx/5xx or curl failure) */ abstract public function push(Log $log): int; diff --git a/src/Logger/Adapter/AppSignal.php b/src/Logger/Adapter/AppSignal.php index 94704b4..3680dfa 100644 --- a/src/Logger/Adapter/AppSignal.php +++ b/src/Logger/Adapter/AppSignal.php @@ -3,6 +3,7 @@ namespace Utopia\Logger\Adapter; use Utopia\Logger\Adapter; +use Utopia\Logger\Exception\Push; use Utopia\Logger\Log; use Utopia\Logger\Logger; @@ -148,13 +149,11 @@ public function push(Log $log): int \curl_close($ch); if ($curlError !== CURLE_OK || $httpCode === 0) { - error_log("AppSignal push failed with curl error ({$curlError}): {$response}"); - - return 500; + throw new Push("AppSignal push failed with curl error ({$curlError}): {$response}", 500); } if ($httpCode >= 400) { - error_log("AppSignal push failed with status code {$httpCode}: {$curlError} ({$response})"); + throw new Push("AppSignal push failed with status code {$httpCode}: {$curlError} ({$response})", $httpCode); } return $httpCode; diff --git a/src/Logger/Adapter/LogOwl.php b/src/Logger/Adapter/LogOwl.php index 7036cd3..f456a45 100644 --- a/src/Logger/Adapter/LogOwl.php +++ b/src/Logger/Adapter/LogOwl.php @@ -3,6 +3,7 @@ namespace Utopia\Logger\Adapter; use Utopia\Logger\Adapter; +use Utopia\Logger\Exception\Push; use Utopia\Logger\Log; use Utopia\Logger\Logger; @@ -165,13 +166,11 @@ public function push(Log $log): int \curl_close($ch); if ($curlError !== CURLE_OK || $httpCode === 0) { - error_log("LogOwl push failed with curl error ({$curlError}): {$response}"); - - return 500; + throw new Push("LogOwl push failed with curl error ({$curlError}): {$response}", 500); } if ($httpCode >= 400) { - error_log("LogOwl push failed with status code {$httpCode}: {$curlError} ({$response})"); + throw new Push("LogOwl push failed with status code {$httpCode}: {$curlError} ({$response})", $httpCode); } return $httpCode; diff --git a/src/Logger/Adapter/Raygun.php b/src/Logger/Adapter/Raygun.php index e51e22d..c6669c7 100644 --- a/src/Logger/Adapter/Raygun.php +++ b/src/Logger/Adapter/Raygun.php @@ -3,6 +3,7 @@ namespace Utopia\Logger\Adapter; use Utopia\Logger\Adapter; +use Utopia\Logger\Exception\Push; use Utopia\Logger\Log; use Utopia\Logger\Logger; @@ -133,13 +134,11 @@ public function push(Log $log): int \curl_close($ch); if ($curlError !== CURLE_OK || $httpCode === 0) { - error_log("Raygun push failed with curl error ({$curlError}): {$response}"); - - return 500; + throw new Push("Raygun push failed with curl error ({$curlError}): {$response}", 500); } if ($httpCode >= 400) { - error_log("Raygun push failed with status code {$httpCode}: {$curlError} ({$response})"); + throw new Push("Raygun push failed with status code {$httpCode}: {$curlError} ({$response})", $httpCode); } return $httpCode; diff --git a/src/Logger/Adapter/Sentry.php b/src/Logger/Adapter/Sentry.php index fa95a00..179dad4 100644 --- a/src/Logger/Adapter/Sentry.php +++ b/src/Logger/Adapter/Sentry.php @@ -4,6 +4,7 @@ use Exception; use Utopia\Logger\Adapter; +use Utopia\Logger\Exception\Push; use Utopia\Logger\Log; use Utopia\Logger\Logger; @@ -175,13 +176,11 @@ public function push(Log $log): int \curl_close($ch); if ($curlError !== CURLE_OK || $httpCode === 0) { - error_log("Sentry push failed with curl error ({$curlError}): {$response}"); - - return 500; + throw new Push("Sentry push failed with curl error ({$curlError}): {$response}", 500); } if ($httpCode >= 400) { - error_log("Sentry push failed with status code {$httpCode}: {$curlError} ({$response})"); + throw new Push("Sentry push failed with status code {$httpCode}: {$curlError} ({$response})", $httpCode); } return $httpCode; diff --git a/src/Logger/Exception/Push.php b/src/Logger/Exception/Push.php new file mode 100644 index 0000000..e8f6cea --- /dev/null +++ b/src/Logger/Exception/Push.php @@ -0,0 +1,22 @@ +getCode(); + } +} diff --git a/src/Logger/Logger.php b/src/Logger/Logger.php index 32a5f4a..fd1422c 100644 --- a/src/Logger/Logger.php +++ b/src/Logger/Logger.php @@ -3,6 +3,8 @@ namespace Utopia\Logger; use Exception; +use Utopia\Console; +use Utopia\Logger\Exception\Push; class Logger { @@ -64,8 +66,23 @@ public function addLog(Log $log): int } if ($this->adapter->validate($log)) { - // Push log - return $this->adapter->push($log); + try { + return $this->adapter->push($log); + } catch (Push $e) { + Console::error($e->getMessage()); + Console::error('Log not reported: message="'.\addslashes($log->getMessage()).'", type='.$log->getType().', action='.$log->getAction().', environment='.$log->getEnvironment().', version='.$log->getVersion().', namespace='.($log->getNamespace() ?? 'null').', server='.($log->getServer() ?? 'null')); + $tags = $log->getTags(); + if ($tags !== []) { + Console::error('tags: '.\json_encode($tags)); + } + $extra = $log->getExtra(); + if ($extra !== []) { + $extraJson = \json_encode($extra); + Console::error('extra: '.(\strlen($extraJson) > 2000 ? \substr($extraJson, 0, 2000).'...' : $extraJson)); + } + + return $e->getStatusCode(); + } } return 500; From a5403913944af7a16cb7498259f65abebb465621 Mon Sep 17 00:00:00 2001 From: eldadfux Date: Sun, 22 Feb 2026 10:40:27 +0100 Subject: [PATCH 2/2] fixed format --- composer.json | 102 +++++++++++++++++++++++++------------------------- 1 file changed, 51 insertions(+), 51 deletions(-) diff --git a/composer.json b/composer.json index 907a09f..6891aea 100644 --- a/composer.json +++ b/composer.json @@ -1,53 +1,53 @@ { -"name": "utopia-php/logger", -"description": "Utopia Logger library is simple and lite library for logging information, such as errors or warnings. This library is aiming to be as simple and easy to learn and use.", -"type": "library", -"keywords": [ -"php", -"framework", -"upf", -"utopia", -"logger", -"logging", -"errors", -"warnings", -"logs", -"sentry", -"raygun", -"appsignal" -], -"license": "MIT", -"scripts": { -"check": "./vendor/bin/phpstan analyse --level max src tests", -"lint": "./vendor/bin/pint --test", -"format": "./vendor/bin/pint", -"test-unit": "./vendor/bin/phpunit --configuration phpunit.xml --testsuite unit --debug", -"test-e2e": "./vendor/bin/phpunit --configuration phpunit.xml --testsuite e2e --debug", -"test": [ -"@test-unit", -"@test-e2e" -] -}, -"autoload": { -"psr-4": { -"Utopia\\Logger\\": "src/Logger" -} -}, -"autoload-dev": { -"psr-4": { -"Utopia\\Tests\\E2E\\": "tests/e2e", -"Utopia\\Tests\\Unit\\": "tests/unit" -} -}, -"require": { -"php": ">=8.0", -"utopia-php/console": "^0.1" -}, -"require-dev": { -"phpunit/phpunit": "^9.3", -"vimeo/psalm": "4.0.1", -"laravel/pint": "1.2.*", -"phpstan/phpstan": "1.9.x-dev" -}, -"minimum-stability": "dev" + "name": "utopia-php/logger", + "description": "Utopia Logger library is simple and lite library for logging information, such as errors or warnings. This library is aiming to be as simple and easy to learn and use.", + "type": "library", + "keywords": [ + "php", + "framework", + "upf", + "utopia", + "logger", + "logging", + "errors", + "warnings", + "logs", + "sentry", + "raygun", + "appsignal" + ], + "license": "MIT", + "scripts": { + "check": "./vendor/bin/phpstan analyse --level max src tests", + "lint": "./vendor/bin/pint --test", + "format": "./vendor/bin/pint", + "test-unit": "./vendor/bin/phpunit --configuration phpunit.xml --testsuite unit --debug", + "test-e2e": "./vendor/bin/phpunit --configuration phpunit.xml --testsuite e2e --debug", + "test": [ + "@test-unit", + "@test-e2e" + ] + }, + "autoload": { + "psr-4": { + "Utopia\\Logger\\": "src/Logger" + } + }, + "autoload-dev": { + "psr-4": { + "Utopia\\Tests\\E2E\\": "tests/e2e", + "Utopia\\Tests\\Unit\\": "tests/unit" + } + }, + "require": { + "php": ">=8.0", + "utopia-php/console": "^0.1" + }, + "require-dev": { + "phpunit/phpunit": "^9.3", + "vimeo/psalm": "4.0.1", + "laravel/pint": "1.2.*", + "phpstan/phpstan": "1.9.x-dev" + }, + "minimum-stability": "dev" } \ No newline at end of file