From f4e67f0a097b5ef638d51aae2d9666976509ef5c Mon Sep 17 00:00:00 2001 From: Brent Shaffer Date: Wed, 13 May 2026 10:58:19 -0700 Subject: [PATCH 1/3] fix: add php 7.4 compatibility to v1.34.1 --- composer.json | 6 +++--- src/Serializer.php | 2 +- tests/Tests/Unit/testdata/src/CustomOperationClient.php | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/composer.json b/composer.json index 2806aeb22..8f42af19e 100644 --- a/composer.json +++ b/composer.json @@ -6,15 +6,15 @@ "homepage": "https://github.com/googleapis/gax-php", "license": "BSD-3-Clause", "require": { - "php": "^8.0", + "php": "^7.4", "google/auth": "^1.34.0", - "google/grpc-gcp": "^0.4", + "google/grpc-gcp": "^0.3.0", "grpc/grpc": "^1.13", "google/protobuf": "^v3.25.3||^4.26.1", "guzzlehttp/promises": "^2.0", "guzzlehttp/psr7": "^2.0", "google/common-protos": "^4.4", - "google/longrunning": "~0.4", + "google/longrunning": "^0.4", "ramsey/uuid": "^4.0" }, "require-dev": { diff --git a/src/Serializer.php b/src/Serializer.php index 1c39ced47..5bb49d032 100644 --- a/src/Serializer.php +++ b/src/Serializer.php @@ -90,7 +90,7 @@ public function __construct( $messageTypeTransformers = [], $decodeFieldTransformers = [], $decodeMessageTypeTransformers = [], - $customEncoders = [], + $customEncoders = [] ) { $this->fieldTransformers = $fieldTransformers; $this->messageTypeTransformers = $messageTypeTransformers; diff --git a/tests/Tests/Unit/testdata/src/CustomOperationClient.php b/tests/Tests/Unit/testdata/src/CustomOperationClient.php index 75b412bc1..943b907e8 100644 --- a/tests/Tests/Unit/testdata/src/CustomOperationClient.php +++ b/tests/Tests/Unit/testdata/src/CustomOperationClient.php @@ -27,7 +27,7 @@ abstract class BaseOperationRequest public string $arg2; public string $arg3; - public static function build(string $name, string $arg2, string $arg3): static + public static function build(string $name, string $arg2, string $arg3) { $request = new static(); $request->name = $name; From 4777c146280ebab31045ba6d5d35e2424fea534e Mon Sep 17 00:00:00 2001 From: Brent Shaffer Date: Wed, 13 May 2026 11:10:26 -0700 Subject: [PATCH 2/3] add 7.4 to unit tests --- .github/workflows/tests.yml | 4 ++-- composer.json | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index cd54d4dd4..f6add1638 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -11,12 +11,12 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - php: [ "8.0", "8.1", "8.2", "8.3" ] + php: [ "7.4", "8.0", "8.1", "8.2", "8.3", "8.4", "8.5" ] extensions: [""] tools: [""] composerflags: [""] include: - - php: "8.0" + - php: "7.4" extensions: "protobuf,grpc" tools: "pecl" - php: "8.3" diff --git a/composer.json b/composer.json index 8f42af19e..f0497541c 100644 --- a/composer.json +++ b/composer.json @@ -6,7 +6,7 @@ "homepage": "https://github.com/googleapis/gax-php", "license": "BSD-3-Clause", "require": { - "php": "^7.4", + "php": "^7.4||^8.0", "google/auth": "^1.34.0", "google/grpc-gcp": "^0.3.0", "grpc/grpc": "^1.13", From eddd31c8004e0ce4503840ff327de126f0db2048 Mon Sep 17 00:00:00 2001 From: Brent Shaffer Date: Wed, 13 May 2026 11:30:33 -0700 Subject: [PATCH 3/3] configure block-insecure to false --- composer.json | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/composer.json b/composer.json index f0497541c..5dc2c9c3d 100644 --- a/composer.json +++ b/composer.json @@ -44,5 +44,10 @@ "test": "./vendor/bin/phpunit", "cs-lint": "vendor/bin/phpcs --standard=./ruleset.xml", "cs-fix": "vendor/bin/phpcbf --standard=./ruleset.xml" + }, + "config": { + "audit": { + "block-insecure": false + } } }