From 2f4ea631a84d3d9da7a16f1f5922ceb95a4a62e4 Mon Sep 17 00:00:00 2001 From: "gcf-owl-bot[bot]" <78513119+gcf-owl-bot[bot]@users.noreply.github.com> Date: Thu, 10 Aug 2023 16:16:09 -0700 Subject: [PATCH] chore!: upgrade to node 14 (#807) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * docs: fix node release schedule link Co-authored-by: Jeffrey Rennie Source-Link: https://github.com/googleapis/synthtool/commit/1a2431537d603e95b4b32317fb494542f75a2165 Post-Processor: gcr.io/cloud-devrel-public-resources/owlbot-nodejs:latest@sha256:e08f9a3757808cdaf7a377e962308c65c4d7eff12db206d4fae702dd50d43430 * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md * chore: upgrade to Node 14 * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md --------- Co-authored-by: Owl Bot Co-authored-by: Sofia Leon --- .github/.OwlBot.lock.yaml | 3 ++- .github/workflows/ci.yaml | 2 +- .kokoro/common.cfg | 2 +- .kokoro/continuous/{node12 => node14}/common.cfg | 2 +- .kokoro/continuous/{node12 => node14}/lint.cfg | 0 .../{node12 => node14}/samples-test.cfg | 0 .../{node12 => node14}/system-test.cfg | 0 .kokoro/continuous/{node12 => node14}/test.cfg | 0 .kokoro/presubmit/{node12 => node14}/common.cfg | 2 +- .../{node12 => node14}/samples-test.cfg | 0 .../presubmit/{node12 => node14}/system-test.cfg | 0 .kokoro/presubmit/{node12 => node14}/test.cfg | 0 .kokoro/release/docs-devsite.sh | 5 +++-- .kokoro/release/docs.cfg | 2 +- .kokoro/release/publish.cfg | 2 +- .kokoro/samples-test.sh | 2 +- .kokoro/system-test.sh | 2 +- .kokoro/test.bat | 2 +- .kokoro/test.sh | 2 +- README.md | 2 +- package.json | 16 ++++++++-------- samples/package.json | 2 +- test/middleware/express.ts | 1 + 23 files changed, 26 insertions(+), 23 deletions(-) rename .kokoro/continuous/{node12 => node14}/common.cfg (93%) rename .kokoro/continuous/{node12 => node14}/lint.cfg (100%) rename .kokoro/continuous/{node12 => node14}/samples-test.cfg (100%) rename .kokoro/continuous/{node12 => node14}/system-test.cfg (100%) rename .kokoro/continuous/{node12 => node14}/test.cfg (100%) rename .kokoro/presubmit/{node12 => node14}/common.cfg (89%) rename .kokoro/presubmit/{node12 => node14}/samples-test.cfg (100%) rename .kokoro/presubmit/{node12 => node14}/system-test.cfg (100%) rename .kokoro/presubmit/{node12 => node14}/test.cfg (100%) diff --git a/.github/.OwlBot.lock.yaml b/.github/.OwlBot.lock.yaml index 0b836e11..a3d003c6 100644 --- a/.github/.OwlBot.lock.yaml +++ b/.github/.OwlBot.lock.yaml @@ -13,4 +13,5 @@ # limitations under the License. docker: image: gcr.io/cloud-devrel-public-resources/owlbot-nodejs:latest - digest: sha256:e6d785d6de3cab027f6213d95ccedab4cab3811b0d3172b78db2216faa182e32 + digest: sha256:e08f9a3757808cdaf7a377e962308c65c4d7eff12db206d4fae702dd50d43430 +# created: 2023-08-03T18:46:14.719706948Z diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index f447b84a..711957ba 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -9,7 +9,7 @@ jobs: runs-on: ubuntu-latest strategy: matrix: - node: [12, 14, 16] + node: [14, 16, 18, 20] steps: - uses: actions/checkout@v3 - uses: actions/setup-node@v3 diff --git a/.kokoro/common.cfg b/.kokoro/common.cfg index edb4167f..d5bc635f 100644 --- a/.kokoro/common.cfg +++ b/.kokoro/common.cfg @@ -16,7 +16,7 @@ build_file: "nodejs-logging-winston/.kokoro/trampoline_v2.sh" # Configure the docker image for kokoro-trampoline. env_vars: { key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/node:12-user" + value: "gcr.io/cloud-devrel-kokoro-resources/node:14-user" } env_vars: { key: "TRAMPOLINE_BUILD_FILE" diff --git a/.kokoro/continuous/node12/common.cfg b/.kokoro/continuous/node14/common.cfg similarity index 93% rename from .kokoro/continuous/node12/common.cfg rename to .kokoro/continuous/node14/common.cfg index edb4167f..d5bc635f 100644 --- a/.kokoro/continuous/node12/common.cfg +++ b/.kokoro/continuous/node14/common.cfg @@ -16,7 +16,7 @@ build_file: "nodejs-logging-winston/.kokoro/trampoline_v2.sh" # Configure the docker image for kokoro-trampoline. env_vars: { key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/node:12-user" + value: "gcr.io/cloud-devrel-kokoro-resources/node:14-user" } env_vars: { key: "TRAMPOLINE_BUILD_FILE" diff --git a/.kokoro/continuous/node12/lint.cfg b/.kokoro/continuous/node14/lint.cfg similarity index 100% rename from .kokoro/continuous/node12/lint.cfg rename to .kokoro/continuous/node14/lint.cfg diff --git a/.kokoro/continuous/node12/samples-test.cfg b/.kokoro/continuous/node14/samples-test.cfg similarity index 100% rename from .kokoro/continuous/node12/samples-test.cfg rename to .kokoro/continuous/node14/samples-test.cfg diff --git a/.kokoro/continuous/node12/system-test.cfg b/.kokoro/continuous/node14/system-test.cfg similarity index 100% rename from .kokoro/continuous/node12/system-test.cfg rename to .kokoro/continuous/node14/system-test.cfg diff --git a/.kokoro/continuous/node12/test.cfg b/.kokoro/continuous/node14/test.cfg similarity index 100% rename from .kokoro/continuous/node12/test.cfg rename to .kokoro/continuous/node14/test.cfg diff --git a/.kokoro/presubmit/node12/common.cfg b/.kokoro/presubmit/node14/common.cfg similarity index 89% rename from .kokoro/presubmit/node12/common.cfg rename to .kokoro/presubmit/node14/common.cfg index eac1092d..5c68abf3 100644 --- a/.kokoro/presubmit/node12/common.cfg +++ b/.kokoro/presubmit/node14/common.cfg @@ -16,7 +16,7 @@ build_file: "nodejs-logging-winston/.kokoro/trampoline_v2.sh" # Configure the docker image for kokoro-trampoline. env_vars: { key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/node:12-user" + value: "gcr.io/cloud-devrel-kokoro-resources/node:14-user" } env_vars: { key: "TRAMPOLINE_BUILD_FILE" diff --git a/.kokoro/presubmit/node12/samples-test.cfg b/.kokoro/presubmit/node14/samples-test.cfg similarity index 100% rename from .kokoro/presubmit/node12/samples-test.cfg rename to .kokoro/presubmit/node14/samples-test.cfg diff --git a/.kokoro/presubmit/node12/system-test.cfg b/.kokoro/presubmit/node14/system-test.cfg similarity index 100% rename from .kokoro/presubmit/node12/system-test.cfg rename to .kokoro/presubmit/node14/system-test.cfg diff --git a/.kokoro/presubmit/node12/test.cfg b/.kokoro/presubmit/node14/test.cfg similarity index 100% rename from .kokoro/presubmit/node12/test.cfg rename to .kokoro/presubmit/node14/test.cfg diff --git a/.kokoro/release/docs-devsite.sh b/.kokoro/release/docs-devsite.sh index 2198e67f..3596c1e4 100755 --- a/.kokoro/release/docs-devsite.sh +++ b/.kokoro/release/docs-devsite.sh @@ -25,5 +25,6 @@ if [[ -z "$CREDENTIALS" ]]; then fi npm install -npm install --no-save @google-cloud/cloud-rad@^0.2.5 -npx @google-cloud/cloud-rad \ No newline at end of file +npm install --no-save @google-cloud/cloud-rad@^0.3.7 +# publish docs to devsite +npx @google-cloud/cloud-rad . cloud-rad diff --git a/.kokoro/release/docs.cfg b/.kokoro/release/docs.cfg index 615bd801..f1239a8e 100644 --- a/.kokoro/release/docs.cfg +++ b/.kokoro/release/docs.cfg @@ -11,7 +11,7 @@ before_action { # doc publications use a Python image. env_vars: { key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/node:12-user" + value: "gcr.io/cloud-devrel-kokoro-resources/node:14-user" } # Download trampoline resources. diff --git a/.kokoro/release/publish.cfg b/.kokoro/release/publish.cfg index faf347e5..e7f04dfa 100644 --- a/.kokoro/release/publish.cfg +++ b/.kokoro/release/publish.cfg @@ -30,7 +30,7 @@ build_file: "nodejs-logging-winston/.kokoro/trampoline_v2.sh" # Configure the docker image for kokoro-trampoline. env_vars: { key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/node:12-user" + value: "gcr.io/cloud-devrel-kokoro-resources/node:14-user" } env_vars: { diff --git a/.kokoro/samples-test.sh b/.kokoro/samples-test.sh index 806c0082..8c5d108c 100755 --- a/.kokoro/samples-test.sh +++ b/.kokoro/samples-test.sh @@ -56,7 +56,7 @@ fi # codecov combines coverage across integration and unit tests. Include # the logic below for any environment you wish to collect coverage for: -COVERAGE_NODE=12 +COVERAGE_NODE=14 if npx check-node-version@3.3.0 --silent --node $COVERAGE_NODE; then NYC_BIN=./node_modules/nyc/bin/nyc.js if [ -f "$NYC_BIN" ]; then diff --git a/.kokoro/system-test.sh b/.kokoro/system-test.sh index 0201e9df..0b3043d2 100755 --- a/.kokoro/system-test.sh +++ b/.kokoro/system-test.sh @@ -49,7 +49,7 @@ npm run system-test # codecov combines coverage across integration and unit tests. Include # the logic below for any environment you wish to collect coverage for: -COVERAGE_NODE=12 +COVERAGE_NODE=14 if npx check-node-version@3.3.0 --silent --node $COVERAGE_NODE; then NYC_BIN=./node_modules/nyc/bin/nyc.js if [ -f "$NYC_BIN" ]; then diff --git a/.kokoro/test.bat b/.kokoro/test.bat index ae59e59b..0bb12405 100644 --- a/.kokoro/test.bat +++ b/.kokoro/test.bat @@ -21,7 +21,7 @@ cd .. @rem we upgrade Node.js in the image: SET PATH=%PATH%;/cygdrive/c/Program Files/nodejs/npm -call nvm use v12.14.1 +call nvm use v14.17.3 call which node call npm install || goto :error diff --git a/.kokoro/test.sh b/.kokoro/test.sh index a5c7ac04..862d478d 100755 --- a/.kokoro/test.sh +++ b/.kokoro/test.sh @@ -39,7 +39,7 @@ npm test # codecov combines coverage across integration and unit tests. Include # the logic below for any environment you wish to collect coverage for: -COVERAGE_NODE=12 +COVERAGE_NODE=14 if npx check-node-version@3.3.0 --silent --node $COVERAGE_NODE; then NYC_BIN=./node_modules/nyc/bin/nyc.js if [ -f "$NYC_BIN" ]; then diff --git a/README.md b/README.md index 5eaf5ca5..68067dee 100644 --- a/README.md +++ b/README.md @@ -339,7 +339,7 @@ also contains samples. ## Supported Node.js Versions -Our client libraries follow the [Node.js release schedule](https://nodejs.org/en/about/releases/). +Our client libraries follow the [Node.js release schedule](https://github.com/nodejs/release#release-schedule). Libraries are compatible with all current _active_ and _maintenance_ versions of Node.js. If you are using an end-of-life version of Node.js, we recommend that you update diff --git a/package.json b/package.json index 6a618cbc..1fd50704 100644 --- a/package.json +++ b/package.json @@ -5,7 +5,7 @@ "license": "Apache-2.0", "author": "Google Inc.", "engines": { - "node": ">=12.0.0" + "node": ">=14.0.0" }, "repository": "googleapis/nodejs-logging-winston", "main": "./build/src/index.js", @@ -50,28 +50,28 @@ "precompile": "gts clean" }, "dependencies": { - "@google-cloud/logging": "^10.2.2", - "google-auth-library": "^8.0.2", + "@google-cloud/logging": "^11.0.0", + "google-auth-library": "^9.0.0", "lodash.mapvalues": "^4.6.0", "winston-transport": "^4.3.0" }, "devDependencies": { "@compodoc/compodoc": "^1.1.10", - "@google-cloud/common": "^4.0.0", + "@google-cloud/common": "^5.0.0", "@types/lodash.mapvalues": "^4.6.6", "@types/mocha": "^9.0.0", - "@types/node": "^18.0.0", + "@types/node": "^20.4.9", "@types/proxyquire": "^1.3.28", "@types/triple-beam": "^1.3.0", "@types/uuid": "^9.0.0", - "c8": "^7.0.0", + "c8": "^8.0.1", "codecov": "^3.5.0", - "gts": "^3.1.0", + "gts": "^5.0.0", "linkinator": "^4.0.0", "mocha": "^9.2.2", "post-install-check": "0.0.1", "proxyquire": "^2.1.0", - "typescript": "^4.6.4", + "typescript": "^5.1.6", "uuid": "^9.0.0", "winston": "^3.2.1" }, diff --git a/samples/package.json b/samples/package.json index 4257c314..a53fb4ef 100644 --- a/samples/package.json +++ b/samples/package.json @@ -8,7 +8,7 @@ "author": "Google Inc.", "repository": "googleapis/nodejs-logging-winston", "engines": { - "node": ">=12.0.0" + "node": ">=14.0.0" }, "scripts": { "test": "mocha --timeout 600000" diff --git a/test/middleware/express.ts b/test/middleware/express.ts index 8e596abc..4d54b43b 100644 --- a/test/middleware/express.ts +++ b/test/middleware/express.ts @@ -37,6 +37,7 @@ class FakeLoggingWinston extends TransportStream { constructor(options: Options) { super(options); + // eslint-disable-next-line @typescript-eslint/no-this-alias transport = this; passedOptions.push(options); this.common = {