Skip to content

Commit 65e297d

Browse files
authored
Merge branch 'main' into main
2 parents ca4d386 + d198266 commit 65e297d

File tree

414 files changed

+11677
-5052
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

414 files changed

+11677
-5052
lines changed

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,13 @@ Note: Before submitting a pull request, please open an issue for discussion if y
88
- [ ] I have followed guidelines from [CONTRIBUTING.MD](https://github.com/GoogleCloudPlatform/nodejs-docs-samples/blob/main/CONTRIBUTING.md) and [Samples Style Guide](https://googlecloudplatform.github.io/samples-style-guide/)
99
- [ ] **Tests** pass: `npm test` (see [Testing](https://github.com/GoogleCloudPlatform/nodejs-docs-samples/blob/main/CONTRIBUTING.md#run-the-tests-for-a-single-sample))
1010
- [ ] **Lint** pass: `npm run lint` (see [Style](https://github.com/GoogleCloudPlatform/nodejs-docs-samples/blob/main/CONTRIBUTING.md#style))
11+
- [ ] **Required CI tests** pass (see [CI testing](https://github.com/GoogleCloudPlatform/nodejs-docs-samples/blob/main/CONTRIBUTING.md#ci-testing))
1112
- [ ] These samples need a new **API enabled** in testing projects to pass (let us know which ones)
1213
- [ ] These samples need a new/updated **env vars** in testing projects set to pass (let us know which ones)
1314
- [ ] This pull request is from a branch created directly off of `GoogleCloudPlatform/nodejs-docs-samples`. Not a fork.
1415
- [ ] This sample adds a new sample directory, and I updated the [CODEOWNERS file](https://github.com/GoogleCloudPlatform/nodejs-docs-samples/blob/main/CODEOWNERS) with the codeowners for this sample
1516
- [ ] This sample adds a new sample directory, and I created [GitHub Actions workflow](https://github.com/GoogleCloudPlatform/nodejs-docs-samples/blob/main/CONTRIBUTING.md#adding-new-samples) for this sample
1617
- [ ] This sample adds a new **Product API**, and I updated the [Blunderbuss issue/PR auto-assigner](https://github.com/GoogleCloudPlatform/nodejs-docs-samples/blob/main/.github/blunderbuss.yml) with the codeowners for this sample
1718
- [ ] Please **merge** this PR for me once it is approved
19+
20+
> **Note**: Any check with `(dev)`, `(experimental)`, or `(legacy)` can be ignored and should **not block** your PR from merging (see [CI testing](https://github.com/GoogleCloudPlatform/nodejs-docs-samples/blob/main/CONTRIBUTING.md#ci-testing)).

.github/blunderbuss.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,10 @@ assign_issues_by:
4444
- "api: parametermanager"
4545
to:
4646
- GoogleCloudPlatform/cloud-parameters-team
47+
- labels:
48+
- "api: modelarmor"
49+
to:
50+
- GoogleCloudPlatform/cloud-modelarmor-team
4751

4852
assign_prs_by:
4953
- labels:
@@ -77,3 +81,7 @@ assign_prs_by:
7781
- "api: parametermanager"
7882
to:
7983
- GoogleCloudPlatform/cloud-parameters-team
84+
- labels:
85+
- "api: modelarmor"
86+
to:
87+
- GoogleCloudPlatform/cloud-modelarmor-team

.github/config/nodejs-dev.jsonc

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,9 @@
3636
".github/ISSUE_TEMPLATE/",
3737
".github/PULL_REQUEST_TEMPLATE.md",
3838
".github/auto-label.yaml",
39-
".github/blunderbuss.yaml",
39+
".github/blunderbuss.yml",
4040
".github/flakybot.yaml",
41-
".github/header-checker-lint.yaml",
41+
".github/header-checker-lint.yml",
4242
".github/scripts/",
4343
".github/snippet-bot.yml",
4444
".github/trusted-contribution.yml",
@@ -100,6 +100,10 @@
100100
"auth",
101101
"batch",
102102
"cloud-language",
103+
"cloud-sql/mysql/mysql",
104+
"cloud-sql/mysql/mysql2",
105+
"cloud-sql/postgres/knex",
106+
"cloud-sql/sqlserver/mssql",
103107
"cloud-tasks/snippets",
104108
"cloud-tasks/tutorial-gcf/app",
105109
"cloud-tasks/tutorial-gcf/function",
@@ -146,9 +150,11 @@
146150
"functions/http/httpContent",
147151
"functions/http/httpMethods",
148152
"functions/http/parseXML",
153+
"functions/imagemagick",
149154
"functions/log/helloWorld",
150155
"functions/log/processEntry",
151156
"functions/memorystore/redis",
157+
"functions/ocr/app",
152158
"functions/pubsub/publish",
153159
"functions/pubsub/subscribe",
154160
"functions/scheduleinstance",
@@ -172,6 +178,7 @@
172178
"functions/v2/helloGCS",
173179
"functions/v2/helloPubSub",
174180
"functions/v2/httpLogging",
181+
"functions/v2/imagemagick",
175182
"functions/v2/log/processEntry",
176183
"functions/v2/ocr/app",
177184
"functions/v2/responseStreaming",
@@ -199,6 +206,7 @@
199206
"run/image-processing",
200207
"run/jobs",
201208
"run/logging-manual",
209+
"run/idp-sql",
202210
"run/markdown-preview/editor",
203211
"run/markdown-preview/renderer",
204212
"run/pubsub",
@@ -214,6 +222,7 @@
214222
"texttospeech",
215223
"tpu",
216224
"translate",
225+
"vision",
217226
"workflows/invoke-private-endpoint"
218227
]
219228
}

.github/config/nodejs-prod.jsonc renamed to .github/config/nodejs.jsonc

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,9 @@
3636
".github/ISSUE_TEMPLATE/",
3737
".github/PULL_REQUEST_TEMPLATE.md",
3838
".github/auto-label.yaml",
39-
".github/blunderbuss.yaml",
39+
".github/blunderbuss.yml",
4040
".github/flakybot.yaml",
41-
".github/header-checker-lint.yaml",
41+
".github/header-checker-lint.yml",
4242
".github/scripts/",
4343
".github/snippet-bot.yml",
4444
".github/trusted-contribution.yml",
@@ -77,10 +77,6 @@
7777
// TODO: fix these
7878
"ai-platform/snippets", // PERMISSION_DENIED: Permission denied: Consumer 'projects/undefined' has been suspended.
7979
"automl", // (untested) FAILED_PRECONDITION: Google Cloud AutoML Natural Language was retired on March 15, 2024. Please migrate to Vertex AI instead
80-
"cloud-sql/mysql/mysql", // (untested) Error: expected 200 "OK", got 500 "Internal Server Error"
81-
"cloud-sql/mysql/mysql2", // (untested) Error: Cannot find module './connect-connector-with-iam-authn.js'
82-
"cloud-sql/postgres/knex", // (untested) CloudSQLConnectorError: Malformed instance connection name provided: expected format of "PROJECT:REGION:INSTANCE", got undefined
83-
"cloud-sql/sqlserver/mssql", // (untested) TypeError: The "config.server" property is required and must be of type string.
8480
"cloud-sql/sqlserver/tedious", // (untested) TypeError: The "config.server" property is required and must be of type string.
8581
"compute", // GoogleError: The resource 'projects/long-door-651/zones/us-central1-a/disks/disk-from-pool-name' was not found
8682
"dataproc", // GoogleError: Error submitting create cluster request: Multiple validation errors
@@ -89,16 +85,11 @@
8985
"dlp", // [ERR_REQUIRE_ESM]: require() of ES Module
9086
"document-ai", // [ERR_REQUIRE_ESM]: require() of ES Module
9187
"functions/billing", // (untested) Error: Request failed with status code 500
92-
"functions/imagemagick", // (untested) Error: A bucket name is needed to use Cloud Storage
93-
"functions/ocr/app", // (untested) Error: Bucket not provided. Make sure you have a "bucket" property in your request
9488
"functions/slack", // TypeError [ERR_INVALID_ARG_TYPE]: The "key" argument must be of type ... Received undefined
95-
"functions/v2/imagemagick", // (untested) Error: A bucket name is needed to use Cloud Storage.
9689
"healthcare/fhir", // Error: Cannot find module 'whatwg-url'
9790
"iam/deny", // PERMISSION_DENIED: Permission iam.googleapis.com/denypolicies.create denied on resource cloudresourcemanager.googleapis.com/projects/long-door-651
98-
"run/idp-sql", // (untested) Error: Invalid contents in the credentials file
9991
"storagetransfer", // CredentialsError: Missing credentials in config, if using AWS_CONFIG_FILE, set AWS_SDK_LOAD_CONFIG=1
10092
"video-intelligence", // PERMISSION_DENIED: The caller does not have permission
101-
"vision", // REDIS: Error: connect ECONNREFUSED 127.0.0.1:6379
10293
"workflows", // SyntaxError: Cannot use import statement outside a module
10394
"workflows/quickstart" // [ERR_MODULE_NOT_FOUND]: Cannot find package 'ts-node' imported from ...
10495
]

.github/workflows/ai-platform-snippets.yaml

Lines changed: 1 addition & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ jobs:
6262
id: npm-cache-dir
6363
shell: bash
6464
run: echo "dir=$(npm config get cache)" >> ${GITHUB_OUTPUT}
65-
- uses: actions/cache@d4323d4df104b026a6aa633fdb11d772146be0bf # v4
65+
- uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684 # v4
6666
id: npm-cache
6767
with:
6868
path: ${{ steps.npm-cache-dir.outputs.dir }}
@@ -80,19 +80,3 @@ jobs:
8080
GOOGLE_SAMPLES_PROJECT: "long-door-651"
8181
LOCATION: ${{ steps.secrets.outputs.location }}
8282
CAIP_PROJECT_ID: ${{ steps.secrets.outputs.caip_id }}
83-
- name: upload test results for FlakyBot workflow
84-
if: github.event.action == 'schedule' && always()
85-
uses: actions/upload-artifact@4cec3d8aa04e39d1a68397de0c4cd6fb9dce8ec1 # v4
86-
env:
87-
MOCHA_REPORTER_OUTPUT: "${{github.run_id}}_sponge_log.xml"
88-
with:
89-
name: test-results
90-
path: ai-platform/snippets/${{ env.MOCHA_REPORTER_OUTPUT }}
91-
retention-days: 1
92-
flakybot:
93-
permissions:
94-
contents: 'read'
95-
id-token: 'write'
96-
if: github.event_name == 'schedule' && always() # always() submits logs even if tests fail
97-
uses: ./.github/workflows/flakybot.yaml
98-
needs: [test]

.github/workflows/appengine-analytics.yaml

Lines changed: 0 additions & 52 deletions
This file was deleted.

.github/workflows/appengine-metadata-flexible.yaml

Lines changed: 0 additions & 52 deletions
This file was deleted.

.github/workflows/ci-scripts.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ jobs:
3131
working-directory: .github/scripts
3232
steps:
3333
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
34-
- uses: actions/setup-node@1d0ff469b7ec7b3cb9d8673fde0c81c44821de2a # v4
34+
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4
3535
with:
3636
node-version: 20
3737
- run: npm install

.github/workflows/compute.yaml

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -43,10 +43,3 @@ jobs:
4343
with:
4444
name: 'compute'
4545
path: 'compute'
46-
flakybot:
47-
permissions:
48-
contents: 'read'
49-
id-token: 'write'
50-
if: github.event_name == 'schedule' && always() # always() submits logs even if tests fail
51-
uses: ./.github/workflows/flakybot.yaml
52-
needs: [test]

.github/workflows/ci-dev.yaml renamed to .github/workflows/custard-ci-dev.yaml

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
# See the License for the specific language governing permissions and
1313
# limitations under the License.
1414

15-
name: custard CI (dev)
15+
name: (legacy dev) Custard CI
1616
on:
1717
push:
1818
branches:
@@ -27,7 +27,7 @@ env:
2727

2828
jobs:
2929
affected:
30-
name: Finding affected tests
30+
name: (legacy) Finding affected tests
3131
runs-on: ubuntu-latest
3232
timeout-minutes: 2
3333
outputs:
@@ -40,12 +40,12 @@ jobs:
4040
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
4141
with:
4242
repository: GoogleCloudPlatform/cloud-samples-tools
43-
ref: v0.2.1
43+
ref: v0.3.2
4444
path: cloud-samples-tools
4545
- name: Create `bin` directory for cloud-samples-tools binaries
4646
run: mkdir bin
4747
working-directory: cloud-samples-tools
48-
- uses: actions/setup-go@f111f3307d8850f501ac008e886eec1fd1932a34 # v5
48+
- uses: actions/setup-go@d35c59abb061a4a6fb18e82ac0862c26744d6ab5 # v5
4949
with:
5050
go-version: ${{ env.GO_VERSION }}
5151
- name: Build Custard (from cloud-samples-tools)
@@ -61,7 +61,8 @@ jobs:
6161
echo "setups=$(./cloud-samples-tools/bin/custard setup-files .github/config/nodejs-dev.jsonc paths.txt)" >> $GITHUB_OUTPUT
6262
6363
nodejs-test:
64-
name: test
64+
if: github.event.pull_request && github.event.pull_request.head.repo.fork == false
65+
name: (legacy) test
6566
needs: affected
6667
runs-on: ubuntu-latest
6768
timeout-minutes: 120 # 2 hours hard limit
@@ -81,7 +82,7 @@ jobs:
8182
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4
8283
with:
8384
ref: ${{ github.event.pull_request.head.sha }}
84-
- uses: actions/setup-node@1d0ff469b7ec7b3cb9d8673fde0c81c44821de2a # v4
85+
- uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4
8586
with:
8687
node-version: ${{ fromJson(env.CI_SETUP).node-version }}
8788
- uses: google-github-actions/auth@6fc4af4b145ae7821d527454aa9bd537d1f2dc5f # v2

0 commit comments

Comments
 (0)