From ba4b58ed1648a88731a83ff21adbe23c064af197 Mon Sep 17 00:00:00 2001 From: Gareth Fuller Date: Mon, 16 Sep 2024 10:54:35 +0100 Subject: [PATCH 1/2] chore: Cleanup env vars --- .env.template | 5 ++--- .github/workflows/checks.yml | 2 +- test/anvil/anvil-setup.ts | 12 +++++++----- 3 files changed, 10 insertions(+), 9 deletions(-) diff --git a/.env.template b/.env.template index cff52df04..1f3bb2a2f 100644 --- a/.env.template +++ b/.env.template @@ -3,14 +3,13 @@ NEXT_PUBLIC_BALANCER_API_URL=https://api-v3.balancer.fi/graphql NEXT_PUBLIC_WALLET_CONNECT_ID=1b6b722470b504a53cf011e1e629a9eb # For wallet checks (optional) -PRIVATE_HYPERNATIVE_EMAIL=xxx -PRIVATE_HYPERNATIVE_PASSWORD=xxx +PRIVATE_HYPERNATIVE_API_ID=xxx +PRIVATE_HYPERNATIVE_API_SECRET=xxx # For fiat currency conversions (optional) PRIVATE_CURRENCYAPI_KEY=xxx # For integration tests and rpc proxy routes -NEXT_PRIVATE_INFURA_KEY=xxx PRIVATE_ALCHEMY_KEY=xxx diff --git a/.github/workflows/checks.yml b/.github/workflows/checks.yml index efc20db02..8dc816690 100644 --- a/.github/workflows/checks.yml +++ b/.github/workflows/checks.yml @@ -6,7 +6,7 @@ on: env: NEXT_PUBLIC_BALANCER_API_URL: https://api-v3.balancer.fi/graphql NEXT_PUBLIC_WALLET_CONNECT_ID: ${{ secrets.NEXT_PUBLIC_WALLET_CONNECT_ID }} - NEXT_PRIVATE_INFURA_KEY: ${{ secrets.NEXT_PRIVATE_INFURA_KEY }} + PRIVATE_ALCHEMY_KEY: ${{ secrets.PRIVATE_ALCHEMY_KEY }} jobs: Build: diff --git a/test/anvil/anvil-setup.ts b/test/anvil/anvil-setup.ts index 6d13fa29a..baa6388e7 100644 --- a/test/anvil/anvil-setup.ts +++ b/test/anvil/anvil-setup.ts @@ -85,15 +85,17 @@ export function getTestRpcSetup(networkName: NetworksWithFork) { } export function getForkUrl(network: NetworkSetup, verbose = false): string { - const privateInfuraKey = process.env['NEXT_PRIVATE_INFURA_KEY'] - if (privateInfuraKey) { + const privateAlchemyKey = process.env['PRIVATE_ALCHEMY_KEY'] + if (privateAlchemyKey) { if (network.networkName === 'Ethereum') { - return `https://mainnet.infura.io/v3/${privateInfuraKey}` + return `https://eth-mainnet.g.alchemy.com/v2/${privateAlchemyKey}` } if (network.networkName === 'Polygon') { - return `https://polygon-mainnet.infura.io/v3/${privateInfuraKey}` + return `https://polygon-mainnet.g.alchemy.com/v2/${privateAlchemyKey}` + } + if (network.networkName === 'Sepolia') { + return `https://eth-sepolia.g.alchemy.com/v2/${privateAlchemyKey}` } - if (network.networkName === 'Sepolia') return `https://sepolia.infura.io/v3/${privateInfuraKey}` } if (!network.fallBackRpc) { From 20ac09ab19a1be71ec461f442dd66cc7351255df Mon Sep 17 00:00:00 2001 From: Gareth Fuller Date: Mon, 16 Sep 2024 11:01:59 +0100 Subject: [PATCH 2/2] chore: Add comment --- .env.template | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.env.template b/.env.template index 1f3bb2a2f..eb2e23ad9 100644 --- a/.env.template +++ b/.env.template @@ -9,7 +9,7 @@ PRIVATE_HYPERNATIVE_API_SECRET=xxx # For fiat currency conversions (optional) PRIVATE_CURRENCYAPI_KEY=xxx -# For integration tests and rpc proxy routes +# For integration tests and rpc proxy routes (optional) PRIVATE_ALCHEMY_KEY=xxx