From c882fd4bf270829e914e0b428a26cbcdcf8e2517 Mon Sep 17 00:00:00 2001 From: Seifane Idouchach Date: Thu, 26 Dec 2024 15:21:27 +0800 Subject: [PATCH 1/9] Fix types for Paginator --- src/Mappers/PaginatorTypeMapper.php | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/Mappers/PaginatorTypeMapper.php b/src/Mappers/PaginatorTypeMapper.php index e110a77..5f9ef02 100644 --- a/src/Mappers/PaginatorTypeMapper.php +++ b/src/Mappers/PaginatorTypeMapper.php @@ -104,54 +104,54 @@ private function getObjectType(bool $countable, OutputType $subType): MutableInt 'firstItem' => [ 'type' => Type::int(), 'description' => 'Get the "index" of the first item being paginated.', - 'resolve' => static function (Paginator $root): int { + 'resolve' => static function (Paginator $root): ?int { return $root->firstItem(); }, ], 'lastItem' => [ 'type' => Type::int(), 'description' => 'Get the "index" of the last item being paginated.', - 'resolve' => static function (Paginator $root): int { + 'resolve' => static function (Paginator $root): ?int { return $root->lastItem(); }, ], 'hasMorePages' => [ - 'type' => Type::boolean(), + 'type' => Type::nonNull(Type::boolean()), 'description' => 'Determine if there are more items in the data source.', 'resolve' => static function (Paginator $root): bool { return $root->hasMorePages(); }, ], 'perPage' => [ - 'type' => Type::int(), + 'type' => Type::nonNull(Type::int()), 'description' => 'Get the number of items shown per page.', 'resolve' => static function (Paginator $root): int { return $root->perPage(); }, ], 'hasPages' => [ - 'type' => Type::boolean(), + 'type' => Type::nonNull(Type::boolean()), 'description' => 'Determine if there are enough items to split into multiple pages.', 'resolve' => static function (Paginator $root): bool { return $root->hasPages(); }, ], 'currentPage' => [ - 'type' => Type::int(), + 'type' => Type::nonNull(Type::int()), 'description' => 'Determine the current page being paginated.', 'resolve' => static function (Paginator $root): int { return $root->currentPage(); }, ], 'isEmpty' => [ - 'type' => Type::boolean(), + 'type' => Type::nonNull(Type::boolean()), 'description' => 'Determine if the list of items is empty or not.', 'resolve' => static function (Paginator $root): bool { return $root->isEmpty(); }, ], 'isNotEmpty' => [ - 'type' => Type::boolean(), + 'type' => Type::nonNull(Type::boolean()), 'description' => 'Determine if the list of items is not empty.', 'resolve' => static function (Paginator $root): bool { return $root->isNotEmpty(); From a8aa501c09c46321203ceb4336373e29f150fdad Mon Sep 17 00:00:00 2001 From: Seifane Idouchach Date: Thu, 26 Dec 2024 15:24:51 +0800 Subject: [PATCH 2/9] Fix types for Paginator --- src/Mappers/PaginatorTypeMapper.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Mappers/PaginatorTypeMapper.php b/src/Mappers/PaginatorTypeMapper.php index 5f9ef02..b242c5f 100644 --- a/src/Mappers/PaginatorTypeMapper.php +++ b/src/Mappers/PaginatorTypeMapper.php @@ -161,13 +161,13 @@ private function getObjectType(bool $countable, OutputType $subType): MutableInt if ($countable) { $fields['totalCount'] = [ - 'type' => Type::int(), + 'type' => Type::nonNull(Type::int()), 'description' => 'The total count of items.', 'resolve' => static function (LengthAwarePaginator $root): int { return $root->total(); }]; $fields['lastPage'] = [ - 'type' => Type::int(), + 'type' => Type::nonNull(Type::int()), 'description' => 'Get the page number of the last available page.', 'resolve' => static function (LengthAwarePaginator $root): int { return $root->lastPage(); From ebeb80e9b308b368af1e1d70d592c903d001e47c Mon Sep 17 00:00:00 2001 From: Seifane Idouchach Date: Tue, 5 Aug 2025 08:21:47 +0800 Subject: [PATCH 3/9] Fix SanePsr11ContainerAdapter --- composer.json | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/composer.json b/composer.json index c6e7eb1..22769af 100644 --- a/composer.json +++ b/composer.json @@ -22,10 +22,10 @@ "require": { "php": "^8.1", "thecodingmachine/graphqlite": "^v6.2.1", - "illuminate/console": "^9 || ^10 | ^11", - "illuminate/container": "^9 || ^10 | ^11", - "illuminate/support": "^9 || ^10 | ^11", - "illuminate/cache": "^9 || ^10 | ^11", + "illuminate/console": "^9 || ^10 | ^11 | ^12", + "illuminate/container": "^9 || ^10 | ^11 | ^12", + "illuminate/support": "^9 || ^10 | ^11 | ^12", + "illuminate/cache": "^9 || ^10 | ^11 | ^12", "symfony/psr-http-message-bridge": "^1.3.0 || ^2 || ^6", "laminas/laminas-diactoros": "^2.2.2", "symfony/cache": "^4.3 || ^5 || ^6", From 7fb82b12478297cf65b49b4a9c59802244fedc52 Mon Sep 17 00:00:00 2001 From: Seifane Idouchach Date: Tue, 5 Aug 2025 08:24:36 +0800 Subject: [PATCH 4/9] upgrade --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 22769af..bc6848a 100644 --- a/composer.json +++ b/composer.json @@ -26,7 +26,7 @@ "illuminate/container": "^9 || ^10 | ^11 | ^12", "illuminate/support": "^9 || ^10 | ^11 | ^12", "illuminate/cache": "^9 || ^10 | ^11 | ^12", - "symfony/psr-http-message-bridge": "^1.3.0 || ^2 || ^6", + "symfony/psr-http-message-bridge": "^1.3.0 || ^2 || ^6 || ^7", "laminas/laminas-diactoros": "^2.2.2", "symfony/cache": "^4.3 || ^5 || ^6", "psr/container": "^2.0.2" From 8225132b00378e973e65049f6b9552b2cc455269 Mon Sep 17 00:00:00 2001 From: Seifane Idouchach Date: Tue, 5 Aug 2025 08:29:18 +0800 Subject: [PATCH 5/9] upgrade --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index bc6848a..bffb0a2 100644 --- a/composer.json +++ b/composer.json @@ -27,7 +27,7 @@ "illuminate/support": "^9 || ^10 | ^11 | ^12", "illuminate/cache": "^9 || ^10 | ^11 | ^12", "symfony/psr-http-message-bridge": "^1.3.0 || ^2 || ^6 || ^7", - "laminas/laminas-diactoros": "^2.2.2", + "laminas/laminas-diactoros": "3.0.0", "symfony/cache": "^4.3 || ^5 || ^6", "psr/container": "^2.0.2" }, From e9c797b3b263d463b2484f7792fa7a284be228c2 Mon Sep 17 00:00:00 2001 From: Seifane Idouchach Date: Tue, 5 Aug 2025 08:29:44 +0800 Subject: [PATCH 6/9] upgrade --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index bffb0a2..f6847bd 100644 --- a/composer.json +++ b/composer.json @@ -27,7 +27,7 @@ "illuminate/support": "^9 || ^10 | ^11 | ^12", "illuminate/cache": "^9 || ^10 | ^11 | ^12", "symfony/psr-http-message-bridge": "^1.3.0 || ^2 || ^6 || ^7", - "laminas/laminas-diactoros": "3.0.0", + "laminas/laminas-diactoros": "3.2.0", "symfony/cache": "^4.3 || ^5 || ^6", "psr/container": "^2.0.2" }, From 359ccfb2ca88f613e63ca7d103f06c5657326e8e Mon Sep 17 00:00:00 2001 From: Seifane Idouchach Date: Tue, 5 Aug 2025 08:34:15 +0800 Subject: [PATCH 7/9] upgrade --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index f6847bd..bb3fa41 100644 --- a/composer.json +++ b/composer.json @@ -21,7 +21,7 @@ }, "require": { "php": "^8.1", - "thecodingmachine/graphqlite": "^v6.2.1", + "thecodingmachine/graphqlite": "^v7.0.0", "illuminate/console": "^9 || ^10 | ^11 | ^12", "illuminate/container": "^9 || ^10 | ^11 | ^12", "illuminate/support": "^9 || ^10 | ^11 | ^12", From e0695e4b2d8775cb4eaf14bce46ce067beaa2fa6 Mon Sep 17 00:00:00 2001 From: Seifane Idouchach Date: Tue, 5 Aug 2025 08:35:12 +0800 Subject: [PATCH 8/9] upgrade --- composer.json | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/composer.json b/composer.json index bb3fa41..57975c0 100644 --- a/composer.json +++ b/composer.json @@ -21,7 +21,7 @@ }, "require": { "php": "^8.1", - "thecodingmachine/graphqlite": "^v7.0.0", + "thecodingmachine/graphqlite": "^v8.1.0", "illuminate/console": "^9 || ^10 | ^11 | ^12", "illuminate/container": "^9 || ^10 | ^11 | ^12", "illuminate/support": "^9 || ^10 | ^11 | ^12", @@ -33,7 +33,7 @@ }, "require-dev": { "orchestra/testbench": "^7 || ^8", - "phpunit/phpunit": "^9.6.6 || ^10.0.19", + "phpunit/phpunit": "^9.6.6 || ^10.0.19 || ^11", "ext-sqlite3": "*" }, "autoload": { From b963f951e173afbb9c6012b2e1f5ac86e6502061 Mon Sep 17 00:00:00 2001 From: Seifane Idouchach Date: Thu, 5 Mar 2026 08:49:02 +0800 Subject: [PATCH 9/9] upgrade --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 57975c0..915c2c2 100644 --- a/composer.json +++ b/composer.json @@ -27,7 +27,7 @@ "illuminate/support": "^9 || ^10 | ^11 | ^12", "illuminate/cache": "^9 || ^10 | ^11 | ^12", "symfony/psr-http-message-bridge": "^1.3.0 || ^2 || ^6 || ^7", - "laminas/laminas-diactoros": "3.2.0", + "laminas/laminas-diactoros": "3.8.0", "symfony/cache": "^4.3 || ^5 || ^6", "psr/container": "^2.0.2" },