Skip to content

Commit d5a55aa

Browse files
saitcakmakmeta-codesync[bot]
authored andcommitted
Fix tutorials workflow git fetch failure (#3185)
Summary: Pull Request resolved: #3185 The tutorials workflow was failing because `git fetch --prune --unshallow` could not authenticate with the HTTPS remote after `actions/checkout@v4` had completed. Instead, configure the checkout action to do a full clone directly by setting `fetch-depth: 0`, which uses the checkout action's own credentials. This is needed by `setuptools_scm` to determine the BoTorch version. Reviewed By: Balandat Differential Revision: D93482307 fbshipit-source-id: 9aebb4c2f97846b6506d4a27e98a9ec1eb0376ab
1 parent d381975 commit d5a55aa

3 files changed

Lines changed: 6 additions & 7 deletions

File tree

.github/workflows/deploy_on_release.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,10 @@ jobs:
2626
needs: tests-and-coverage
2727
steps:
2828
- uses: actions/checkout@v4
29+
with:
30+
fetch-depth: 0
2931
- name: Install uv
3032
uses: astral-sh/setup-uv@v5
31-
- name: Fetch all history for all tags and branches
32-
run: git fetch --prune --unshallow
3333
- name: Set up Python
3434
uses: actions/setup-python@v5
3535
with:

.github/workflows/nightly.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ jobs:
2525
UV_SYSTEM_PYTHON: 1
2626
steps:
2727
- uses: actions/checkout@v4
28-
- name: Fetch all history for all tags and branches
29-
run: git fetch --prune --unshallow
28+
with:
29+
fetch-depth: 0
3030
- name: Install uv
3131
uses: astral-sh/setup-uv@v5
3232
- name: Set up Python

.github/workflows/reusable_tutorials.yml

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,8 @@ jobs:
2929
UV_SYSTEM_PYTHON: 1
3030
steps:
3131
- uses: actions/checkout@v4
32+
with:
33+
fetch-depth: 0
3234
- name: Install uv
3335
uses: astral-sh/setup-uv@v5
3436
- if: ${{ !inputs.use_stable_pytorch_gpytorch }}
@@ -41,9 +43,6 @@ jobs:
4143
uses: actions/setup-python@v5
4244
with:
4345
python-version: "3.11"
44-
- name: Fetch all history for all tags and branches
45-
# We need to do this so setuptools_scm knows how to set the BoTorch version.
46-
run: git fetch --prune --unshallow
4746
- if: ${{ !inputs.use_stable_pytorch_gpytorch }}
4847
name: Install latest PyTorch & GPyTorch
4948
run: |

0 commit comments

Comments
 (0)