diff --git a/.github/workflows/RollPyTorch.yml b/.github/workflows/RollPyTorch.yml index 25cb26395be..2976df3442b 100644 --- a/.github/workflows/RollPyTorch.yml +++ b/.github/workflows/RollPyTorch.yml @@ -14,11 +14,13 @@ jobs: if: github.repository == 'llvm/torch-mlir' steps: - - - name: chown $GITHUB_WORKSPACE + + - name: Prepare workspace run: | - sudo chown -R $USER:$USER $GITHUB_WORKSPACE - + # Clear the workspace directory so that we don't run into errors about + # existing lock files. + rm -rf $GITHUB_WORKSPACE/* + - name: Get torch-mlir uses: actions/checkout@v3 with: diff --git a/.github/workflows/bazelBuildAndTest.yml b/.github/workflows/bazelBuildAndTest.yml index dd053ae7f0a..17a14189933 100644 --- a/.github/workflows/bazelBuildAndTest.yml +++ b/.github/workflows/bazelBuildAndTest.yml @@ -20,6 +20,12 @@ jobs: runs-on: ubuntu-latest steps: + - name: Prepare workspace + run: | + # Clear the workspace directory so that we don't run into errors about + # existing lock files. + rm -rf $GITHUB_WORKSPACE/* + - name: Checkout torch-mlir uses: actions/checkout@v3 with: diff --git a/.github/workflows/buildAndTest.yml b/.github/workflows/buildAndTest.yml index aaaa84aab13..8590649541d 100644 --- a/.github/workflows/buildAndTest.yml +++ b/.github/workflows/buildAndTest.yml @@ -52,10 +52,12 @@ jobs: steps: - - name: chown $GITHUB_WORKSPACE + - name: Prepare workspace if: ${{ matrix.os-arch == 'ubuntu-x86_64' }} run: | - sudo chown -R $USER:$USER $GITHUB_WORKSPACE + # Clear the workspace directory so that we don't run into errors about + # existing lock files. + rm -rf $GITHUB_WORKSPACE/* - name: Checkout torch-mlir uses: actions/checkout@v3 diff --git a/.github/workflows/buildRelease.yml b/.github/workflows/buildRelease.yml index 6ea420dfedf..051811c0673 100644 --- a/.github/workflows/buildRelease.yml +++ b/.github/workflows/buildRelease.yml @@ -15,11 +15,13 @@ jobs: name: Manylinux Build runs-on: a100 steps: - - - name: chown $GITHUB_WORKSPACE + + - name: Prepare workspace run: | - sudo chown -R $USER:$USER $GITHUB_WORKSPACE - + # Clear the workspace directory so that we don't run into errors about + # existing lock files. + rm -rf $GITHUB_WORKSPACE/* + - name: Get torch-mlir uses: actions/checkout@v3 with: diff --git a/.github/workflows/gh-pages-releases.yml b/.github/workflows/gh-pages-releases.yml index ecac146b9b6..1849f8d4521 100644 --- a/.github/workflows/gh-pages-releases.yml +++ b/.github/workflows/gh-pages-releases.yml @@ -13,8 +13,13 @@ jobs: if: github.repository == 'llvm/torch-mlir' steps: + - name: Prepare workspace + run: | + # Clear the workspace directory so that we don't run into errors about + # existing lock files. + rm -rf $GITHUB_WORKSPACE/* - name: Checking out repository - uses: actions/checkout@v2 + uses: actions/checkout@v3 with: token: ${{ secrets.WORKFLOW_INVOCATION_TOKEN }} - name: Run scrape releases script diff --git a/.github/workflows/oneshotSnapshotPackage.yml b/.github/workflows/oneshotSnapshotPackage.yml index c21ed8f9e36..07d0863a741 100644 --- a/.github/workflows/oneshotSnapshotPackage.yml +++ b/.github/workflows/oneshotSnapshotPackage.yml @@ -10,8 +10,14 @@ jobs: # Don't run this in everyone's forks. if: github.repository == 'llvm/torch-mlir' steps: + - name: Prepare workspace + run: | + # Clear the workspace directory so that we don't run into errors about + # existing lock files. + rm -rf $GITHUB_WORKSPACE/* + - name: Checking out repository - uses: actions/checkout@v2 + uses: actions/checkout@v3 with: token: ${{ secrets.WORKFLOW_INVOCATION_TOKEN }} diff --git a/.github/workflows/releaseSnapshotPackage.yml b/.github/workflows/releaseSnapshotPackage.yml index 1037abca0b2..a9878633865 100644 --- a/.github/workflows/releaseSnapshotPackage.yml +++ b/.github/workflows/releaseSnapshotPackage.yml @@ -13,8 +13,15 @@ jobs: # Don't run this in everyone's forks. if: github.repository == 'llvm/torch-mlir' steps: + + - name: Prepare workspace + run: | + # Clear the workspace directory so that we don't run into errors about + # existing lock files. + rm -rf $GITHUB_WORKSPACE/* + - name: Checking out repository - uses: actions/checkout@v2 + uses: actions/checkout@v3 with: token: ${{ secrets.WORKFLOW_INVOCATION_TOKEN }}