Skip to content

Commit 0a03b30

Browse files
authored
Merge branch 'main' into dependabot/npm_and_yarn/axios-1.18.1
2 parents 7684ed7 + 61e870d commit 0a03b30

3 files changed

Lines changed: 21 additions & 7 deletions

File tree

.github/workflows/dependabot_auto_merge.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,4 +88,4 @@ jobs:
8888
if: steps.merge_guard.outputs.should_merge == 'true'
8989
env:
9090
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
91-
run: gh pr merge "${{ steps.pr.outputs.pr_number }}" --repo "${GITHUB_REPOSITORY}" --rebase --delete-branch --match-head-commit "${{ steps.pr.outputs.head_sha }}" --auto
91+
run: gh pr merge "${{ steps.pr.outputs.pr_number }}" --repo "${GITHUB_REPOSITORY}" --rebase --delete-branch --match-head-commit "${{ steps.pr.outputs.head_sha }}"

.github/workflows/main.yml

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,14 @@ on:
1313
options:
1414
- direct
1515
- proxy
16+
upload_debug_artifacts:
17+
description: 'Upload redacted diagnostics on failure for this manual run'
18+
required: true
19+
default: 'false'
20+
type: choice
21+
options:
22+
- 'false'
23+
- 'true'
1624

1725
permissions:
1826
contents: write
@@ -71,15 +79,14 @@ jobs:
7179
GCP_SECRET_ID: ${{ vars.GCP_SECRET_ID }}
7280
SCHWAB_REDIRECT_URI: ${{ vars.SCHWAB_REDIRECT_URI }}
7381

74-
- name: Upload Error Screenshot
75-
if: failure()
82+
- name: Upload Redacted Diagnostics
83+
if: failure() && github.event_name == 'workflow_dispatch' && inputs.upload_debug_artifacts == 'true'
7684
uses: actions/upload-artifact@v7
7785
with:
78-
name: debug-screenshots
86+
name: redacted-diagnostics
7987
path: |
80-
*.png
8188
*_diagnostics.json
82-
retention-days: 3
89+
retention-days: 1
8390

8491
- name: Update Log (Bash Version)
8592
if: success()

tests/test_workflow_config_sources.sh

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,9 @@ grep -Eq "channel: ['\"]chrome['\"]" "$repo_dir/main.js"
2222
grep -Fq 'PW_TEST_SCREENSHOT_NO_FONTS_READY' "$repo_dir/main.js"
2323
grep -Fq '#placeholderCode' "$repo_dir/main.js"
2424
grep -Fq '#continueButton' "$repo_dir/main.js"
25-
grep -Fq ' *.png' "$workflow_file"
25+
grep -Fq 'upload_debug_artifacts:' "$workflow_file"
26+
grep -Fq 'Upload Redacted Diagnostics' "$workflow_file"
27+
grep -Fq "inputs.upload_debug_artifacts == 'true'" "$workflow_file"
2628
grep -Fq ' *_diagnostics.json' "$workflow_file"
2729

2830
if grep -Fq 'google-chrome-stable_current_amd64.deb' "$workflow_file"; then
@@ -35,6 +37,11 @@ if grep -Fq 'npx playwright install --with-deps chromium' "$workflow_file"; then
3537
exit 1
3638
fi
3739

40+
if grep -Fq ' *.png' "$workflow_file"; then
41+
echo "workflow should not upload screenshots by default" >&2
42+
exit 1
43+
fi
44+
3845
if grep -Fq 'secrets.GCP_PROJECT_ID' "$workflow_file"; then
3946
echo "workflow should not read GCP_PROJECT_ID from secrets anymore" >&2
4047
exit 1

0 commit comments

Comments
 (0)