From f8fb2e8c2d226813f02e7e8b389646e4b246c8eb Mon Sep 17 00:00:00 2001 From: Damodar Lohani Date: Tue, 10 Feb 2026 00:01:40 +0000 Subject: [PATCH 1/9] Chore: test group --- tests/e2e/General/HTTPTest.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tests/e2e/General/HTTPTest.php b/tests/e2e/General/HTTPTest.php index 4012745682..56f3cb7fb0 100644 --- a/tests/e2e/General/HTTPTest.php +++ b/tests/e2e/General/HTTPTest.php @@ -18,6 +18,11 @@ class HTTPTest extends Scope $this->client->setEndpoint('http://appwrite.test'); } + /** + * @group ci-ignore + * + * @return void + */ public function testOptions() { /** From bb76becf81ce76926d2bf88edf0e5ca511d6714b Mon Sep 17 00:00:00 2001 From: Damodar Lohani Date: Tue, 10 Feb 2026 10:52:53 +0000 Subject: [PATCH 2/9] Add CORS configuration and refactor CORS resource handling --- app/config/cors.php | 53 +++++++++++++++++++++++++++++++++++++ app/init/configs.php | 1 + app/init/resources.php | 59 ++++++++---------------------------------- 3 files changed, 65 insertions(+), 48 deletions(-) create mode 100644 app/config/cors.php diff --git a/app/config/cors.php b/app/config/cors.php new file mode 100644 index 0000000000..ef1adeb998 --- /dev/null +++ b/app/config/cors.php @@ -0,0 +1,53 @@ + ['GET', 'POST', 'PUT', 'PATCH', 'DELETE'], + 'allowedHeaders' => [ + 'Accept', + 'Origin', + 'Cookie', + 'Set-Cookie', + // Content + 'Content-Type', + 'Content-Range', + // Appwrite + 'X-Appwrite-Project', + 'X-Appwrite-Key', + 'X-Appwrite-Dev-Key', + 'X-Appwrite-Locale', + 'X-Appwrite-Mode', + 'X-Appwrite-JWT', + 'X-Appwrite-Response-Format', + 'X-Appwrite-Timeout', + 'X-Appwrite-ID', + 'X-Appwrite-Timestamp', + 'X-Appwrite-Session', + 'X-Appwrite-Platform', + // SDK generator + 'X-SDK-Version', + 'X-SDK-Name', + 'X-SDK-Language', + 'X-SDK-Platform', + 'X-SDK-GraphQL', + 'X-SDK-Profile', + // Caching + 'Range', + 'Cache-Control', + 'Expires', + 'Pragma', + // Server to server + 'X-Fallback-Cookies', + 'X-Requested-With', + 'X-Forwarded-For', + 'X-Forwarded-User-Agent', + ], + 'exposedHeaders' => [ + 'X-Appwrite-Session', + 'X-Fallback-Cookies', + ], +]; diff --git a/app/init/configs.php b/app/init/configs.php index d5748707cf..35c8e3899d 100644 --- a/app/init/configs.php +++ b/app/init/configs.php @@ -46,3 +46,4 @@ Config::load('storage-outputs', __DIR__ . '/../config/storage/outputs.php', $con Config::load('specifications', __DIR__ . '/../config/specifications.php', $configAdapter); Config::load('templates-function', __DIR__ . '/../config/templates/function.php', $configAdapter); Config::load('templates-site', __DIR__ . '/../config/templates/site.php', $configAdapter); +Config::load('cors', __DIR__ . '/../config/cors.php', $configAdapter); diff --git a/app/init/resources.php b/app/init/resources.php index 8f78df1573..792efce4f7 100644 --- a/app/init/resources.php +++ b/app/init/resources.php @@ -296,54 +296,17 @@ Http::setResource('rule', function (Request $request, Database $dbForPlatform, D /** * CORS service */ -Http::setResource('cors', fn (array $allowedHostnames) => new Cors( - $allowedHostnames, - allowedMethods: ['GET', 'POST', 'PUT', 'PATCH', 'DELETE'], - allowedHeaders: [ - 'Accept', - 'Origin', - 'Cookie', - 'Set-Cookie', - // Content - 'Content-Type', - 'Content-Range', - // Appwrite - 'X-Appwrite-Project', - 'X-Appwrite-Key', - 'X-Appwrite-Dev-Key', - 'X-Appwrite-Locale', - 'X-Appwrite-Mode', - 'X-Appwrite-JWT', - 'X-Appwrite-Response-Format', - 'X-Appwrite-Timeout', - 'X-Appwrite-ID', - 'X-Appwrite-Timestamp', - 'X-Appwrite-Session', - 'X-Appwrite-Platform', // for `$platform` injection and SDK generator - // SDK generator - 'X-SDK-Version', - 'X-SDK-Name', - 'X-SDK-Language', - 'X-SDK-Platform', - 'X-SDK-GraphQL', - 'X-SDK-Profile', - // Caching - 'Range', - 'Cache-Control', - 'Expires', - 'Pragma', - // Server to server - 'X-Fallback-Cookies', - 'X-Requested-With', - 'X-Forwarded-For', - 'X-Forwarded-User-Agent', - ], - allowCredentials: true, - exposedHeaders: [ - 'X-Appwrite-Session', - 'X-Fallback-Cookies', - ], -), ['allowedHostnames']); +Http::setResource('cors', function (array $allowedHostnames) { + $corsConfig = Config::getParam('cors'); + + return new Cors( + $allowedHostnames, + allowedMethods: $corsConfig['allowedMethods'], + allowedHeaders: $corsConfig['allowedHeaders'], + allowCredentials: true, + exposedHeaders: $corsConfig['exposedHeaders'], + ); +}, ['allowedHostnames']); Http::setResource('originValidator', function (Document $devKey, array $allowedHostnames, array $allowedSchemes) { if (!$devKey->isEmpty()) { From ac35e7c7ad8f366097368f0900886cf057c9ac24 Mon Sep 17 00:00:00 2001 From: Damodar Lohani Date: Wed, 11 Feb 2026 01:59:09 +0000 Subject: [PATCH 3/9] update test to use the config --- tests/e2e/General/HTTPTest.php | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/tests/e2e/General/HTTPTest.php b/tests/e2e/General/HTTPTest.php index 56f3cb7fb0..743b7169a8 100644 --- a/tests/e2e/General/HTTPTest.php +++ b/tests/e2e/General/HTTPTest.php @@ -6,6 +6,7 @@ use Tests\E2E\Client; use Tests\E2E\Scopes\ProjectNone; use Tests\E2E\Scopes\Scope; use Tests\E2E\Scopes\SideNone; +use Utopia\Config\Config; class HTTPTest extends Scope { @@ -33,11 +34,16 @@ class HTTPTest extends Scope 'content-type' => 'application/json', ]), []); + $corsConfig = Config::getParam('cors'); + $allowedMethods = \implode(', ', $corsConfig['allowedMethods']); + $allowedHeaders = \implode(', ', $corsConfig['allowedHeaders']); + $exposedHeaders = \implode(', ', $corsConfig['exposedHeaders']); + $this->assertEquals(204, $response['headers']['status-code']); $this->assertEquals('Appwrite', $response['headers']['server']); - $this->assertEquals('GET, POST, PUT, PATCH, DELETE', $response['headers']['access-control-allow-methods']); - $this->assertEquals('Accept, Origin, Cookie, Set-Cookie, Content-Type, Content-Range, X-Appwrite-Project, X-Appwrite-Key, X-Appwrite-Dev-Key, X-Appwrite-Locale, X-Appwrite-Mode, X-Appwrite-JWT, X-Appwrite-Response-Format, X-Appwrite-Timeout, X-Appwrite-ID, X-Appwrite-Timestamp, X-Appwrite-Session, X-Appwrite-Platform, X-SDK-Version, X-SDK-Name, X-SDK-Language, X-SDK-Platform, X-SDK-GraphQL, X-SDK-Profile, Range, Cache-Control, Expires, Pragma, X-Fallback-Cookies, X-Requested-With, X-Forwarded-For, X-Forwarded-User-Agent', $response['headers']['access-control-allow-headers']); - $this->assertEquals('X-Appwrite-Session, X-Fallback-Cookies', $response['headers']['access-control-expose-headers']); + $this->assertEquals($allowedMethods, $response['headers']['access-control-allow-methods']); + $this->assertEquals($allowedHeaders, $response['headers']['access-control-allow-headers']); + $this->assertEquals($exposedHeaders, $response['headers']['access-control-expose-headers']); $this->assertEquals('http://localhost', $response['headers']['access-control-allow-origin']); $this->assertEquals('true', $response['headers']['access-control-allow-credentials']); $this->assertEmpty($response['body']); From 6b8b11e1675e22c31120814c64e4c6d0d570d201 Mon Sep 17 00:00:00 2001 From: Damodar Lohani Date: Wed, 11 Feb 2026 02:00:38 +0000 Subject: [PATCH 4/9] no longer ignore --- tests/e2e/General/HTTPTest.php | 5 ----- 1 file changed, 5 deletions(-) diff --git a/tests/e2e/General/HTTPTest.php b/tests/e2e/General/HTTPTest.php index 743b7169a8..261bab9348 100644 --- a/tests/e2e/General/HTTPTest.php +++ b/tests/e2e/General/HTTPTest.php @@ -19,11 +19,6 @@ class HTTPTest extends Scope $this->client->setEndpoint('http://appwrite.test'); } - /** - * @group ci-ignore - * - * @return void - */ public function testOptions() { /** From cc0d63bf03509c1609b7a19a1075ab06ce96fd8d Mon Sep 17 00:00:00 2001 From: Chirag Aggarwal Date: Tue, 17 Feb 2026 09:57:41 +0530 Subject: [PATCH 5/9] chore: bump storage lib to remove deprecation warnings --- app/controllers/api/migrations.php | 6 +- composer.json | 5 +- composer.lock | 83 +++++++++++-------- .../Modules/Functions/Workers/Screenshots.php | 2 +- .../Modules/Storage/Http/Buckets/Create.php | 2 +- .../Storage/Http/Buckets/Files/Create.php | 6 +- .../Http/Buckets/Files/Download/Get.php | 6 +- .../Http/Buckets/Files/Preview/Get.php | 6 +- .../Storage/Http/Buckets/Files/Push/Get.php | 6 +- .../Storage/Http/Buckets/Files/View/Get.php | 6 +- .../Modules/Storage/Http/Buckets/Update.php | 2 +- src/Appwrite/Platform/Workers/Migrations.php | 2 +- src/Appwrite/Utopia/Response/Model/Bucket.php | 2 +- src/Appwrite/Utopia/Response/Model/File.php | 2 +- 14 files changed, 74 insertions(+), 62 deletions(-) diff --git a/app/controllers/api/migrations.php b/app/controllers/api/migrations.php index 9d5e013cdc..95339feec2 100644 --- a/app/controllers/api/migrations.php +++ b/app/controllers/api/migrations.php @@ -11,6 +11,9 @@ use Appwrite\SDK\Response as SDKResponse; use Appwrite\Utopia\Database\Validator\CompoundUID; use Appwrite\Utopia\Database\Validator\Queries\Migrations; use Appwrite\Utopia\Response; +use Utopia\Compression\Algorithms\GZIP; +use Utopia\Compression\Algorithms\Zstd; +use Utopia\Compression\Compression; use Utopia\Database\Database; use Utopia\Database\Document; use Utopia\Database\Exception\Order as OrderException; @@ -29,9 +32,6 @@ use Utopia\Migration\Sources\Firebase; use Utopia\Migration\Sources\NHost; use Utopia\Migration\Sources\Supabase; use Utopia\Migration\Transfer; -use Utopia\Storage\Compression\Algorithms\GZIP; -use Utopia\Storage\Compression\Algorithms\Zstd; -use Utopia\Storage\Compression\Compression; use Utopia\Storage\Device; use Utopia\System\System; use Utopia\Validator\ArrayList; diff --git a/composer.json b/composer.json index b7d3bc5483..10b202d316 100644 --- a/composer.json +++ b/composer.json @@ -51,6 +51,7 @@ "utopia-php/auth": "0.5.*", "utopia-php/cache": "1.0.*", "utopia-php/cli": "0.22.*", + "utopia-php/compression": "dev-feat-rename-identity-to-none as 0.1.3", "utopia-php/config": "1.*", "utopia-php/console": "0.1.*", "utopia-php/database": "5.*", @@ -65,14 +66,14 @@ "utopia-php/locale": "0.8.*", "utopia-php/logger": "0.6.*", "utopia-php/messaging": "0.20.*", - "utopia-php/migration": "1.6.*", + "utopia-php/migration": "dev-bump-storage-lib as 1.6.0", "utopia-php/platform": "0.7.*", "utopia-php/pools": "1.*", "utopia-php/span": "1.1.*", "utopia-php/preloader": "0.2.*", "utopia-php/queue": "0.15.*", "utopia-php/registry": "0.5.*", - "utopia-php/storage": "0.18.*", + "utopia-php/storage": "1.0.*", "utopia-php/system": "0.10.*", "utopia-php/telemetry": "0.2.*", "utopia-php/vcs": "1.*", diff --git a/composer.lock b/composer.lock index ddc2754e98..03ab95303a 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": "fe847eccf6ba73bfca1e08d26e9fc7ab", + "content-hash": "90a81fe7def09b16d16e279e060376a2", "packages": [ { "name": "adhocore/jwt", @@ -3656,20 +3656,20 @@ }, { "name": "utopia-php/compression", - "version": "0.1.3", + "version": "dev-feat-rename-identity-to-none", "source": { "type": "git", "url": "https://github.com/utopia-php/compression.git", - "reference": "66f093557ba66d98245e562036182016c7dcfe8a" + "reference": "171e37f6fe663991448fcf06acf830f7eb0b05de" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/utopia-php/compression/zipball/66f093557ba66d98245e562036182016c7dcfe8a", - "reference": "66f093557ba66d98245e562036182016c7dcfe8a", + "url": "https://api.github.com/repos/utopia-php/compression/zipball/171e37f6fe663991448fcf06acf830f7eb0b05de", + "reference": "171e37f6fe663991448fcf06acf830f7eb0b05de", "shasum": "" }, "require": { - "php": ">=8.0" + "php": ">=8.1" }, "require-dev": { "laravel/pint": "1.2.*", @@ -3696,9 +3696,9 @@ ], "support": { "issues": "https://github.com/utopia-php/compression/issues", - "source": "https://github.com/utopia-php/compression/tree/0.1.3" + "source": "https://github.com/utopia-php/compression/tree/feat-rename-identity-to-none" }, - "time": "2025-01-15T15:15:51+00:00" + "time": "2026-02-17T05:15:15+00:00" }, { "name": "utopia-php/config", @@ -3797,16 +3797,16 @@ }, { "name": "utopia-php/database", - "version": "5.2.0", + "version": "5.2.1", "source": { "type": "git", "url": "https://github.com/utopia-php/database.git", - "reference": "5c89b39de00f2b3126d0fbbdea36786341293df7" + "reference": "adfdf201144353a1d2ce14bb197ab746079894e0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/utopia-php/database/zipball/5c89b39de00f2b3126d0fbbdea36786341293df7", - "reference": "5c89b39de00f2b3126d0fbbdea36786341293df7", + "url": "https://api.github.com/repos/utopia-php/database/zipball/adfdf201144353a1d2ce14bb197ab746079894e0", + "reference": "adfdf201144353a1d2ce14bb197ab746079894e0", "shasum": "" }, "require": { @@ -3849,9 +3849,9 @@ ], "support": { "issues": "https://github.com/utopia-php/database/issues", - "source": "https://github.com/utopia-php/database/tree/5.2.0" + "source": "https://github.com/utopia-php/database/tree/5.2.1" }, - "time": "2026-02-14T09:37:28+00:00" + "time": "2026-02-16T11:01:13+00:00" }, { "name": "utopia-php/detector", @@ -4464,16 +4464,16 @@ }, { "name": "utopia-php/migration", - "version": "1.6.0", + "version": "dev-bump-storage-lib", "source": { "type": "git", "url": "https://github.com/utopia-php/migration.git", - "reference": "aa07cf9ae8cc4b8df0ab64588e033693b5ad6849" + "reference": "75c9b9ac8ee4827163711e1aedced2bafb8f265b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/utopia-php/migration/zipball/aa07cf9ae8cc4b8df0ab64588e033693b5ad6849", - "reference": "aa07cf9ae8cc4b8df0ab64588e033693b5ad6849", + "url": "https://api.github.com/repos/utopia-php/migration/zipball/75c9b9ac8ee4827163711e1aedced2bafb8f265b", + "reference": "75c9b9ac8ee4827163711e1aedced2bafb8f265b", "shasum": "" }, "require": { @@ -4484,7 +4484,7 @@ "php": ">=8.1", "utopia-php/database": "5.*", "utopia-php/dsn": "0.2.*", - "utopia-php/storage": "0.18.*" + "utopia-php/storage": "1.0.*" }, "require-dev": { "ext-pdo": "*", @@ -4513,9 +4513,9 @@ ], "support": { "issues": "https://github.com/utopia-php/migration/issues", - "source": "https://github.com/utopia-php/migration/tree/1.6.0" + "source": "https://github.com/utopia-php/migration/tree/bump-storage-lib" }, - "time": "2026-02-16T07:19:27+00:00" + "time": "2026-02-17T05:24:05+00:00" }, { "name": "utopia-php/mongo", @@ -4953,32 +4953,27 @@ }, { "name": "utopia-php/storage", - "version": "0.18.19", + "version": "1.0.0", "source": { "type": "git", "url": "https://github.com/utopia-php/storage.git", - "reference": "9c3f9a471250d22de7d405ee19e23e72b14181ca" + "reference": "f672e8865938e5d1d6dc3bd149ceba4e5582199e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/utopia-php/storage/zipball/9c3f9a471250d22de7d405ee19e23e72b14181ca", - "reference": "9c3f9a471250d22de7d405ee19e23e72b14181ca", + "url": "https://api.github.com/repos/utopia-php/storage/zipball/f672e8865938e5d1d6dc3bd149ceba4e5582199e", + "reference": "f672e8865938e5d1d6dc3bd149ceba4e5582199e", "shasum": "" }, "require": { - "ext-brotli": "*", "ext-curl": "*", "ext-fileinfo": "*", - "ext-lz4": "*", "ext-simplexml": "*", - "ext-snappy": "*", - "ext-xz": "*", "ext-zlib": "*", - "ext-zstd": "*", "php": ">=8.1", - "utopia-php/framework": "0.*.*", "utopia-php/system": "0.*.*", - "utopia-php/telemetry": "0.2.*" + "utopia-php/telemetry": "0.2.*", + "utopia-php/validators": "0.2.*" }, "require-dev": { "laravel/pint": "1.2.*", @@ -5005,9 +5000,9 @@ ], "support": { "issues": "https://github.com/utopia-php/storage/issues", - "source": "https://github.com/utopia-php/storage/tree/0.18.19" + "source": "https://github.com/utopia-php/storage/tree/1.0.0" }, - "time": "2025-12-17T13:55:20+00:00" + "time": "2026-02-17T04:37:10+00:00" }, { "name": "utopia-php/system", @@ -8888,9 +8883,25 @@ "time": "2024-03-07T20:33:40+00:00" } ], - "aliases": [], + "aliases": [ + { + "package": "utopia-php/compression", + "version": "dev-feat-rename-identity-to-none", + "alias": "0.1.3", + "alias_normalized": "0.1.3.0" + }, + { + "package": "utopia-php/migration", + "version": "dev-bump-storage-lib", + "alias": "1.6.0", + "alias_normalized": "1.6.0.0" + } + ], "minimum-stability": "stable", - "stability-flags": [], + "stability-flags": { + "utopia-php/compression": 20, + "utopia-php/migration": 20 + }, "prefer-stable": false, "prefer-lowest": false, "platform": { diff --git a/src/Appwrite/Platform/Modules/Functions/Workers/Screenshots.php b/src/Appwrite/Platform/Modules/Functions/Workers/Screenshots.php index f5f7a7974b..485078af88 100644 --- a/src/Appwrite/Platform/Modules/Functions/Workers/Screenshots.php +++ b/src/Appwrite/Platform/Modules/Functions/Workers/Screenshots.php @@ -7,6 +7,7 @@ use Appwrite\Event\Realtime; use Appwrite\Permission; use Appwrite\Role; use Exception; +use Utopia\Compression\Compression; use Utopia\Config\Config; use Utopia\Console; use Utopia\Database\Database; @@ -16,7 +17,6 @@ use Utopia\Database\Query; use Utopia\Fetch\Client as FetchClient; use Utopia\Platform\Action; use Utopia\Queue\Message; -use Utopia\Storage\Compression\Compression; use Utopia\Storage\Device; use Utopia\System\System; diff --git a/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Create.php b/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Create.php index c78402e5a4..f31d30188a 100644 --- a/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Create.php +++ b/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Create.php @@ -9,6 +9,7 @@ use Appwrite\SDK\Method; use Appwrite\SDK\Response as SDKResponse; use Appwrite\Utopia\Database\Validator\CustomId; use Appwrite\Utopia\Response; +use Utopia\Compression\Compression; use Utopia\Config\Config; use Utopia\Database\Database; use Utopia\Database\Document; @@ -17,7 +18,6 @@ use Utopia\Database\Helpers\ID; use Utopia\Database\Helpers\Permission; use Utopia\Platform\Action; use Utopia\Platform\Scope\HTTP; -use Utopia\Storage\Compression\Compression; use Utopia\Storage\Storage; use Utopia\System\System; use Utopia\Validator\ArrayList; diff --git a/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Files/Create.php b/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Files/Create.php index 6473f1058a..827dbc8dd9 100644 --- a/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Files/Create.php +++ b/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Files/Create.php @@ -14,6 +14,9 @@ use Appwrite\SDK\Response as SDKResponse; use Appwrite\Utopia\Database\Documents\User; use Appwrite\Utopia\Database\Validator\CustomId; use Appwrite\Utopia\Response; +use Utopia\Compression\Algorithms\GZIP; +use Utopia\Compression\Algorithms\Zstd; +use Utopia\Compression\Compression; use Utopia\Database\Database; use Utopia\Database\Document; use Utopia\Database\Exception\Duplicate as DuplicateException; @@ -28,9 +31,6 @@ use Utopia\Database\Validator\UID; use Utopia\Http\Adapter\Swoole\Request; use Utopia\Platform\Action; use Utopia\Platform\Scope\HTTP; -use Utopia\Storage\Compression\Algorithms\GZIP; -use Utopia\Storage\Compression\Algorithms\Zstd; -use Utopia\Storage\Compression\Compression; use Utopia\Storage\Device; use Utopia\Storage\Storage; use Utopia\Storage\Validator\File; diff --git a/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Files/Download/Get.php b/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Files/Download/Get.php index 4a52c87238..042ae76565 100644 --- a/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Files/Download/Get.php +++ b/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Files/Download/Get.php @@ -11,6 +11,9 @@ use Appwrite\SDK\MethodType; use Appwrite\SDK\Response as SDKResponse; use Appwrite\Utopia\Database\Documents\User; use Appwrite\Utopia\Response; +use Utopia\Compression\Algorithms\GZIP; +use Utopia\Compression\Algorithms\Zstd; +use Utopia\Compression\Compression; use Utopia\Database\Database; use Utopia\Database\Document; use Utopia\Database\Validator\Authorization; @@ -19,9 +22,6 @@ use Utopia\Database\Validator\UID; use Utopia\Http\Adapter\Swoole\Request; use Utopia\Platform\Action; use Utopia\Platform\Scope\HTTP; -use Utopia\Storage\Compression\Algorithms\GZIP; -use Utopia\Storage\Compression\Algorithms\Zstd; -use Utopia\Storage\Compression\Compression; use Utopia\Storage\Device; use Utopia\System\System; use Utopia\Validator\Text; diff --git a/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Files/Preview/Get.php b/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Files/Preview/Get.php index a53cbb3a52..63a72fc683 100644 --- a/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Files/Preview/Get.php +++ b/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Files/Preview/Get.php @@ -11,6 +11,9 @@ use Appwrite\SDK\MethodType; use Appwrite\SDK\Response as SDKResponse; use Appwrite\Utopia\Database\Documents\User; use Appwrite\Utopia\Response; +use Utopia\Compression\Algorithms\GZIP; +use Utopia\Compression\Algorithms\Zstd; +use Utopia\Compression\Compression; use Utopia\Config\Config; use Utopia\Console; use Utopia\Database\Database; @@ -23,9 +26,6 @@ use Utopia\Http\Adapter\Swoole\Request; use Utopia\Image\Image; use Utopia\Platform\Action; use Utopia\Platform\Scope\HTTP; -use Utopia\Storage\Compression\Algorithms\GZIP; -use Utopia\Storage\Compression\Algorithms\Zstd; -use Utopia\Storage\Compression\Compression; use Utopia\Storage\Device; use Utopia\System\System; use Utopia\Validator\HexColor; diff --git a/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Files/Push/Get.php b/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Files/Push/Get.php index 60846cb546..c475c53d24 100644 --- a/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Files/Push/Get.php +++ b/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Files/Push/Get.php @@ -8,6 +8,9 @@ use Appwrite\Extend\Exception; use Appwrite\OpenSSL\OpenSSL; use Appwrite\Utopia\Database\Documents\User; use Appwrite\Utopia\Response; +use Utopia\Compression\Algorithms\GZIP; +use Utopia\Compression\Algorithms\Zstd; +use Utopia\Compression\Compression; use Utopia\Config\Config; use Utopia\Database\Database; use Utopia\Database\Document; @@ -16,9 +19,6 @@ use Utopia\Database\Validator\UID; use Utopia\Http\Adapter\Swoole\Request; use Utopia\Platform\Action; use Utopia\Platform\Scope\HTTP; -use Utopia\Storage\Compression\Algorithms\GZIP; -use Utopia\Storage\Compression\Algorithms\Zstd; -use Utopia\Storage\Compression\Compression; use Utopia\Storage\Device; use Utopia\System\System; use Utopia\Validator\Text; diff --git a/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Files/View/Get.php b/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Files/View/Get.php index 73e7e58421..cba6c2fa13 100644 --- a/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Files/View/Get.php +++ b/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Files/View/Get.php @@ -11,6 +11,9 @@ use Appwrite\SDK\MethodType; use Appwrite\SDK\Response as SDKResponse; use Appwrite\Utopia\Database\Documents\User; use Appwrite\Utopia\Response; +use Utopia\Compression\Algorithms\GZIP; +use Utopia\Compression\Algorithms\Zstd; +use Utopia\Compression\Compression; use Utopia\Config\Config; use Utopia\Database\Database; use Utopia\Database\Document; @@ -20,9 +23,6 @@ use Utopia\Database\Validator\UID; use Utopia\Http\Adapter\Swoole\Request; use Utopia\Platform\Action; use Utopia\Platform\Scope\HTTP; -use Utopia\Storage\Compression\Algorithms\GZIP; -use Utopia\Storage\Compression\Algorithms\Zstd; -use Utopia\Storage\Compression\Compression; use Utopia\Storage\Device; use Utopia\System\System; use Utopia\Validator\Text; diff --git a/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Update.php b/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Update.php index 9dd5a29967..e4827a6354 100644 --- a/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Update.php +++ b/src/Appwrite/Platform/Modules/Storage/Http/Buckets/Update.php @@ -8,13 +8,13 @@ use Appwrite\SDK\AuthType; use Appwrite\SDK\Method; use Appwrite\SDK\Response as SDKResponse; use Appwrite\Utopia\Response; +use Utopia\Compression\Compression; use Utopia\Database\Database; use Utopia\Database\Helpers\Permission; use Utopia\Database\Validator\Permissions; use Utopia\Database\Validator\UID; use Utopia\Platform\Action; use Utopia\Platform\Scope\HTTP; -use Utopia\Storage\Compression\Compression; use Utopia\Storage\Storage; use Utopia\System\System; use Utopia\Validator\ArrayList; diff --git a/src/Appwrite/Platform/Workers/Migrations.php b/src/Appwrite/Platform/Workers/Migrations.php index 94cbcf341c..5e729af98f 100644 --- a/src/Appwrite/Platform/Workers/Migrations.php +++ b/src/Appwrite/Platform/Workers/Migrations.php @@ -8,6 +8,7 @@ use Appwrite\Event\Realtime; use Appwrite\Event\StatsUsage; use Appwrite\Extend\Exception; use Appwrite\Template\Template; +use Utopia\Compression\Compression; use Utopia\Config\Config; use Utopia\Console; use Utopia\Database\Database; @@ -39,7 +40,6 @@ use Utopia\Migration\Sources\Supabase; use Utopia\Migration\Transfer; use Utopia\Platform\Action; use Utopia\Queue\Message; -use Utopia\Storage\Compression\Compression; use Utopia\Storage\Device; use Utopia\System\System; diff --git a/src/Appwrite/Utopia/Response/Model/Bucket.php b/src/Appwrite/Utopia/Response/Model/Bucket.php index aece4cf850..d66a27be97 100644 --- a/src/Appwrite/Utopia/Response/Model/Bucket.php +++ b/src/Appwrite/Utopia/Response/Model/Bucket.php @@ -4,7 +4,7 @@ namespace Appwrite\Utopia\Response\Model; use Appwrite\Utopia\Response; use Appwrite\Utopia\Response\Model; -use Utopia\Storage\Compression\Compression; +use Utopia\Compression\Compression; class Bucket extends Model { diff --git a/src/Appwrite/Utopia/Response/Model/File.php b/src/Appwrite/Utopia/Response/Model/File.php index c4e36286ea..9b3e6ff618 100644 --- a/src/Appwrite/Utopia/Response/Model/File.php +++ b/src/Appwrite/Utopia/Response/Model/File.php @@ -4,8 +4,8 @@ namespace Appwrite\Utopia\Response\Model; use Appwrite\Utopia\Response; use Appwrite\Utopia\Response\Model; +use Utopia\Compression\Compression; use Utopia\Database\Document; -use Utopia\Storage\Compression\Compression; class File extends Model { From 8639e70ce93b92c494ac4885348a5e6ab59b63bf Mon Sep 17 00:00:00 2001 From: Chirag Aggarwal Date: Tue, 17 Feb 2026 11:25:27 +0530 Subject: [PATCH 6/9] use stable --- composer.json | 4 ++-- composer.lock | 46 +++++++++++++++------------------------------- 2 files changed, 17 insertions(+), 33 deletions(-) diff --git a/composer.json b/composer.json index 10b202d316..ce55926d23 100644 --- a/composer.json +++ b/composer.json @@ -51,7 +51,7 @@ "utopia-php/auth": "0.5.*", "utopia-php/cache": "1.0.*", "utopia-php/cli": "0.22.*", - "utopia-php/compression": "dev-feat-rename-identity-to-none as 0.1.3", + "utopia-php/compression": "0.1.*", "utopia-php/config": "1.*", "utopia-php/console": "0.1.*", "utopia-php/database": "5.*", @@ -66,7 +66,7 @@ "utopia-php/locale": "0.8.*", "utopia-php/logger": "0.6.*", "utopia-php/messaging": "0.20.*", - "utopia-php/migration": "dev-bump-storage-lib as 1.6.0", + "utopia-php/migration": "1.6.*", "utopia-php/platform": "0.7.*", "utopia-php/pools": "1.*", "utopia-php/span": "1.1.*", diff --git a/composer.lock b/composer.lock index 03ab95303a..54e8929825 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": "90a81fe7def09b16d16e279e060376a2", + "content-hash": "dd9887a50fb434887461a99413007573", "packages": [ { "name": "adhocore/jwt", @@ -3656,16 +3656,16 @@ }, { "name": "utopia-php/compression", - "version": "dev-feat-rename-identity-to-none", + "version": "0.1.4", "source": { "type": "git", "url": "https://github.com/utopia-php/compression.git", - "reference": "171e37f6fe663991448fcf06acf830f7eb0b05de" + "reference": "68045cb9d714c1259582d2dfd0e76bd34f83e713" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/utopia-php/compression/zipball/171e37f6fe663991448fcf06acf830f7eb0b05de", - "reference": "171e37f6fe663991448fcf06acf830f7eb0b05de", + "url": "https://api.github.com/repos/utopia-php/compression/zipball/68045cb9d714c1259582d2dfd0e76bd34f83e713", + "reference": "68045cb9d714c1259582d2dfd0e76bd34f83e713", "shasum": "" }, "require": { @@ -3696,9 +3696,9 @@ ], "support": { "issues": "https://github.com/utopia-php/compression/issues", - "source": "https://github.com/utopia-php/compression/tree/feat-rename-identity-to-none" + "source": "https://github.com/utopia-php/compression/tree/0.1.4" }, - "time": "2026-02-17T05:15:15+00:00" + "time": "2026-02-17T05:53:40+00:00" }, { "name": "utopia-php/config", @@ -4464,16 +4464,16 @@ }, { "name": "utopia-php/migration", - "version": "dev-bump-storage-lib", + "version": "1.6.1", "source": { "type": "git", "url": "https://github.com/utopia-php/migration.git", - "reference": "75c9b9ac8ee4827163711e1aedced2bafb8f265b" + "reference": "c5c7544d02d2418536d41050794050132f247d62" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/utopia-php/migration/zipball/75c9b9ac8ee4827163711e1aedced2bafb8f265b", - "reference": "75c9b9ac8ee4827163711e1aedced2bafb8f265b", + "url": "https://api.github.com/repos/utopia-php/migration/zipball/c5c7544d02d2418536d41050794050132f247d62", + "reference": "c5c7544d02d2418536d41050794050132f247d62", "shasum": "" }, "require": { @@ -4513,9 +4513,9 @@ ], "support": { "issues": "https://github.com/utopia-php/migration/issues", - "source": "https://github.com/utopia-php/migration/tree/bump-storage-lib" + "source": "https://github.com/utopia-php/migration/tree/1.6.1" }, - "time": "2026-02-17T05:24:05+00:00" + "time": "2026-02-17T05:49:48+00:00" }, { "name": "utopia-php/mongo", @@ -8883,25 +8883,9 @@ "time": "2024-03-07T20:33:40+00:00" } ], - "aliases": [ - { - "package": "utopia-php/compression", - "version": "dev-feat-rename-identity-to-none", - "alias": "0.1.3", - "alias_normalized": "0.1.3.0" - }, - { - "package": "utopia-php/migration", - "version": "dev-bump-storage-lib", - "alias": "1.6.0", - "alias_normalized": "1.6.0.0" - } - ], + "aliases": [], "minimum-stability": "stable", - "stability-flags": { - "utopia-php/compression": 20, - "utopia-php/migration": 20 - }, + "stability-flags": {}, "prefer-stable": false, "prefer-lowest": false, "platform": { From 9b4eefc72455c5f749c3f77512862edd46ca964e Mon Sep 17 00:00:00 2001 From: Jake Barnby Date: Tue, 17 Feb 2026 19:00:26 +1300 Subject: [PATCH 7/9] Allow resourceId/resourceType filtering --- src/Appwrite/Utopia/Database/Validator/Queries/Migrations.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/Appwrite/Utopia/Database/Validator/Queries/Migrations.php b/src/Appwrite/Utopia/Database/Validator/Queries/Migrations.php index 436a95534b..c49788872e 100644 --- a/src/Appwrite/Utopia/Database/Validator/Queries/Migrations.php +++ b/src/Appwrite/Utopia/Database/Validator/Queries/Migrations.php @@ -10,6 +10,8 @@ class Migrations extends Base 'source', 'destination', 'resources', + 'resourceId', + 'resourceType', 'statusCounters', 'resourceData', 'errors' From bfecddcc9ae5d1da7790479460c72bc6e70bb1b8 Mon Sep 17 00:00:00 2001 From: Atharva Deosthale Date: Tue, 17 Feb 2026 11:38:03 +0530 Subject: [PATCH 8/9] Add status to response model --- src/Appwrite/Utopia/Response/Model/Project.php | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/Appwrite/Utopia/Response/Model/Project.php b/src/Appwrite/Utopia/Response/Model/Project.php index c516aab73f..cd33a29685 100644 --- a/src/Appwrite/Utopia/Response/Model/Project.php +++ b/src/Appwrite/Utopia/Response/Model/Project.php @@ -283,6 +283,12 @@ class Project extends Model 'example' => ['vip'], 'array' => true, ]) + ->addRule('status', [ + 'type' => self::TYPE_STRING, + 'description' => 'Project status.', + 'default' => 'active', + 'example' => 'active', + ]) ; $services = Config::getParam('services', []); From 0844af9c9d0de16273f71fe651063be395bf71e9 Mon Sep 17 00:00:00 2001 From: Atharva Deosthale Date: Tue, 17 Feb 2026 11:54:22 +0530 Subject: [PATCH 9/9] add tests --- tests/e2e/Services/Projects/ProjectsConsoleClientTest.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/e2e/Services/Projects/ProjectsConsoleClientTest.php b/tests/e2e/Services/Projects/ProjectsConsoleClientTest.php index 1d15f10971..e6cb871f52 100644 --- a/tests/e2e/Services/Projects/ProjectsConsoleClientTest.php +++ b/tests/e2e/Services/Projects/ProjectsConsoleClientTest.php @@ -57,6 +57,7 @@ class ProjectsConsoleClientTest extends Scope $this->assertNotEmpty($response['body']['$id']); $this->assertEquals('Project Test', $response['body']['name']); $this->assertEquals($team['body']['$id'], $response['body']['teamId']); + $this->assertEquals(PROJECT_STATUS_ACTIVE, $response['body']['status']); $this->assertArrayHasKey('platforms', $response['body']); $this->assertArrayHasKey('webhooks', $response['body']); $this->assertArrayHasKey('keys', $response['body']); @@ -76,6 +77,7 @@ class ProjectsConsoleClientTest extends Scope $this->assertNotEmpty($response['body']['$id']); $this->assertEquals('Project Test', $response['body']['name']); $this->assertEquals($team['body']['$id'], $response['body']['teamId']); + $this->assertEquals(PROJECT_STATUS_ACTIVE, $response['body']['status']); $this->assertArrayHasKey('platforms', $response['body']); $this->assertArrayHasKey('webhooks', $response['body']); $this->assertArrayHasKey('keys', $response['body']);