From 2b206d581b60b7cb9d88b0c049af7f51a18abd3e Mon Sep 17 00:00:00 2001 From: Brent Shaffer Date: Mon, 18 Dec 2023 10:50:03 -0800 Subject: [PATCH 01/17] chore(tests): add CI for checking lowest version of dependencies --- .github/run-package-tests.sh | 19 ++++++++++++++----- .github/workflows/tests.yaml | 13 +++++++++++++ 2 files changed, 27 insertions(+), 5 deletions(-) diff --git a/.github/run-package-tests.sh b/.github/run-package-tests.sh index 4a4245e1a653..badddff4db99 100644 --- a/.github/run-package-tests.sh +++ b/.github/run-package-tests.sh @@ -13,12 +13,18 @@ # See the License for the specific language governing permissions and # limitations under the License. -# first argument can be a directory DIRS=$(find * -maxdepth 0 -type d -name '[A-Z]*') +PREFER_LOWEST="" +VALID=1 if [ "$#" -eq 1 ]; then - DIRS=$1 + # first argument can be a directory or "--prefer-lowest" + if [ "$1" = "--prefer-lowest" ]; then + PREFER_LOWEST="--prefer-lowest" + else + DIRS=$1 + fi elif [ "$#" -ne 0 ]; then - echo "usage: run-package-tests.sh [DIR]" + echo "usage: run-package-tests.sh [DIR|--prefer-lowest]" exit 1; fi @@ -38,11 +44,14 @@ for DIR in ${DIRS}; do { done echo "Installing composer in $DIR" - COMPOSER_ROOT_VERSION=$(cat $DIR/VERSION) composer -q --no-interaction --no-ansi --no-progress update -d ${DIR}; + if [ "$PREFER_LOWEST" != "" ]; then + echo " (with $PREFER_LOWEST)" + fi + COMPOSER_ROOT_VERSION=$(cat $DIR/VERSION) composer -q --no-interaction --no-ansi --no-progress $PREFER_LOWEST update -d ${DIR}; if [ $? != 0 ]; then echo "$DIR: composer install failed" >> "${FAILED_FILE}" # run again but without "-q" so we can see the error - COMPOSER_ROOT_VERSION=$(cat $DIR/VERSION) composer --no-interaction --no-ansi --no-progress update -d ${DIR}; + COMPOSER_ROOT_VERSION=$(cat $DIR/VERSION) composer --no-interaction --no-ansi --no-progress $PREFER_LOWEST update -d ${DIR}; continue fi echo "Running $DIR Unit Tests" diff --git a/.github/workflows/tests.yaml b/.github/workflows/tests.yaml index 0e5820a99561..717545e666fe 100644 --- a/.github/workflows/tests.yaml +++ b/.github/workflows/tests.yaml @@ -80,6 +80,19 @@ jobs: - name: Run Package Test Suites run: bash .github/run-package-tests.sh + test_packages_lowest: + name: Package Tests (Lowest Dependencies) + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: Setup PHP + uses: shivammathur/setup-php@verbose + with: + php-version: '8.1' + extensions: grpc + - name: Run Package Test Suites + run: bash .github/run-package-tests.sh --prefer-lowest + test_dev_commands: name: Dev Commands Unit Tests runs-on: ubuntu-latest From 7801ffa874713d1acff8c023ac428d0870309f06 Mon Sep 17 00:00:00 2001 From: Brent Shaffer Date: Mon, 18 Dec 2023 11:29:44 -0800 Subject: [PATCH 02/17] update dev deps --- composer.json | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/composer.json b/composer.json index 42944e9e58aa..67eaa9620155 100644 --- a/composer.json +++ b/composer.json @@ -46,8 +46,8 @@ "php": ">=7.4", "rize/uri-template": "~0.3", "guzzlehttp/guzzle": "^6.5.8|^7.4.4", - "guzzlehttp/psr7": "^1.7|^2.0", - "monolog/monolog": "^2.0||^3.0", + "guzzlehttp/psr7": "^2.6", + "monolog/monolog": "^2.9||^3.0", "psr/http-message": "^1.0|^2.0", "ramsey/uuid": "^4.0", "google/gax": "^1.24.0", @@ -55,15 +55,16 @@ "google/auth": "^1.18" }, "require-dev": { - "phpunit/phpunit": "^9.0", + "phpunit/phpunit": "^9.6", "phpdocumentor/reflection": "^5.0", "erusev/parsedown": "^1.6", "phpseclib/phpseclib": "^3.0", "google/cloud-tools": "^0.13.0", "opis/closure": "^3.0", "flix-tech/avro-php": "^5.0.0", - "phpspec/prophecy-phpunit": "^2.0", - "kreait/firebase-php": "^5.26.5" + "phpspec/prophecy-phpunit": "^2.1", + "kreait/firebase-php": "^5.26.5", + "psr/log": "^1.1.1 || 2.0" }, "conflict": { "psr/log": ">=3" From e632142c5b0b06177000a21f03a871336c559ae7 Mon Sep 17 00:00:00 2001 From: Brent Shaffer Date: Mon, 18 Dec 2023 12:14:40 -0800 Subject: [PATCH 03/17] update all packages for tests to pass --- .github/run-package-tests.sh | 9 +++++++++ BigQuery/composer.json | 3 ++- Bigtable/composer.json | 3 ++- Channel/composer.json | 3 ++- Core/composer.json | 7 ++++--- Datastore/composer.json | 3 ++- Debugger/composer.json | 3 ++- Firestore/composer.json | 3 ++- Logging/composer.json | 6 ++++-- LongRunning/composer.json | 3 ++- PubSub/composer.json | 3 ++- Spanner/composer.json | 3 ++- Speech/composer.json | 3 ++- Storage/composer.json | 3 ++- Trace/composer.json | 3 ++- Translate/composer.json | 3 ++- Vision/composer.json | 3 ++- 17 files changed, 45 insertions(+), 19 deletions(-) diff --git a/.github/run-package-tests.sh b/.github/run-package-tests.sh index badddff4db99..987711339062 100644 --- a/.github/run-package-tests.sh +++ b/.github/run-package-tests.sh @@ -23,6 +23,15 @@ if [ "$#" -eq 1 ]; then else DIRS=$1 fi +elif [ "$#" -eq 2 ]; then + # first argument can be a directory or "--prefer-lowest" + if [ "$2" = "--prefer-lowest" ]; then + DIRS=$1 + PREFER_LOWEST="--prefer-lowest" + else + echo "usage: run-package-tests.sh [DIR|--prefer-lowest]" + exit 1; + fi elif [ "$#" -ne 0 ]; then echo "usage: run-package-tests.sh [DIR|--prefer-lowest]" exit 1; diff --git a/BigQuery/composer.json b/BigQuery/composer.json index 6e654b2040f7..f43f0eb13344 100644 --- a/BigQuery/composer.json +++ b/BigQuery/composer.json @@ -12,7 +12,8 @@ "phpunit/phpunit": "^9.0", "phpspec/prophecy-phpunit": "^2.0", "squizlabs/php_codesniffer": "2.*", - "phpdocumentor/reflection": "^5.0", + "phpdocumentor/reflection": "^5.3.3", + "phpdocumentor/reflection-docblock": "^5.3", "erusev/parsedown": "^1.6", "google/cloud-storage": "^1.3" }, diff --git a/Bigtable/composer.json b/Bigtable/composer.json index da2ce80851c3..e8146301e7f5 100644 --- a/Bigtable/composer.json +++ b/Bigtable/composer.json @@ -11,7 +11,8 @@ "require-dev": { "phpunit/phpunit": "^9.0", "erusev/parsedown": "^1.6", - "phpdocumentor/reflection": "^5.0", + "phpdocumentor/reflection": "^5.3.3", + "phpdocumentor/reflection-docblock": "^5.3", "phpspec/prophecy-phpunit": "^2.0" }, "suggest": { diff --git a/Channel/composer.json b/Channel/composer.json index 501f7dc4d348..7c25cc32e39b 100644 --- a/Channel/composer.json +++ b/Channel/composer.json @@ -27,7 +27,8 @@ "google/gax": "^1.24.0" }, "require-dev": { - "phpunit/phpunit": "^9.0" + "phpunit/phpunit": "^9.0", + "google/common-protos": "^3.2||^4.0" }, "suggest": { "ext-grpc": "Enables use of gRPC, a universal high-performance RPC framework created by Google.", diff --git a/Core/composer.json b/Core/composer.json index 63aff87d114c..839327268519 100644 --- a/Core/composer.json +++ b/Core/composer.json @@ -9,15 +9,16 @@ "google/auth": "^1.18", "guzzlehttp/guzzle": "^6.5.8|^7.4.4", "guzzlehttp/promises": "^1.4||^2.0", - "guzzlehttp/psr7": "^1.7|^2.0", - "monolog/monolog": "^1.1|^2.0|^3.0", + "guzzlehttp/psr7": "^2.6", + "monolog/monolog": "^2.9|^3.0", "psr/http-message": "^1.0|^2.0" }, "require-dev": { "phpunit/phpunit": "^9.0", "phpspec/prophecy-phpunit": "^2.0", "squizlabs/php_codesniffer": "2.*", - "phpdocumentor/reflection": "^5.0", + "phpdocumentor/reflection": "^5.3.3", + "phpdocumentor/reflection-docblock": "^5.3", "erusev/parsedown": "^1.6", "google/gax": "^1.24.0", "opis/closure": "^3", diff --git a/Datastore/composer.json b/Datastore/composer.json index 73fab4abd097..c56a4de071ba 100644 --- a/Datastore/composer.json +++ b/Datastore/composer.json @@ -12,7 +12,8 @@ "phpunit/phpunit": "^9.0", "phpspec/prophecy-phpunit": "^2.0", "squizlabs/php_codesniffer": "2.*", - "phpdocumentor/reflection": "^5.0", + "phpdocumentor/reflection": "^5.3.3", + "phpdocumentor/reflection-docblock": "^5.3", "erusev/parsedown": "^1.6" }, "extra": { diff --git a/Debugger/composer.json b/Debugger/composer.json index 2ecbf79454df..b116d3754ac4 100644 --- a/Debugger/composer.json +++ b/Debugger/composer.json @@ -15,7 +15,8 @@ "phpunit/phpunit": "^9.0", "phpspec/prophecy-phpunit": "^2.0", "squizlabs/php_codesniffer": "2.*", - "phpdocumentor/reflection": "^5.0", + "phpdocumentor/reflection": "^5.3.3", + "phpdocumentor/reflection-docblock": "^5.3", "erusev/parsedown": "^1.6", "google/cloud-tools": "^0.13.0", "kreait/firebase-php": "^5.26.5" diff --git a/Firestore/composer.json b/Firestore/composer.json index 19c7bfe6d850..ac6dd3dcd901 100644 --- a/Firestore/composer.json +++ b/Firestore/composer.json @@ -14,7 +14,8 @@ "phpunit/phpunit": "^9.0", "phpspec/prophecy-phpunit": "^2.0", "squizlabs/php_codesniffer": "2.*", - "phpdocumentor/reflection": "^5.0", + "phpdocumentor/reflection": "^5.3.3", + "phpdocumentor/reflection-docblock": "^5.3", "erusev/parsedown": "^1.6" }, "suggest": { diff --git a/Logging/composer.json b/Logging/composer.json index c0108d0311a2..446912267dfa 100644 --- a/Logging/composer.json +++ b/Logging/composer.json @@ -12,13 +12,15 @@ "phpunit/phpunit": "^9.0", "phpspec/prophecy-phpunit": "^2.0", "squizlabs/php_codesniffer": "2.*", - "phpdocumentor/reflection": "^5.0", + "phpdocumentor/reflection": "^5.3.3", + "phpdocumentor/reflection-docblock": "^5.3", "erusev/parsedown": "^1.6", "fig/log-test": "^1.0", "google/cloud-storage": "^1.3", "google/cloud-bigquery": "^1.0", "google/cloud-pubsub": "^1.0", - "opis/closure": "^3" + "opis/closure": "^3", + "monolog/monolog": "^2.9|3.0" }, "provide": { "psr/log-implementation": "1.0|2.0" diff --git a/LongRunning/composer.json b/LongRunning/composer.json index ac3dc391e4f3..ff165d988630 100644 --- a/LongRunning/composer.json +++ b/LongRunning/composer.json @@ -20,6 +20,7 @@ }, "require-dev": { "google/gax": "^1.13.0", - "phpunit/phpunit": "^9.0" + "phpunit/phpunit": "^9.0", + "google/common-protos": "^2.2" } } diff --git a/PubSub/composer.json b/PubSub/composer.json index 716334f0b1ee..3ccf2529be11 100644 --- a/PubSub/composer.json +++ b/PubSub/composer.json @@ -12,7 +12,8 @@ "phpunit/phpunit": "^9.0", "phpspec/prophecy-phpunit": "^2.0", "squizlabs/php_codesniffer": "2.*", - "phpdocumentor/reflection": "^5.0", + "phpdocumentor/reflection": "^5.3.3", + "phpdocumentor/reflection-docblock": "^5.3", "erusev/parsedown": "^1.6", "flix-tech/avro-php": "^5.0.0" }, diff --git a/Spanner/composer.json b/Spanner/composer.json index 6ec6ebb1a696..f3d9f9e936ae 100644 --- a/Spanner/composer.json +++ b/Spanner/composer.json @@ -13,7 +13,8 @@ "phpunit/phpunit": "^9.0", "phpspec/prophecy-phpunit": "^2.0", "squizlabs/php_codesniffer": "2.*", - "phpdocumentor/reflection": "^5.0", + "phpdocumentor/reflection": "^5.3.3", + "phpdocumentor/reflection-docblock": "^5.3", "erusev/parsedown": "^1.6", "google/cloud-pubsub": "^1.0" }, diff --git a/Speech/composer.json b/Speech/composer.json index e3a56f32b3ea..7072d8e02238 100644 --- a/Speech/composer.json +++ b/Speech/composer.json @@ -12,7 +12,8 @@ "phpunit/phpunit": "^9.0", "phpspec/prophecy-phpunit": "^2.0", "squizlabs/php_codesniffer": "2.*", - "phpdocumentor/reflection": "^5.0", + "phpdocumentor/reflection": "^5.3.3", + "phpdocumentor/reflection-docblock": "^5.3", "erusev/parsedown": "^1.6", "google/cloud-storage": "^1.3" }, diff --git a/Storage/composer.json b/Storage/composer.json index a5d1195dbe0d..ed676d21c47e 100644 --- a/Storage/composer.json +++ b/Storage/composer.json @@ -12,7 +12,8 @@ "phpunit/phpunit": "^9.0", "phpspec/prophecy-phpunit": "^2.0", "squizlabs/php_codesniffer": "2.*", - "phpdocumentor/reflection": "^5.0", + "phpdocumentor/reflection": "^5.3.3", + "phpdocumentor/reflection-docblock": "^5.3", "erusev/parsedown": "^1.6", "phpseclib/phpseclib": "^2.0||^3.0", "google/cloud-pubsub": "^1.0" diff --git a/Trace/composer.json b/Trace/composer.json index a87dd2dc8013..804ed934d907 100644 --- a/Trace/composer.json +++ b/Trace/composer.json @@ -13,7 +13,8 @@ "phpunit/phpunit": "^9.0", "phpspec/prophecy-phpunit": "^2.0", "squizlabs/php_codesniffer": "2.*", - "phpdocumentor/reflection": "^5.0", + "phpdocumentor/reflection": "^5.3.3", + "phpdocumentor/reflection-docblock": "^5.3", "erusev/parsedown": "^1.6" }, "suggest": { diff --git a/Translate/composer.json b/Translate/composer.json index 385bff3b14e1..3c491a1c9f16 100644 --- a/Translate/composer.json +++ b/Translate/composer.json @@ -12,7 +12,8 @@ "phpunit/phpunit": "^9.0", "phpspec/prophecy-phpunit": "^2.0", "squizlabs/php_codesniffer": "2.*", - "phpdocumentor/reflection": "^5.0", + "phpdocumentor/reflection": "^5.3.3", + "phpdocumentor/reflection-docblock": "^5.3", "erusev/parsedown": "^1.6" }, "suggest": { diff --git a/Vision/composer.json b/Vision/composer.json index 4b7e3ef831ce..44e324448a97 100644 --- a/Vision/composer.json +++ b/Vision/composer.json @@ -12,7 +12,8 @@ "phpunit/phpunit": "^9.0", "phpspec/prophecy-phpunit": "^2.0", "squizlabs/php_codesniffer": "2.*", - "phpdocumentor/reflection": "^5.0", + "phpdocumentor/reflection": "^5.3.3", + "phpdocumentor/reflection-docblock": "^5.3", "erusev/parsedown": "^1.6", "google/cloud-storage": "^1.12" }, From 536fa1d0aaeb13559111aa87cc2f77b6e93e95e9 Mon Sep 17 00:00:00 2001 From: Brent Shaffer Date: Mon, 18 Dec 2023 12:16:24 -0800 Subject: [PATCH 04/17] run lowest dependency tests on lowest version of PHP --- .github/workflows/tests.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/tests.yaml b/.github/workflows/tests.yaml index 717545e666fe..3b7718298c80 100644 --- a/.github/workflows/tests.yaml +++ b/.github/workflows/tests.yaml @@ -88,7 +88,7 @@ jobs: - name: Setup PHP uses: shivammathur/setup-php@verbose with: - php-version: '8.1' + php-version: '7.4' extensions: grpc - name: Run Package Test Suites run: bash .github/run-package-tests.sh --prefer-lowest From c8ebc75d5d7cb203ab1e4ab6ce90b2fd4e6bd8d8 Mon Sep 17 00:00:00 2001 From: Brent Shaffer Date: Mon, 18 Dec 2023 12:25:02 -0800 Subject: [PATCH 05/17] fix language --- Language/composer.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Language/composer.json b/Language/composer.json index 4deb31e27581..194781cca483 100644 --- a/Language/composer.json +++ b/Language/composer.json @@ -12,7 +12,8 @@ "phpunit/phpunit": "^9.0", "phpspec/prophecy-phpunit": "^2.0", "squizlabs/php_codesniffer": "2.*", - "phpdocumentor/reflection": "^5.0", + "phpdocumentor/reflection": "^5.3.3", + "phpdocumentor/reflection-docblock": "^5.3", "erusev/parsedown": "^1.6", "google/cloud-storage": "^1.3" }, From cfdcc3a4647b9f4db19a5e97a2ae5c0db04584f8 Mon Sep 17 00:00:00 2001 From: Brent Shaffer Date: Fri, 5 Jan 2024 07:10:10 -0800 Subject: [PATCH 06/17] chore: add Longrunning version to composer.json --- LongRunning/composer.json | 1 + 1 file changed, 1 insertion(+) diff --git a/LongRunning/composer.json b/LongRunning/composer.json index 8f2bbc1ef151..f1e38a81112f 100644 --- a/LongRunning/composer.json +++ b/LongRunning/composer.json @@ -3,6 +3,7 @@ "description": "Google LongRunning Client for PHP", "license": "Apache-2.0", "minimum-stability": "stable", + "version": "0.2.6", "autoload": { "psr-4": { "Google\\ApiCore\\LongRunning\\": "src/ApiCore/LongRunning", From 20df777b15b5119fb01eb173abf9f7d8a12351cf Mon Sep 17 00:00:00 2001 From: Brent Shaffer Date: Fri, 5 Jan 2024 07:13:21 -0800 Subject: [PATCH 07/17] we no longer need COMPOSER_ROOT_VERSION --- .github/run-package-tests.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/run-package-tests.sh b/.github/run-package-tests.sh index 987711339062..2b3246a42081 100644 --- a/.github/run-package-tests.sh +++ b/.github/run-package-tests.sh @@ -56,11 +56,11 @@ for DIR in ${DIRS}; do { if [ "$PREFER_LOWEST" != "" ]; then echo " (with $PREFER_LOWEST)" fi - COMPOSER_ROOT_VERSION=$(cat $DIR/VERSION) composer -q --no-interaction --no-ansi --no-progress $PREFER_LOWEST update -d ${DIR}; + composer -q --no-interaction --no-ansi --no-progress $PREFER_LOWEST update -d ${DIR}; if [ $? != 0 ]; then echo "$DIR: composer install failed" >> "${FAILED_FILE}" # run again but without "-q" so we can see the error - COMPOSER_ROOT_VERSION=$(cat $DIR/VERSION) composer --no-interaction --no-ansi --no-progress $PREFER_LOWEST update -d ${DIR}; + composer --no-interaction --no-ansi --no-progress $PREFER_LOWEST update -d ${DIR}; continue fi echo "Running $DIR Unit Tests" From 7edfbda6c4d4432d6c5b9b936b9afb7653ebd015 Mon Sep 17 00:00:00 2001 From: Brent Shaffer Date: Fri, 5 Jan 2024 07:23:31 -0800 Subject: [PATCH 08/17] remove common protos dep --- LongRunning/composer.json | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/LongRunning/composer.json b/LongRunning/composer.json index f1e38a81112f..31f9737902af 100644 --- a/LongRunning/composer.json +++ b/LongRunning/composer.json @@ -21,7 +21,6 @@ }, "require-dev": { "google/gax": "^1.26.0", - "phpunit/phpunit": "^9.0", - "google/common-protos": "^2.2" + "phpunit/phpunit": "^9.0" } } From e07a9c6af6e02ca539482930cfecf13222121867 Mon Sep 17 00:00:00 2001 From: Brent Shaffer Date: Fri, 5 Jan 2024 07:29:01 -0800 Subject: [PATCH 09/17] define minimum common-protos dep --- AlloyDb/composer.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/AlloyDb/composer.json b/AlloyDb/composer.json index 886e1c46dc8c..6b2c461bd9a6 100644 --- a/AlloyDb/composer.json +++ b/AlloyDb/composer.json @@ -18,7 +18,8 @@ }, "require": { "php": ">=7.4", - "google/gax": "^1.26.0" + "google/gax": "^1.26.0", + "google/common-protos": "^4.4" }, "require-dev": { "phpunit/phpunit": "^9.0" From a82edd8bd51ed2ce9469574863e575e5ca1a0d1f Mon Sep 17 00:00:00 2001 From: Brent Shaffer Date: Fri, 5 Jan 2024 07:33:28 -0800 Subject: [PATCH 10/17] fix usage/comment --- .github/run-package-tests.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/run-package-tests.sh b/.github/run-package-tests.sh index 2b3246a42081..ae502afc8cc9 100644 --- a/.github/run-package-tests.sh +++ b/.github/run-package-tests.sh @@ -24,16 +24,16 @@ if [ "$#" -eq 1 ]; then DIRS=$1 fi elif [ "$#" -eq 2 ]; then - # first argument can be a directory or "--prefer-lowest" + # first argument is a directory, second is "--prefer-lowest" if [ "$2" = "--prefer-lowest" ]; then DIRS=$1 PREFER_LOWEST="--prefer-lowest" else - echo "usage: run-package-tests.sh [DIR|--prefer-lowest]" + echo "usage: run-package-tests.sh [DIR] [--prefer-lowest]" exit 1; fi elif [ "$#" -ne 0 ]; then - echo "usage: run-package-tests.sh [DIR|--prefer-lowest]" + echo "usage: run-package-tests.sh [DIR] [--prefer-lowest]" exit 1; fi From 4f37dfe6332601c483759cc6f0ded5f5805d1cdf Mon Sep 17 00:00:00 2001 From: Brent Shaffer Date: Fri, 5 Jan 2024 09:36:43 -0800 Subject: [PATCH 11/17] Update Channel/composer.json --- Channel/composer.json | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Channel/composer.json b/Channel/composer.json index 3d9885b1be04..16d01f2eddab 100644 --- a/Channel/composer.json +++ b/Channel/composer.json @@ -28,8 +28,7 @@ "google/common-protos": "^3.2||^4.0" }, "require-dev": { - "phpunit/phpunit": "^9.0", - "google/common-protos": "^3.2||^4.0" + "phpunit/phpunit": "^9.0" }, "suggest": { "ext-grpc": "Enables use of gRPC, a universal high-performance RPC framework created by Google.", From 1037149dd0c7874a1e3f3986fae8d26e5b724044 Mon Sep 17 00:00:00 2001 From: Brent Shaffer Date: Mon, 8 Jan 2024 11:21:31 -0800 Subject: [PATCH 12/17] do NOT use local packagess for --prefer-lowest --- .github/run-package-tests.sh | 24 ++++++++++++++---------- 1 file changed, 14 insertions(+), 10 deletions(-) diff --git a/.github/run-package-tests.sh b/.github/run-package-tests.sh index ae502afc8cc9..fd917912b837 100644 --- a/.github/run-package-tests.sh +++ b/.github/run-package-tests.sh @@ -43,19 +43,23 @@ export COMPOSER=composer-local.json FAILED_FILE=$(mktemp -d)/failed for DIR in ${DIRS}; do { cp ${DIR}/composer.json ${DIR}/composer-local.json - # Update composer to use local packages - for i in BigQuery,cloud-bigquery Core,cloud-core Logging,cloud-logging PubSub,cloud-pubsub Storage,cloud-storage ShoppingCommonProtos,shopping-common-protos,0.2; do - IFS=","; set -- $i; - if grep -q "\"google/$2\":" ${DIR}/composer.json; then - if [ -z "$3" ]; then VERSION="1.100"; else VERSION=$3; fi - composer config repositories.$2 "{\"type\": \"path\", \"url\": \"../$1\", \"options\":{\"versions\":{\"google/$2\":\"$VERSION\"}}}" -d ${DIR} - fi - done + if [ "$PREFER_LOWEST" = "" ]; then + # Update composer to use local packages + for i in BigQuery,cloud-bigquery Core,cloud-core Logging,cloud-logging PubSub,cloud-pubsub Storage,cloud-storage ShoppingCommonProtos,shopping-common-protos,0.2; do + IFS=","; set -- $i; + if grep -q "\"google/$2\":" ${DIR}/composer.json; then + if [ -z "$3" ]; then VERSION="1.100"; else VERSION=$3; fi + echo "Use local package $1 as google/$2:$VERSION in $DIR" + composer config repositories.$2 "{\"type\": \"path\", \"url\": \"../$1\", \"options\":{\"versions\":{\"google/$2\":\"$VERSION\"}}}" -d ${DIR} + fi + done + fi - echo "Installing composer in $DIR" + echo -n "Installing composer in $DIR" if [ "$PREFER_LOWEST" != "" ]; then - echo " (with $PREFER_LOWEST)" + echo -n " (with $PREFER_LOWEST)" fi + echo "" composer -q --no-interaction --no-ansi --no-progress $PREFER_LOWEST update -d ${DIR}; if [ $? != 0 ]; then echo "$DIR: composer install failed" >> "${FAILED_FILE}" From ce3372c303851e866f426e0eee628580646add56 Mon Sep 17 00:00:00 2001 From: Brent Shaffer Date: Tue, 9 Jan 2024 07:31:48 -0800 Subject: [PATCH 13/17] fix deps for lowest --- ErrorReporting/composer.json | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/ErrorReporting/composer.json b/ErrorReporting/composer.json index 080ac4308ec1..e6cb54905aae 100644 --- a/ErrorReporting/composer.json +++ b/ErrorReporting/composer.json @@ -5,13 +5,14 @@ "minimum-stability": "stable", "require": { "php": ">=7.4", - "google/cloud-logging": "^1.16", + "google/cloud-logging": "^1.29", "google/gax": "^1.26.0" }, "require-dev": { "phpunit/phpunit": "^9.0", "phpspec/prophecy-phpunit": "^2.0", - "google/cloud-core": "^1.52.7" + "google/cloud-core": "^1.52.7", + "psr/log": " ^2.0" }, "suggest": { "ext-grpc": "The gRPC extension allows more granular control over Error Reporting", From 8f3cdae7dbb2a2a54f5ac538eec7bf0f22dfec0a Mon Sep 17 00:00:00 2001 From: Brent Shaffer Date: Tue, 9 Jan 2024 08:31:00 -0800 Subject: [PATCH 14/17] allow psr/log v1 --- ErrorReporting/composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ErrorReporting/composer.json b/ErrorReporting/composer.json index e6cb54905aae..77858f405cdf 100644 --- a/ErrorReporting/composer.json +++ b/ErrorReporting/composer.json @@ -12,7 +12,7 @@ "phpunit/phpunit": "^9.0", "phpspec/prophecy-phpunit": "^2.0", "google/cloud-core": "^1.52.7", - "psr/log": " ^2.0" + "psr/log": "^1.1.1||^2.0" }, "suggest": { "ext-grpc": "The gRPC extension allows more granular control over Error Reporting", From ce107116616e08527ba6f5a9c10cc77d6edb2f0e Mon Sep 17 00:00:00 2001 From: Brent Shaffer Date: Thu, 18 Jan 2024 07:04:36 -0800 Subject: [PATCH 15/17] fix config deps --- Config/composer.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Config/composer.json b/Config/composer.json index 1da8e42ea8e8..e5902447d8e4 100644 --- a/Config/composer.json +++ b/Config/composer.json @@ -18,7 +18,8 @@ }, "require": { "php": ">=7.4", - "google/gax": "^1.26.0" + "google/gax": "^1.26.0", + "google/common-protos": " ^4.4" }, "require-dev": { "phpunit/phpunit": "^9.0" From 43af413ba8bdb08b7aff06384d5ec606fb19a832 Mon Sep 17 00:00:00 2001 From: Brent Shaffer Date: Thu, 18 Jan 2024 11:56:26 -0800 Subject: [PATCH 16/17] upgrade minimum cloud-common-protos version --- Core/composer.json | 2 +- Debugger/composer.json | 2 +- Filestore/composer.json | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Core/composer.json b/Core/composer.json index 30af2b927d7c..8d9ac6622c4e 100644 --- a/Core/composer.json +++ b/Core/composer.json @@ -22,7 +22,7 @@ "erusev/parsedown": "^1.6", "google/gax": "^1.26.0", "opis/closure": "^3", - "google/cloud-common-protos": "^0.4" + "google/cloud-common-protos": "~0.5" }, "suggest": { "opis/closure": "May be used to serialize closures to process jobs in the batch daemon. Please require version ^3.", diff --git a/Debugger/composer.json b/Debugger/composer.json index 2700a8dd55fc..6a91d944dfc1 100644 --- a/Debugger/composer.json +++ b/Debugger/composer.json @@ -8,7 +8,7 @@ "google/cloud-core": "^1.52.7", "google/cloud-logging": "^1.16", "google/gax": "^1.26.0", - "google/cloud-common-protos": "^0.4", + "google/cloud-common-protos": "~0.5", "psr/log": "^1.0||^2.0" }, "require-dev": { diff --git a/Filestore/composer.json b/Filestore/composer.json index 701e21abbdbd..26e9816e5b5a 100644 --- a/Filestore/composer.json +++ b/Filestore/composer.json @@ -25,7 +25,7 @@ "require": { "php": ">=7.4", "google/gax": "^1.26.0", - "google/cloud-common-protos": "^0.4" + "google/cloud-common-protos": "~0.5" }, "require-dev": { "phpunit/phpunit": "^9.0" From 6c88a2f873e452e1fe911aafa7d9154e457ac930 Mon Sep 17 00:00:00 2001 From: Brent Shaffer Date: Mon, 22 Jan 2024 09:53:05 -0800 Subject: [PATCH 17/17] add vmware common protos --- VmwareEngine/composer.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/VmwareEngine/composer.json b/VmwareEngine/composer.json index d5b30aeb0983..54ccbff88f37 100644 --- a/VmwareEngine/composer.json +++ b/VmwareEngine/composer.json @@ -19,7 +19,8 @@ }, "require": { "php": ">=7.4", - "google/gax": "^1.26.0" + "google/gax": "^1.26.0", + "google/common-protos": "^4.4" }, "require-dev": { "phpunit/phpunit": "^9.0"