AutoGPT is the vision of accessible AI for everyone, to use and to build on. Our mission is to provide the tools, so that you can focus on what matters.
fix ci cassettes (#4234)
merwanehamadi517c0805443c
diff --git a/.github/workflows/add-cassettes.yml b/.github/workflows/add-cassettes.ymlindex 90e4402d96..9bf5b1b890 100644--- a/.github/workflows/add-cassettes.yml+++ b/.github/workflows/add-cassettes.yml@@ -22,7 +22,7 @@ jobs:- name: Reset branchrun: |git checkout ${{ github.event.pull_request.base.ref }}- git reset --hard origin/cassette-diff-${{ github.event.pull_request.number }}+ git reset --hard origin/cassette-diff-${{ github.event.pull_request.head.sha }}- name: Create PRid: create_pr@@ -30,7 +30,7 @@ jobs:with:commit-message: Update cassettessignoff: false- branch: cassette-diff-${{ github.event.pull_request.number }}+ branch: cassette-diff-${{ github.event.pull_request.head.sha }}delete-branch: falsetitle: "Update cassettes"body: "This PR updates the cassettes."diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.ymlindex c2afde5514..b36b45e8b6 100644--- a/.github/workflows/ci.yml+++ b/.github/workflows/ci.yml@@ -95,11 +95,13 @@ jobs:- name: Stage new files and commitrun: |+ COMMIT_SHA=$(git rev-parse HEAD) # take the sha before committing the cassettegit add testsgit diff --cached --quiet && echo "No changes to commit" && exit 0git config user.email "[email protected]"git config user.name "GitHub Actions"git commit -m "Add new cassettes"- git checkout -b cassette-diff-${{ github.event.pull_request.number }}++ git checkout -b cassette-diff-${COMMIT_SHA}git remote add target https://${{ secrets.GITHUB_TOKEN }}@github.com/${{ github.event.pull_request.base.repo.full_name }}- git push -f target cassette-diff-${{ github.event.pull_request.number }}+ git push -f target cassette-diff-${COMMIT_SHA}