Skip to content

Commit 17f4004

Browse files
authored
[CI] Release only changes for 2.1 release (#108053)
* [CI] Release only changes for 2.1 release * include circle script * release only changes for test-infra * More test-infra related
1 parent 138e289 commit 17f4004

51 files changed

Lines changed: 271 additions & 409 deletions

File tree

Some content is hidden

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

.ci/pytorch/common_utils.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -180,7 +180,7 @@ function install_numpy_pytorch_interop() {
180180

181181
function clone_pytorch_xla() {
182182
if [[ ! -d ./xla ]]; then
183-
git clone --recursive --quiet https://github.com/pytorch/xla.git
183+
git clone --recursive -b r2.1 https://github.com/pytorch/xla.git
184184
pushd xla
185185
# pin the xla hash so that we don't get broken by changes to xla
186186
git checkout "$(cat ../.github/ci_commit_pins/xla.txt)"

.circleci/scripts/binary_checkout.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ git --no-pager log --max-count 1
6262
popd
6363

6464
# Clone the Builder main repo
65-
retry git clone -q https://github.com/pytorch/builder.git "$BUILDER_ROOT"
65+
retry git clone -q https://github.com/pytorch/builder.git -b release/2.1 "$BUILDER_ROOT"
6666
pushd "$BUILDER_ROOT"
6767
echo "Using builder from "
6868
git --no-pager log --max-count 1

.github/ci_commit_pins/xla.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
e1ee592d9806216d7ac0bb711cae6307b0c5b68a
1+
r2.1

.github/templates/common.yml.j2

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
# NOTE: If testing pytorch/builder changes you can change this variable to change what pytorch/builder reference
99
# the binary builds will check out
1010
{%- set builder_repo = "pytorch/builder" -%}
11-
{%- set builder_branch = "main" -%}
11+
{%- set builder_branch = "release/2.1" -%}
1212

1313
{%- macro concurrency(build_environment) -%}
1414
concurrency:

.github/templates/linux_binary_build_workflow.yml.j2

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -97,13 +97,13 @@ jobs:
9797
with:
9898
name: !{{ config["build_name"] }}
9999
path: "${{ runner.temp }}/artifacts/"
100-
!{{ common.checkout(deep_clone=False, directory="pytorch") }}
101-
!{{ common.checkout(deep_clone=False, directory="builder", repository=common.builder_repo, branch=common.builder_branch) }}
100+
!{{ common.checkout(deep_clone=False, directory="pytorch", checkout_pr_head=False) }}
101+
!{{ common.checkout(deep_clone=False, directory="builder", repository=common.builder_repo, branch=common.builder_branch, checkout_pr_head=False) }}
102102
- name: ROCm set GPU_FLAG
103103
run: |
104104
echo "GPU_FLAG=--device=/dev/mem --device=/dev/kfd --device=/dev/dri --group-add video --group-add daemon" >> "${GITHUB_ENV}"
105105
- name: Pull Docker image
106-
uses: pytorch/test-infra/.github/actions/pull-docker-image@main
106+
uses: pytorch/test-infra/.github/actions/pull-docker-image@release/2.1
107107
with:
108108
docker-image: !{{ config["container_image"] }}
109109
- name: Test Pytorch binary

.github/templates/macos_binary_build_workflow.yml.j2

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,8 +74,8 @@ jobs:
7474
/bin/bash "${RUNNER_TEMP}/conda.sh" -b -p "${RUNNER_TEMP}/anaconda"
7575
echo "${RUNNER_TEMP}/anaconda/bin" >> "${GITHUB_PATH}"
7676
echo "DEVELOPER_DIR=/Applications/Xcode_13.3.1.app/Contents/Developer" >> "${GITHUB_ENV}"
77-
!{{ common.checkout(deep_clone=False, directory="pytorch") }}
78-
!{{ common.checkout(deep_clone=False, directory="builder", repository=common.builder_repo, branch=common.builder_branch) }}
77+
!{{ common.checkout(deep_clone=False, directory="pytorch", checkout_pr_head=False) }}
78+
!{{ common.checkout(deep_clone=False, directory="builder", repository=common.builder_repo, branch=common.builder_branch, checkout_pr_head=False) }}
7979
- name: Install sccache (only for non-forked PRs, and pushes to trunk)
8080
uses: nick-fields/retry@v2.8.2
8181
if: ${{ github.event_name == 'push' || github.event.pull_request.head.repo.full_name == github.repository }}

.github/templates/windows_binary_build_workflow.yml.j2

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,8 @@ jobs:
6262
steps:
6363
!{{ common.setup_ec2_windows() }}
6464
!{{ set_runner_specific_vars() }}
65-
!{{ common.checkout(deep_clone=False, directory="pytorch") }}
66-
!{{ common.checkout(deep_clone=False, directory="builder", repository=common.builder_repo, branch=common.builder_branch) }}
65+
!{{ common.checkout(deep_clone=False, directory="pytorch", checkout_pr_head=False) }}
66+
!{{ common.checkout(deep_clone=False, directory="builder", repository=common.builder_repo, branch=common.builder_branch, checkout_pr_head=False) }}
6767
- name: Populate binary env
6868
shell: bash
6969
run: |
@@ -102,8 +102,8 @@ jobs:
102102
with:
103103
name: !{{ config["build_name"] }}
104104
path: "${{ env.PYTORCH_FINAL_PACKAGE_DIR }}"
105-
!{{ common.checkout(deep_clone=False, directory="pytorch") }}
106-
!{{ common.checkout(deep_clone=False, directory="builder", repository=common.builder_repo, branch=common.builder_branch) }}
105+
!{{ common.checkout(deep_clone=False, directory="pytorch", checkout_pr_head=False) }}
106+
!{{ common.checkout(deep_clone=False, directory="builder", repository=common.builder_repo, branch=common.builder_branch, checkout_pr_head=False) }}
107107
- name: Populate binary env
108108
shell: bash
109109
run: |

.github/workflows/_android-build-test.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ jobs:
3636
keep-going: ${{ steps.filter.outputs.keep-going }}
3737
steps:
3838
- name: Checkout PyTorch
39-
uses: pytorch/pytorch/.github/actions/checkout-pytorch@main
39+
uses: pytorch/pytorch/.github/actions/checkout-pytorch@release/2.1
4040
with:
4141
fetch-depth: 1
4242
submodules: false
@@ -58,25 +58,25 @@ jobs:
5858
runs-on: ${{ matrix.runner }}
5959
steps:
6060
- name: Setup SSH (Click me for login details)
61-
uses: pytorch/test-infra/.github/actions/setup-ssh@main
61+
uses: pytorch/test-infra/.github/actions/setup-ssh@release/2.1
6262
with:
6363
github-secret: ${{ secrets.GITHUB_TOKEN }}
6464

6565
# [see note: pytorch repo ref]
6666
- name: Checkout PyTorch
67-
uses: pytorch/pytorch/.github/actions/checkout-pytorch@main
67+
uses: pytorch/pytorch/.github/actions/checkout-pytorch@release/2.1
6868

6969
- name: Setup Linux
7070
uses: ./.github/actions/setup-linux
7171

7272
- name: Calculate docker image
7373
id: calculate-docker-image
74-
uses: pytorch/test-infra/.github/actions/calculate-docker-image@main
74+
uses: pytorch/test-infra/.github/actions/calculate-docker-image@release/2.1
7575
with:
7676
docker-image-name: ${{ inputs.docker-image-name }}
7777

7878
- name: Pull docker image
79-
uses: pytorch/test-infra/.github/actions/pull-docker-image@main
79+
uses: pytorch/test-infra/.github/actions/pull-docker-image@release/2.1
8080
with:
8181
docker-image: ${{ steps.calculate-docker-image.outputs.docker-image }}
8282

@@ -140,5 +140,5 @@ jobs:
140140
if: always()
141141

142142
- name: Teardown Linux
143-
uses: pytorch/test-infra/.github/actions/teardown-linux@main
143+
uses: pytorch/test-infra/.github/actions/teardown-linux@release/2.1
144144
if: always()

.github/workflows/_android-full-build-test.yml

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ jobs:
3636
keep-going: ${{ steps.filter.outputs.keep-going }}
3737
steps:
3838
- name: Checkout PyTorch
39-
uses: pytorch/pytorch/.github/actions/checkout-pytorch@main
39+
uses: pytorch/pytorch/.github/actions/checkout-pytorch@release/2.1
4040
with:
4141
fetch-depth: 1
4242
submodules: false
@@ -58,25 +58,25 @@ jobs:
5858
runs-on: ${{ matrix.runner }}
5959
steps:
6060
- name: Setup SSH (Click me for login details)
61-
uses: pytorch/test-infra/.github/actions/setup-ssh@main
61+
uses: pytorch/test-infra/.github/actions/setup-ssh@release/2.1
6262
with:
6363
github-secret: ${{ secrets.GITHUB_TOKEN }}
6464

6565
# [see note: pytorch repo ref]
6666
- name: Checkout PyTorch
67-
uses: pytorch/pytorch/.github/actions/checkout-pytorch@main
67+
uses: pytorch/pytorch/.github/actions/checkout-pytorch@release/2.1
6868

6969
- name: Setup Linux
7070
uses: ./.github/actions/setup-linux
7171

7272
- name: Calculate docker image
7373
id: calculate-docker-image
74-
uses: pytorch/test-infra/.github/actions/calculate-docker-image@main
74+
uses: pytorch/test-infra/.github/actions/calculate-docker-image@release/2.1
7575
with:
7676
docker-image-name: ${{ inputs.docker-image-name }}
7777

7878
- name: Pull docker image
79-
uses: pytorch/test-infra/.github/actions/pull-docker-image@main
79+
uses: pytorch/test-infra/.github/actions/pull-docker-image@release/2.1
8080
with:
8181
docker-image: ${{ steps.calculate-docker-image.outputs.docker-image }}
8282

@@ -185,5 +185,5 @@ jobs:
185185
if: always()
186186

187187
- name: Teardown Linux
188-
uses: pytorch/test-infra/.github/actions/teardown-linux@main
188+
uses: pytorch/test-infra/.github/actions/teardown-linux@release/2.1
189189
if: always()

.github/workflows/_bazel-build-test.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ jobs:
4141
reenabled-issues: ${{ steps.filter.outputs.reenabled-issues }}
4242
steps:
4343
- name: Checkout PyTorch
44-
uses: pytorch/pytorch/.github/actions/checkout-pytorch@main
44+
uses: pytorch/pytorch/.github/actions/checkout-pytorch@release/2.1
4545
with:
4646
fetch-depth: 1
4747
submodules: false
@@ -63,30 +63,30 @@ jobs:
6363
runs-on: ${{ matrix.runner }}
6464
steps:
6565
- name: Setup SSH (Click me for login details)
66-
uses: pytorch/test-infra/.github/actions/setup-ssh@main
66+
uses: pytorch/test-infra/.github/actions/setup-ssh@release/2.1
6767
with:
6868
github-secret: ${{ secrets.GITHUB_TOKEN }}
6969

7070
# [see note: pytorch repo ref]
7171
- name: Checkout PyTorch
72-
uses: pytorch/pytorch/.github/actions/checkout-pytorch@main
72+
uses: pytorch/pytorch/.github/actions/checkout-pytorch@release/2.1
7373

7474
- name: Setup Linux
7575
uses: ./.github/actions/setup-linux
7676

7777
- name: Calculate docker image
7878
id: calculate-docker-image
79-
uses: pytorch/test-infra/.github/actions/calculate-docker-image@main
79+
uses: pytorch/test-infra/.github/actions/calculate-docker-image@release/2.1
8080
with:
8181
docker-image-name: ${{ inputs.docker-image-name }}
8282

8383
- name: Pull docker image
84-
uses: pytorch/test-infra/.github/actions/pull-docker-image@main
84+
uses: pytorch/test-infra/.github/actions/pull-docker-image@release/2.1
8585
with:
8686
docker-image: ${{ steps.calculate-docker-image.outputs.docker-image }}
8787

8888
- name: Install nvidia driver, nvidia-docker runtime, set GPU_FLAG
89-
uses: pytorch/test-infra/.github/actions/setup-nvidia@main
89+
uses: pytorch/test-infra/.github/actions/setup-nvidia@release/2.1
9090
if: ${{ inputs.cuda-version != 'cpu' }}
9191

9292
- name: Output disk space left
@@ -197,5 +197,5 @@ jobs:
197197
file-suffix: bazel-${{ github.job }}_${{ steps.get-job-id.outputs.job-id }}
198198

199199
- name: Teardown Linux
200-
uses: pytorch/test-infra/.github/actions/teardown-linux@main
200+
uses: pytorch/test-infra/.github/actions/teardown-linux@release/2.1
201201
if: always()

0 commit comments

Comments
 (0)