Skip to content

Commit 44299a1

Browse files
CristianLarafacebook-github-bot
authored andcommitted
Add permissions to test website build workflow (#2917)
Summary: The first run of this workflow failed https://github.com/pytorch/botorch/actions/runs/16153124002 ``` Invalid workflow file: .github/workflows/test_website.yml#L17 The workflow is not valid. .github/workflows/test_website.yml (Line: 17, Col: 3): Error calling workflow 'pytorch/botorch/.github/workflows/publish_website.yml@669d131'. The nested job 'build-website' is requesting 'contents: write', but is only allowed 'contents: read'. .github/workflows/test_website.yml (Line: 17, Col: 3): Error calling workflow 'pytorch/botorch/.github/workflows/publish_website.yml@669d131'. The nested job 'deploy-website' is requesting 'pages: write, id-token: write', but is only allowed 'pages: none, id-token: none'. ``` It's correct that the publish_website.yml workflow uses these permissions to update the branch and deploy gh-pages but we enable the dry_run option which skips those steps. Specifying these permissions wasn't required in the Ax counterpart for some reason... the GITHUB_TOKEN permissions may have been adjusted in that repo but I don't have access to those settings https://github.com/facebook/Ax/blob/main/.github/workflows/test_website.yml Pull Request resolved: #2917 Test Plan: Manually triggered the workflow targeting this branch from the UI and it now actually runs https://github.com/pytorch/botorch/actions/runs/16153629735 Reviewed By: saitcakmak Differential Revision: D77957829 Pulled By: CristianLara fbshipit-source-id: 87501eb06f5652b2ba29c24fb89ce667589b4bbd
1 parent 669d131 commit 44299a1

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

.github/workflows/test_website.yml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,3 +20,7 @@ jobs:
2020
with:
2121
dry_run: true
2222
run_tutorials: false
23+
permissions:
24+
contents: write
25+
pages: write
26+
id-token: write

0 commit comments

Comments
 (0)