From b59d97ffa75992fa72a78c5fb3ec564aec5c4ad8 Mon Sep 17 00:00:00 2001 From: akshaydeo Date: Sun, 21 Jun 2026 17:59:51 +0530 Subject: [PATCH] fixes go worspace setup for cost-accuracy and load-test --- .github/workflows/scripts/cost-accuracy-test.sh | 8 ++++++++ .github/workflows/scripts/load-test.sh | 8 ++++++++ 2 files changed, 16 insertions(+) diff --git a/.github/workflows/scripts/cost-accuracy-test.sh b/.github/workflows/scripts/cost-accuracy-test.sh index a1ebb392c9..db47087398 100755 --- a/.github/workflows/scripts/cost-accuracy-test.sh +++ b/.github/workflows/scripts/cost-accuracy-test.sh @@ -2,6 +2,14 @@ set -euo pipefail ROOT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")/../../.." && pwd)" + +# Setup Go workspace for CI (go.work is gitignored, must be regenerated) so the +# build below resolves local core/framework/plugins instead of the published +# versions pinned in transports/go.mod. Run with repo root as CWD because +# setup-go-workspace.sh's `go work use ./core` paths are repo-root-relative; the +# go.work file it writes at ${ROOT_DIR} is then auto-discovered by `go build`. +( cd "${ROOT_DIR}" && source "${ROOT_DIR}/.github/workflows/scripts/setup-go-workspace.sh" ) + COMPOSE_FILE="${ROOT_DIR}/.github/workflows/configs/docker-compose.yml" COMPOSE_PROJECT="${COMPOSE_PROJECT:-bifrost-cost-accuracy}" BENCHMARK_DIR="${BENCHMARK_DIR:-${ROOT_DIR}/../bifrost-benchmarking}" diff --git a/.github/workflows/scripts/load-test.sh b/.github/workflows/scripts/load-test.sh index d690ad269e..799aff3098 100755 --- a/.github/workflows/scripts/load-test.sh +++ b/.github/workflows/scripts/load-test.sh @@ -20,6 +20,14 @@ set -Ee # Configuration SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)" REPO_ROOT="$(cd "${SCRIPT_DIR}/../../.." && pwd)" + +# Setup Go workspace for CI (go.work is gitignored, must be regenerated) so the +# build below resolves local core/framework/plugins instead of the published +# versions pinned in transports/go.mod. Run with repo root as CWD because +# setup-go-workspace.sh's `go work use ./core` paths are repo-root-relative; the +# go.work file it writes at ${REPO_ROOT} is then auto-discovered by `go build`. +( cd "${REPO_ROOT}" && source "${SCRIPT_DIR}/setup-go-workspace.sh" ) + BIFROST_HTTP_DIR="${REPO_ROOT}/transports/bifrost-http" TRANSPORTS_DIR="${REPO_ROOT}/transports" WORK_DIR="${SCRIPT_DIR}"