From bdd5ccc77463038405552d5fbaaf0539e3115c7f Mon Sep 17 00:00:00 2001 From: David Robertson Date: Sat, 28 Oct 2023 19:12:57 +0100 Subject: [PATCH 1/4] Run actions/setup-go after checking out complement --- .github/workflows/latest_deps.yml | 6 ++++-- .github/workflows/tests.yml | 6 ++++-- .github/workflows/twisted_trunk.yml | 6 ++++-- 3 files changed, 12 insertions(+), 6 deletions(-) diff --git a/.github/workflows/latest_deps.yml b/.github/workflows/latest_deps.yml index c9ec70abe981..738aed7bd1af 100644 --- a/.github/workflows/latest_deps.yml +++ b/.github/workflows/latest_deps.yml @@ -197,11 +197,13 @@ jobs: with: path: synapse - - uses: actions/setup-go@v4 - - name: Prepare Complement's Prerequisites run: synapse/.ci/scripts/setup_complement_prerequisites.sh + - uses: actions/setup-go@v4 + with: + cache-dependency-path: complement/go.sum + - run: | set -o pipefail TEST_ONLY_IGNORE_POETRY_LOCKFILE=1 POSTGRES=${{ (matrix.database == 'Postgres') && 1 || '' }} WORKERS=${{ (matrix.arrangement == 'workers') && 1 || '' }} COMPLEMENT_DIR=`pwd`/complement synapse/scripts-dev/complement.sh -json 2>&1 | synapse/.ci/scripts/gotestfmt diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 12420911b4f1..86a975984e78 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -633,11 +633,13 @@ jobs: uses: dtolnay/rust-toolchain@1.61.0 - uses: Swatinem/rust-cache@v2 - - uses: actions/setup-go@v4 - - name: Prepare Complement's Prerequisites run: synapse/.ci/scripts/setup_complement_prerequisites.sh + - uses: actions/setup-go@v4 + with: + cache-dependency-path: complement/go.sum + # use p=1 concurrency as GHA boxes are underpowered and don't like running tons of synapses at once. - run: | set -o pipefail diff --git a/.github/workflows/twisted_trunk.yml b/.github/workflows/twisted_trunk.yml index 062f782e8b77..3e21e903ee5c 100644 --- a/.github/workflows/twisted_trunk.yml +++ b/.github/workflows/twisted_trunk.yml @@ -168,11 +168,13 @@ jobs: with: path: synapse - - uses: actions/setup-go@v4 - - name: Prepare Complement's Prerequisites run: synapse/.ci/scripts/setup_complement_prerequisites.sh + - uses: actions/setup-go@v4 + with: + cache-dependency-path: complement/go.sum + # This step is specific to the 'Twisted trunk' test run: - name: Patch dependencies run: | From aa5332bd74a10539a3f87a15b91570aae4c19ac5 Mon Sep 17 00:00:00 2001 From: David Robertson Date: Sat, 28 Oct 2023 19:14:38 +0100 Subject: [PATCH 2/4] Changelog --- changelog.d/16567.misc | 1 + 1 file changed, 1 insertion(+) create mode 100644 changelog.d/16567.misc diff --git a/changelog.d/16567.misc b/changelog.d/16567.misc new file mode 100644 index 000000000000..8cedf0f11e73 --- /dev/null +++ b/changelog.d/16567.misc @@ -0,0 +1 @@ +Run actions/setup-go after checking out complement. From 6e7e714022501d3ebdea74d43652e82ddb906316 Mon Sep 17 00:00:00 2001 From: David Robertson Date: Sun, 29 Oct 2023 20:42:45 +0000 Subject: [PATCH 3/4] Also pull go version from go.mod --- .github/workflows/latest_deps.yml | 1 + .github/workflows/tests.yml | 1 + .github/workflows/twisted_trunk.yml | 1 + 3 files changed, 3 insertions(+) diff --git a/.github/workflows/latest_deps.yml b/.github/workflows/latest_deps.yml index 738aed7bd1af..cb801afcbf26 100644 --- a/.github/workflows/latest_deps.yml +++ b/.github/workflows/latest_deps.yml @@ -203,6 +203,7 @@ jobs: - uses: actions/setup-go@v4 with: cache-dependency-path: complement/go.sum + go-version-file: complement/go.mod - run: | set -o pipefail diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 86a975984e78..a1f714da2338 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -639,6 +639,7 @@ jobs: - uses: actions/setup-go@v4 with: cache-dependency-path: complement/go.sum + go-version-file: complement/go.mod # use p=1 concurrency as GHA boxes are underpowered and don't like running tons of synapses at once. - run: | diff --git a/.github/workflows/twisted_trunk.yml b/.github/workflows/twisted_trunk.yml index 3e21e903ee5c..1011a15390af 100644 --- a/.github/workflows/twisted_trunk.yml +++ b/.github/workflows/twisted_trunk.yml @@ -174,6 +174,7 @@ jobs: - uses: actions/setup-go@v4 with: cache-dependency-path: complement/go.sum + go-version-file: complement/go.mod # This step is specific to the 'Twisted trunk' test run: - name: Patch dependencies From 2a8dd7525c8416435dc30da9b5d532870c90661b Mon Sep 17 00:00:00 2001 From: David Robertson Date: Sun, 29 Oct 2023 20:43:29 +0000 Subject: [PATCH 4/4] Update changelog --- changelog.d/16567.misc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/changelog.d/16567.misc b/changelog.d/16567.misc index 8cedf0f11e73..858fbac7f299 100644 --- a/changelog.d/16567.misc +++ b/changelog.d/16567.misc @@ -1 +1 @@ -Run actions/setup-go after checking out complement. +Deal with warnings from running complement in CI.