From 841d260b5fd31fe3c776a06e1c12e872d3b70992 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matej=20Ba=C4=8Do?= Date: Tue, 29 Apr 2025 11:31:06 +0200 Subject: [PATCH 01/10] PlatformDB migration preparations --- app/config/collections/platform.php | 2 +- app/controllers/general.php | 12 +++++++++++- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/app/config/collections/platform.php b/app/config/collections/platform.php index ce8be6a874..e53194c513 100644 --- a/app/config/collections/platform.php +++ b/app/config/collections/platform.php @@ -1148,7 +1148,7 @@ return [ 'format' => '', 'size' => 32, 'signed' => true, - 'required' => true, + 'required' => false, 'default' => null, 'array' => false, 'filters' => [], diff --git a/app/controllers/general.php b/app/controllers/general.php index 889571fe62..939573261e 100644 --- a/app/controllers/general.php +++ b/app/controllers/general.php @@ -149,7 +149,17 @@ function router(App $utopia, Database $dbForPlatform, callable $getProjectDB, Sw $dbForProject = $getProjectDB($project); /** @var Document $deployment */ - $deployment = Authorization::skip(fn () => $dbForProject->getDocument('deployments', $rule->getAttribute('deploymentId'))); + if(!empty($rule->getAttribute('deploymentId', ''))) { + $deployment = Authorization::skip(fn () => $dbForProject->getDocument('deployments', $rule->getAttribute('deploymentId'))); + } else { + // 1.6.x DB schema compatibility + // TODO: Make sure deploymentId is never empty, and remove this code + $resource = $rule->getAttribute('deploymentResourceType', '') === 'function' ? + Authorization::skip(fn () => $dbForProject->getDocument('functions', $rule->getAttribute('deploymentResourceId', ''))) : + Authorization::skip(fn () => $dbForProject->getDocument('sites', $rule->getAttribute('deploymentResourceId', ''))); + $deploymentId = $resource->getAttribute('deploymentId', $resource->getAttribute('deployment', '')); + $deployment = Authorization::skip(fn () => $dbForProject->getDocument('deployments', $deploymentId)); + } if ($deployment->getAttribute('resourceType', '') === 'functions') { $type = 'function'; From 7ece755abf4b5341db8fb6d721e40c1b7e9a3e4e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matej=20Ba=C4=8Do?= Date: Tue, 29 Apr 2025 11:56:51 +0200 Subject: [PATCH 02/10] Improve code quality --- app/controllers/general.php | 30 ++++++++++++++++++++++-------- 1 file changed, 22 insertions(+), 8 deletions(-) diff --git a/app/controllers/general.php b/app/controllers/general.php index 939573261e..dbc07f950b 100644 --- a/app/controllers/general.php +++ b/app/controllers/general.php @@ -149,17 +149,31 @@ function router(App $utopia, Database $dbForPlatform, callable $getProjectDB, Sw $dbForProject = $getProjectDB($project); /** @var Document $deployment */ - if(!empty($rule->getAttribute('deploymentId', ''))) { - $deployment = Authorization::skip(fn () => $dbForProject->getDocument('deployments', $rule->getAttribute('deploymentId'))); + if (!empty($rule->getAttribute('deploymentId', ''))) { + $deployment = Authorization::skip(fn () => $dbForProject->getDocument('deployments', $rule->getAttribute('deploymentId'))); } else { // 1.6.x DB schema compatibility // TODO: Make sure deploymentId is never empty, and remove this code - $resource = $rule->getAttribute('deploymentResourceType', '') === 'function' ? - Authorization::skip(fn () => $dbForProject->getDocument('functions', $rule->getAttribute('deploymentResourceId', ''))) : - Authorization::skip(fn () => $dbForProject->getDocument('sites', $rule->getAttribute('deploymentResourceId', ''))); - $deploymentId = $resource->getAttribute('deploymentId', $resource->getAttribute('deployment', '')); - $deployment = Authorization::skip(fn () => $dbForProject->getDocument('deployments', $deploymentId)); - } + + // Check if site or function; should never be site, but better safe than sorry + // Attempts to use attribute from both schemas (1.6 and 1.7) + $resourceType = $rule->getAttribute('deploymentResourceType', $rule->getAttribute('resourceType', '')); + + // ID of site or function + $resourceId = $rule->getAttribute('deploymentResourceId', ''); + + // Document of site or function + $resource = $resourceType === 'function' ? + Authorization::skip(fn () => $dbForProject->getDocument('functions', $resourceId)) : + Authorization::skip(fn () => $dbForProject->getDocument('sites', $resourceId)); + + // ID of active deployments + // Attempts to use attribute from both schemas (1.6 and 1.7) + $activeDeploymentId = $resource->getAttribute('deploymentId', $resource->getAttribute('deployment', '')); + + // Get deployment document, as intended originally + $deployment = Authorization::skip(fn () => $dbForProject->getDocument('deployments', $activeDeploymentId)); + } if ($deployment->getAttribute('resourceType', '') === 'functions') { $type = 'function'; From 0148c3ed7780fd1fe6d9e6632bf74732f4026deb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matej=20Ba=C4=8Do?= Date: Tue, 29 Apr 2025 16:00:09 +0200 Subject: [PATCH 03/10] Fix migration row length issue --- app/config/collections/projects.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/config/collections/projects.php b/app/config/collections/projects.php index 19547559e6..ec44e0a72b 100644 --- a/app/config/collections/projects.php +++ b/app/config/collections/projects.php @@ -1361,7 +1361,7 @@ return [ '$id' => ID::custom('sourcePath'), 'type' => Database::VAR_STRING, 'format' => '', - 'size' => 2048, + 'size' => 16384, 'signed' => true, 'required' => false, 'default' => null, From bd50baff85f85a0746d2da7274450a2d41559144 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matej=20Ba=C4=8Do?= Date: Wed, 30 Apr 2025 09:31:17 +0200 Subject: [PATCH 04/10] Upgrade db lib for migration fix --- composer.lock | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/composer.lock b/composer.lock index 17b3b27078..a1b91ab2e6 100644 --- a/composer.lock +++ b/composer.lock @@ -3705,16 +3705,16 @@ }, { "name": "utopia-php/fetch", - "version": "0.4.1", + "version": "0.4.2", "source": { "type": "git", "url": "https://github.com/utopia-php/fetch.git", - "reference": "65095dac14037db0c822fb5e209e5bd3187a0303" + "reference": "83986d1be75a2fae4e684107fe70dd78a8e19b77" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/utopia-php/fetch/zipball/65095dac14037db0c822fb5e209e5bd3187a0303", - "reference": "65095dac14037db0c822fb5e209e5bd3187a0303", + "url": "https://api.github.com/repos/utopia-php/fetch/zipball/83986d1be75a2fae4e684107fe70dd78a8e19b77", + "reference": "83986d1be75a2fae4e684107fe70dd78a8e19b77", "shasum": "" }, "require": { @@ -3738,9 +3738,9 @@ "description": "A simple library that provides an interface for making HTTP Requests.", "support": { "issues": "https://github.com/utopia-php/fetch/issues", - "source": "https://github.com/utopia-php/fetch/tree/0.4.1" + "source": "https://github.com/utopia-php/fetch/tree/0.4.2" }, - "time": "2025-04-14T07:34:27+00:00" + "time": "2025-04-25T13:48:02+00:00" }, { "name": "utopia-php/framework", @@ -5275,16 +5275,16 @@ }, { "name": "myclabs/deep-copy", - "version": "1.13.0", + "version": "1.13.1", "source": { "type": "git", "url": "https://github.com/myclabs/DeepCopy.git", - "reference": "024473a478be9df5fdaca2c793f2232fe788e414" + "reference": "1720ddd719e16cf0db4eb1c6eca108031636d46c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/024473a478be9df5fdaca2c793f2232fe788e414", - "reference": "024473a478be9df5fdaca2c793f2232fe788e414", + "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/1720ddd719e16cf0db4eb1c6eca108031636d46c", + "reference": "1720ddd719e16cf0db4eb1c6eca108031636d46c", "shasum": "" }, "require": { @@ -5323,7 +5323,7 @@ ], "support": { "issues": "https://github.com/myclabs/DeepCopy/issues", - "source": "https://github.com/myclabs/DeepCopy/tree/1.13.0" + "source": "https://github.com/myclabs/DeepCopy/tree/1.13.1" }, "funding": [ { @@ -5331,7 +5331,7 @@ "type": "tidelift" } ], - "time": "2025-02-12T12:17:51+00:00" + "time": "2025-04-29T12:36:36+00:00" }, { "name": "nikic/php-parser", From e1dbf2170e2ee79c23d52ff0ff7ff27535e40f28 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matej=20Ba=C4=8Do?= Date: Wed, 30 Apr 2025 12:10:51 +0200 Subject: [PATCH 05/10] Migration preparations --- app/config/collections/projects.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/config/collections/projects.php b/app/config/collections/projects.php index ec44e0a72b..152c6a5e6a 100644 --- a/app/config/collections/projects.php +++ b/app/config/collections/projects.php @@ -1699,7 +1699,7 @@ return [ 'format' => '', 'size' => 16, 'signed' => true, - 'required' => true, + 'required' => false, 'default' => 'waiting', 'array' => false, 'filters' => [], From 279ff8f5ae22302644a28305dabe23b92a0c16dd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matej=20Ba=C4=8Do?= Date: Wed, 30 Apr 2025 12:38:32 +0200 Subject: [PATCH 06/10] Migration preps, table width issues --- app/config/collections/projects.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/app/config/collections/projects.php b/app/config/collections/projects.php index 152c6a5e6a..99707752bb 100644 --- a/app/config/collections/projects.php +++ b/app/config/collections/projects.php @@ -1029,7 +1029,7 @@ return [ '$id' => ID::custom('fallbackFile'), 'type' => Database::VAR_STRING, 'format' => '', - 'size' => Database::LENGTH_KEY, + 'size' => 16384, 'signed' => true, 'required' => false, 'default' => null, @@ -1205,7 +1205,7 @@ return [ '$id' => ID::custom('adapter'), // ssr or static; named this way as it's a term in SSR frameworks 'type' => Database::VAR_STRING, 'format' => '', - 'size' => 128, + 'size' => 16, 'signed' => true, 'required' => false, 'default' => '', @@ -1708,7 +1708,7 @@ return [ '$id' => ID::custom('buildPath'), 'type' => Database::VAR_STRING, 'format' => '', - 'size' => Database::LENGTH_KEY, + 'size' => 16384, 'signed' => true, 'required' => false, 'default' => '', @@ -1730,7 +1730,7 @@ return [ '$id' => ID::custom('adapter'), // ssr or static; named this way as it's a term in SSR frameworks 'type' => Database::VAR_STRING, 'format' => '', - 'size' => 128, + 'size' => 16, 'signed' => true, 'required' => false, 'default' => '', @@ -1741,7 +1741,7 @@ return [ '$id' => ID::custom('fallbackFile'), 'type' => Database::VAR_STRING, 'format' => '', - 'size' => Database::LENGTH_KEY, + 'size' => 16384, 'signed' => true, 'required' => false, 'default' => null, From f76aff19163ecff093507cb5026b96ceff303622 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matej=20Ba=C4=8Do?= Date: Fri, 2 May 2025 11:17:51 +0200 Subject: [PATCH 07/10] Migration preparations --- app/config/collections/projects.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/config/collections/projects.php b/app/config/collections/projects.php index 99707752bb..5105304599 100644 --- a/app/config/collections/projects.php +++ b/app/config/collections/projects.php @@ -1372,7 +1372,7 @@ return [ '$id' => ID::custom('type'), 'type' => Database::VAR_STRING, 'format' => '', - 'size' => 32, + 'size' => 2048, 'signed' => true, 'required' => true, 'default' => null, From 7e6c148f71fda6f294e2d812959d4e2b04fa8ade Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matej=20Ba=C4=8Do?= Date: Mon, 5 May 2025 19:30:27 +0200 Subject: [PATCH 08/10] Upgrade DB lib --- composer.json | 4 +- composer.lock | 169 ++++++++++++++++++++++++++++---------------------- 2 files changed, 96 insertions(+), 77 deletions(-) diff --git a/composer.json b/composer.json index cce3abc522..0e645887a0 100644 --- a/composer.json +++ b/composer.json @@ -49,11 +49,11 @@ "utopia-php/abuse": "0.52.*", "utopia-php/analytics": "0.10.*", "utopia-php/audit": "0.55.*", - "utopia-php/cache": "0.12.*", + "utopia-php/cache": "0.13.*", "utopia-php/cli": "0.15.*", "utopia-php/config": "0.2.*", "utopia-php/detector": "0.1.*", - "utopia-php/database": "0.66.*", + "utopia-php/database": "dev-fix-collection-delete-v1 as 0.66.99", "utopia-php/domains": "0.5.*", "utopia-php/dsn": "0.2.1", "utopia-php/framework": "0.33.*", diff --git a/composer.lock b/composer.lock index a1b91ab2e6..ba919cf04c 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": "51959289a3f882160f5a9eeb605d41d7", + "content-hash": "fda4c4fd7a656edae3088e2625f9fc75", "packages": [ { "name": "adhocore/jwt", @@ -1179,16 +1179,16 @@ }, { "name": "open-telemetry/context", - "version": "1.1.0", + "version": "1.2.0", "source": { "type": "git", "url": "https://github.com/opentelemetry-php/context.git", - "reference": "0cba875ea1953435f78aec7f1d75afa87bdbf7f3" + "reference": "5f553042b951d3fedf47925852c380159dfca801" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/opentelemetry-php/context/zipball/0cba875ea1953435f78aec7f1d75afa87bdbf7f3", - "reference": "0cba875ea1953435f78aec7f1d75afa87bdbf7f3", + "url": "https://api.github.com/repos/opentelemetry-php/context/zipball/5f553042b951d3fedf47925852c380159dfca801", + "reference": "5f553042b951d3fedf47925852c380159dfca801", "shasum": "" }, "require": { @@ -1234,7 +1234,7 @@ "issues": "https://github.com/open-telemetry/opentelemetry-php/issues", "source": "https://github.com/open-telemetry/opentelemetry-php" }, - "time": "2024-08-21T00:29:20+00:00" + "time": "2025-05-02T01:57:57+00:00" }, { "name": "open-telemetry/exporter-otlp", @@ -1365,16 +1365,16 @@ }, { "name": "open-telemetry/sdk", - "version": "1.2.4", + "version": "1.3.0", "source": { "type": "git", "url": "https://github.com/opentelemetry-php/sdk.git", - "reference": "47fcb66ae5328c5a799195247b1dce551d85873e" + "reference": "05d9ceb6773b5bddcf485af6d4a6f543bbeb980b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/opentelemetry-php/sdk/zipball/47fcb66ae5328c5a799195247b1dce551d85873e", - "reference": "47fcb66ae5328c5a799195247b1dce551d85873e", + "url": "https://api.github.com/repos/opentelemetry-php/sdk/zipball/05d9ceb6773b5bddcf485af6d4a6f543bbeb980b", + "reference": "05d9ceb6773b5bddcf485af6d4a6f543bbeb980b", "shasum": "" }, "require": { @@ -1451,20 +1451,20 @@ "issues": "https://github.com/open-telemetry/opentelemetry-php/issues", "source": "https://github.com/open-telemetry/opentelemetry-php" }, - "time": "2025-04-15T07:02:07+00:00" + "time": "2025-05-01T23:20:43+00:00" }, { "name": "open-telemetry/sem-conv", - "version": "1.30.0", + "version": "1.32.0", "source": { "type": "git", "url": "https://github.com/opentelemetry-php/sem-conv.git", - "reference": "4178c9f390da8e4dbca9b181a9d1efd50cf7ee0a" + "reference": "16585cc0dbc3032a318e274043454679430d2ebf" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/opentelemetry-php/sem-conv/zipball/4178c9f390da8e4dbca9b181a9d1efd50cf7ee0a", - "reference": "4178c9f390da8e4dbca9b181a9d1efd50cf7ee0a", + "url": "https://api.github.com/repos/opentelemetry-php/sem-conv/zipball/16585cc0dbc3032a318e274043454679430d2ebf", + "reference": "16585cc0dbc3032a318e274043454679430d2ebf", "shasum": "" }, "require": { @@ -1508,7 +1508,7 @@ "issues": "https://github.com/open-telemetry/opentelemetry-php/issues", "source": "https://github.com/open-telemetry/opentelemetry-php" }, - "time": "2025-02-06T00:21:48+00:00" + "time": "2025-05-05T03:58:53+00:00" }, { "name": "paragonie/constant_time_encoding", @@ -2726,19 +2726,20 @@ }, { "name": "symfony/polyfill-mbstring", - "version": "v1.31.0", + "version": "v1.32.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-mbstring.git", - "reference": "85181ba99b2345b0ef10ce42ecac37612d9fd341" + "reference": "6d857f4d76bd4b343eac26d6b539585d2bc56493" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/85181ba99b2345b0ef10ce42ecac37612d9fd341", - "reference": "85181ba99b2345b0ef10ce42ecac37612d9fd341", + "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/6d857f4d76bd4b343eac26d6b539585d2bc56493", + "reference": "6d857f4d76bd4b343eac26d6b539585d2bc56493", "shasum": "" }, "require": { + "ext-iconv": "*", "php": ">=7.2" }, "provide": { @@ -2786,7 +2787,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.31.0" + "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.32.0" }, "funding": [ { @@ -2802,11 +2803,11 @@ "type": "tidelift" } ], - "time": "2024-09-09T11:45:10+00:00" + "time": "2024-12-23T08:48:59+00:00" }, { "name": "symfony/polyfill-php82", - "version": "v1.31.0", + "version": "v1.32.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php82.git", @@ -2862,7 +2863,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-php82/tree/v1.31.0" + "source": "https://github.com/symfony/polyfill-php82/tree/v1.32.0" }, "funding": [ { @@ -3300,16 +3301,16 @@ }, { "name": "utopia-php/cache", - "version": "0.12.0", + "version": "0.13.0", "source": { "type": "git", "url": "https://github.com/utopia-php/cache.git", - "reference": "646038f1d470b759c129348be8fc14da3c00bbd9" + "reference": "dee01dec33a211644d60f6cfa56b1b8176d3fae3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/utopia-php/cache/zipball/646038f1d470b759c129348be8fc14da3c00bbd9", - "reference": "646038f1d470b759c129348be8fc14da3c00bbd9", + "url": "https://api.github.com/repos/utopia-php/cache/zipball/dee01dec33a211644d60f6cfa56b1b8176d3fae3", + "reference": "dee01dec33a211644d60f6cfa56b1b8176d3fae3", "shasum": "" }, "require": { @@ -3317,6 +3318,7 @@ "ext-memcached": "*", "ext-redis": "*", "php": ">=8.0", + "utopia-php/pools": "0.8.*", "utopia-php/telemetry": "0.1.*" }, "require-dev": { @@ -3345,9 +3347,9 @@ ], "support": { "issues": "https://github.com/utopia-php/cache/issues", - "source": "https://github.com/utopia-php/cache/tree/0.12.0" + "source": "https://github.com/utopia-php/cache/tree/0.13.0" }, - "time": "2025-02-25T09:09:21+00:00" + "time": "2025-04-17T04:20:26+00:00" }, { "name": "utopia-php/cli", @@ -3497,23 +3499,23 @@ }, { "name": "utopia-php/database", - "version": "0.66.0", + "version": "dev-fix-collection-delete-v1", "source": { "type": "git", "url": "https://github.com/utopia-php/database.git", - "reference": "67d2ab418efba31dc76b3564cf043e2b3f98d027" + "reference": "dfda0e1521a75312e2fed93db5d49ee2cb43c930" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/utopia-php/database/zipball/67d2ab418efba31dc76b3564cf043e2b3f98d027", - "reference": "67d2ab418efba31dc76b3564cf043e2b3f98d027", + "url": "https://api.github.com/repos/utopia-php/database/zipball/dfda0e1521a75312e2fed93db5d49ee2cb43c930", + "reference": "dfda0e1521a75312e2fed93db5d49ee2cb43c930", "shasum": "" }, "require": { "ext-mbstring": "*", "ext-pdo": "*", "php": ">=8.1", - "utopia-php/cache": "0.12.*", + "utopia-php/cache": "0.13.*", "utopia-php/framework": "0.33.*", "utopia-php/pools": "0.8.*" }, @@ -3547,9 +3549,9 @@ ], "support": { "issues": "https://github.com/utopia-php/database/issues", - "source": "https://github.com/utopia-php/database/tree/0.66.0" + "source": "https://github.com/utopia-php/database/tree/fix-collection-delete-v1" }, - "time": "2025-04-16T07:10:27+00:00" + "time": "2025-05-05T17:14:21+00:00" }, { "name": "utopia-php/detector", @@ -4588,28 +4590,28 @@ }, { "name": "utopia-php/vcs", - "version": "0.10.1", + "version": "0.10.2", "source": { "type": "git", "url": "https://github.com/utopia-php/vcs.git", - "reference": "6be02650cc361764900ade8c129f309df263eb74" + "reference": "1f9823ebcb8fd098607de0074f18f48e28985012" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/utopia-php/vcs/zipball/6be02650cc361764900ade8c129f309df263eb74", - "reference": "6be02650cc361764900ade8c129f309df263eb74", + "url": "https://api.github.com/repos/utopia-php/vcs/zipball/1f9823ebcb8fd098607de0074f18f48e28985012", + "reference": "1f9823ebcb8fd098607de0074f18f48e28985012", "shasum": "" }, "require": { "adhocore/jwt": "^1.1", "php": ">=8.0", - "utopia-php/cache": "0.12.*", + "utopia-php/cache": "0.13.*", "utopia-php/framework": "0.*.*", "utopia-php/system": "0.9.*" }, "require-dev": { - "laravel/pint": "1.2.*", - "phpstan/phpstan": "1.8.*", + "laravel/pint": "1.*.*", + "phpstan/phpstan": "1.*.*", "phpunit/phpunit": "^9.4" }, "type": "library", @@ -4631,9 +4633,9 @@ ], "support": { "issues": "https://github.com/utopia-php/vcs/issues", - "source": "https://github.com/utopia-php/vcs/tree/0.10.1" + "source": "https://github.com/utopia-php/vcs/tree/0.10.2" }, - "time": "2025-03-18T11:44:09+00:00" + "time": "2025-04-17T04:35:25+00:00" }, { "name": "utopia-php/websocket", @@ -6038,16 +6040,16 @@ }, { "name": "phpunit/phpunit", - "version": "9.6.22", + "version": "9.6.23", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "f80235cb4d3caa59ae09be3adf1ded27521d1a9c" + "reference": "43d2cb18d0675c38bd44982a5d1d88f6d53d8d95" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/f80235cb4d3caa59ae09be3adf1ded27521d1a9c", - "reference": "f80235cb4d3caa59ae09be3adf1ded27521d1a9c", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/43d2cb18d0675c38bd44982a5d1d88f6d53d8d95", + "reference": "43d2cb18d0675c38bd44982a5d1d88f6d53d8d95", "shasum": "" }, "require": { @@ -6058,7 +6060,7 @@ "ext-mbstring": "*", "ext-xml": "*", "ext-xmlwriter": "*", - "myclabs/deep-copy": "^1.12.1", + "myclabs/deep-copy": "^1.13.1", "phar-io/manifest": "^2.0.4", "phar-io/version": "^3.2.1", "php": ">=7.3", @@ -6121,7 +6123,7 @@ "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", "security": "https://github.com/sebastianbergmann/phpunit/security/policy", - "source": "https://github.com/sebastianbergmann/phpunit/tree/9.6.22" + "source": "https://github.com/sebastianbergmann/phpunit/tree/9.6.23" }, "funding": [ { @@ -6132,12 +6134,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-12-05T13:48:26+00:00" + "time": "2025-05-02T06:40:34+00:00" }, { "name": "psr/cache", @@ -7249,16 +7259,16 @@ }, { "name": "symfony/console", - "version": "v7.2.5", + "version": "v7.2.6", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "e51498ea18570c062e7df29d05a7003585b19b88" + "reference": "0e2e3f38c192e93e622e41ec37f4ca70cfedf218" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/e51498ea18570c062e7df29d05a7003585b19b88", - "reference": "e51498ea18570c062e7df29d05a7003585b19b88", + "url": "https://api.github.com/repos/symfony/console/zipball/0e2e3f38c192e93e622e41ec37f4ca70cfedf218", + "reference": "0e2e3f38c192e93e622e41ec37f4ca70cfedf218", "shasum": "" }, "require": { @@ -7322,7 +7332,7 @@ "terminal" ], "support": { - "source": "https://github.com/symfony/console/tree/v7.2.5" + "source": "https://github.com/symfony/console/tree/v7.2.6" }, "funding": [ { @@ -7338,7 +7348,7 @@ "type": "tidelift" } ], - "time": "2025-03-12T08:11:12+00:00" + "time": "2025-04-07T19:09:28+00:00" }, { "name": "symfony/filesystem", @@ -7539,7 +7549,7 @@ }, { "name": "symfony/polyfill-ctype", - "version": "v1.31.0", + "version": "v1.32.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-ctype.git", @@ -7598,7 +7608,7 @@ "portable" ], "support": { - "source": "https://github.com/symfony/polyfill-ctype/tree/v1.31.0" + "source": "https://github.com/symfony/polyfill-ctype/tree/v1.32.0" }, "funding": [ { @@ -7618,7 +7628,7 @@ }, { "name": "symfony/polyfill-intl-grapheme", - "version": "v1.31.0", + "version": "v1.32.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-grapheme.git", @@ -7676,7 +7686,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.32.0" }, "funding": [ { @@ -7696,7 +7706,7 @@ }, { "name": "symfony/polyfill-intl-normalizer", - "version": "v1.31.0", + "version": "v1.32.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-normalizer.git", @@ -7757,7 +7767,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.32.0" }, "funding": [ { @@ -7777,7 +7787,7 @@ }, { "name": "symfony/polyfill-php81", - "version": "v1.31.0", + "version": "v1.32.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php81.git", @@ -7833,7 +7843,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-php81/tree/v1.31.0" + "source": "https://github.com/symfony/polyfill-php81/tree/v1.32.0" }, "funding": [ { @@ -7914,16 +7924,16 @@ }, { "name": "symfony/string", - "version": "v7.2.0", + "version": "v7.2.6", "source": { "type": "git", "url": "https://github.com/symfony/string.git", - "reference": "446e0d146f991dde3e73f45f2c97a9faad773c82" + "reference": "a214fe7d62bd4df2a76447c67c6b26e1d5e74931" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/string/zipball/446e0d146f991dde3e73f45f2c97a9faad773c82", - "reference": "446e0d146f991dde3e73f45f2c97a9faad773c82", + "url": "https://api.github.com/repos/symfony/string/zipball/a214fe7d62bd4df2a76447c67c6b26e1d5e74931", + "reference": "a214fe7d62bd4df2a76447c67c6b26e1d5e74931", "shasum": "" }, "require": { @@ -7981,7 +7991,7 @@ "utf8" ], "support": { - "source": "https://github.com/symfony/string/tree/v7.2.0" + "source": "https://github.com/symfony/string/tree/v7.2.6" }, "funding": [ { @@ -7997,7 +8007,7 @@ "type": "tidelift" } ], - "time": "2024-11-13T13:31:26+00:00" + "time": "2025-04-20T20:18:16+00:00" }, { "name": "textalk/websocket", @@ -8227,9 +8237,18 @@ "time": "2024-03-07T20:33:40+00:00" } ], - "aliases": [], + "aliases": [ + { + "package": "utopia-php/database", + "version": "dev-fix-collection-delete-v1", + "alias": "0.66.99", + "alias_normalized": "0.66.99.0" + } + ], "minimum-stability": "stable", - "stability-flags": [], + "stability-flags": { + "utopia-php/database": 20 + }, "prefer-stable": false, "prefer-lowest": false, "platform": { From 9c33649ec7e25665fb77a216faacf5a695f0a388 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matej=20Ba=C4=8Do?= Date: Tue, 6 May 2025 13:24:43 +0200 Subject: [PATCH 09/10] Upgrade DB lib for migration step3 (deletion) --- composer.json | 2 +- composer.lock | 27 +++++++++------------------ 2 files changed, 10 insertions(+), 19 deletions(-) diff --git a/composer.json b/composer.json index 0e645887a0..28c3ad51e6 100644 --- a/composer.json +++ b/composer.json @@ -53,7 +53,7 @@ "utopia-php/cli": "0.15.*", "utopia-php/config": "0.2.*", "utopia-php/detector": "0.1.*", - "utopia-php/database": "dev-fix-collection-delete-v1 as 0.66.99", + "utopia-php/database": "0.67.*", "utopia-php/domains": "0.5.*", "utopia-php/dsn": "0.2.1", "utopia-php/framework": "0.33.*", diff --git a/composer.lock b/composer.lock index ba919cf04c..6f2bf05ed9 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": "fda4c4fd7a656edae3088e2625f9fc75", + "content-hash": "11fce9a96898cdde0fea0e581d1da5c3", "packages": [ { "name": "adhocore/jwt", @@ -3499,16 +3499,16 @@ }, { "name": "utopia-php/database", - "version": "dev-fix-collection-delete-v1", + "version": "0.67.1", "source": { "type": "git", "url": "https://github.com/utopia-php/database.git", - "reference": "dfda0e1521a75312e2fed93db5d49ee2cb43c930" + "reference": "8a17cd51b034dd94b2d28e8da372e2641b4df288" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/utopia-php/database/zipball/dfda0e1521a75312e2fed93db5d49ee2cb43c930", - "reference": "dfda0e1521a75312e2fed93db5d49ee2cb43c930", + "url": "https://api.github.com/repos/utopia-php/database/zipball/8a17cd51b034dd94b2d28e8da372e2641b4df288", + "reference": "8a17cd51b034dd94b2d28e8da372e2641b4df288", "shasum": "" }, "require": { @@ -3549,9 +3549,9 @@ ], "support": { "issues": "https://github.com/utopia-php/database/issues", - "source": "https://github.com/utopia-php/database/tree/fix-collection-delete-v1" + "source": "https://github.com/utopia-php/database/tree/0.67.1" }, - "time": "2025-05-05T17:14:21+00:00" + "time": "2025-05-06T11:00:10+00:00" }, { "name": "utopia-php/detector", @@ -8237,18 +8237,9 @@ "time": "2024-03-07T20:33:40+00:00" } ], - "aliases": [ - { - "package": "utopia-php/database", - "version": "dev-fix-collection-delete-v1", - "alias": "0.66.99", - "alias_normalized": "0.66.99.0" - } - ], + "aliases": [], "minimum-stability": "stable", - "stability-flags": { - "utopia-php/database": 20 - }, + "stability-flags": [], "prefer-stable": false, "prefer-lowest": false, "platform": { From 4c7c38947ddd94971be1d8d0f70ea42cb6d3c9a5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matej=20Ba=C4=8Do?= Date: Tue, 6 May 2025 14:12:48 +0200 Subject: [PATCH 10/10] Upgrade DB lib --- composer.lock | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/composer.lock b/composer.lock index 6f2bf05ed9..02401ca490 100644 --- a/composer.lock +++ b/composer.lock @@ -3499,16 +3499,16 @@ }, { "name": "utopia-php/database", - "version": "0.67.1", + "version": "0.67.2", "source": { "type": "git", "url": "https://github.com/utopia-php/database.git", - "reference": "8a17cd51b034dd94b2d28e8da372e2641b4df288" + "reference": "cd55117beab0025fd0d3f945a5a004125600982c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/utopia-php/database/zipball/8a17cd51b034dd94b2d28e8da372e2641b4df288", - "reference": "8a17cd51b034dd94b2d28e8da372e2641b4df288", + "url": "https://api.github.com/repos/utopia-php/database/zipball/cd55117beab0025fd0d3f945a5a004125600982c", + "reference": "cd55117beab0025fd0d3f945a5a004125600982c", "shasum": "" }, "require": { @@ -3549,9 +3549,9 @@ ], "support": { "issues": "https://github.com/utopia-php/database/issues", - "source": "https://github.com/utopia-php/database/tree/0.67.1" + "source": "https://github.com/utopia-php/database/tree/0.67.2" }, - "time": "2025-05-06T11:00:10+00:00" + "time": "2025-05-06T12:11:58+00:00" }, { "name": "utopia-php/detector",