diff --git a/.github/actions/build-test-image/action.yml b/.github/actions/build-test-image/action.yml index 29c5fa853..2ab2bc2e7 100644 --- a/.github/actions/build-test-image/action.yml +++ b/.github/actions/build-test-image/action.yml @@ -18,6 +18,9 @@ inputs: QA_AWS_ACCOUNT_NUMBER: description: The AWS region the ECR repository is located in, should only be needed for public ECR repositories, used in configuring docker/login-action required: true + GITHUB_TOKEN: + description: GATI Token used to pull private repositories + required: true runs: using: composite @@ -32,6 +35,10 @@ runs: tag: ${{ inputs.tag }} AWS_REGION: ${{ inputs.QA_AWS_REGION }} AWS_ROLE_TO_ASSUME: ${{ inputs.QA_AWS_ROLE_TO_ASSUME }} + - name: Setup Go with private repo access + uses: ./.github/actions/setup-github-private-access + with: + gati_token: ${{ inputs.GITHUB_TOKEN }} - name: Build and Publish Test Runner if: steps.check-image.outputs.exists == 'false' uses: smartcontractkit/chainlink-github-actions/docker/build-push@fc3e0df622521019f50d772726d6bf8dc919dd38 # v2.3.19 @@ -42,6 +49,7 @@ runs: file: ./integration-tests/test.Dockerfile build-args: | SUITES="smoke soak" + GITHUB_TOKEN=${{ inputs.GITHUB_TOKEN }} AWS_REGION: ${{ inputs.QA_AWS_REGION }} AWS_ROLE_TO_ASSUME: ${{ inputs.QA_AWS_ROLE_TO_ASSUME }} - name: Print Image Built diff --git a/.github/actions/setup-github-private-access/action.yml b/.github/actions/setup-github-private-access/action.yml new file mode 100644 index 000000000..7840de6a4 --- /dev/null +++ b/.github/actions/setup-github-private-access/action.yml @@ -0,0 +1,16 @@ +name: Setup GitHub Private Repo Access +description: Uses a GATI Token to be able to pull from private repos + +inputs: + gati_token: + description: 'GATI Token used to pull private repos' + required: true + +runs: + using: 'composite' + steps: + - name: Setup Go with private repo access + shell: bash + run: | + git config --global url."https://x-access-token:${{ inputs.gati_token }}@github.com/".insteadOf "https://github.com/" + go env -w GOPRIVATE=github.com/smartcontractkit/* diff --git a/.github/workflows/golangci-lint.yml b/.github/workflows/golangci-lint.yml index 69bd691e9..b6e9ce359 100644 --- a/.github/workflows/golangci-lint.yml +++ b/.github/workflows/golangci-lint.yml @@ -51,10 +51,24 @@ jobs: golang_lint_ops: name: Golang Lint Ops runs-on: ubuntu-latest + permissions: + id-token: write + contents: read needs: [golangci-lint-version] steps: - name: Checkout sources uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 + - name: Setup GitHub Token + id: setup-github-token + uses: smartcontractkit/.github/actions/setup-github-token@9e7cc0779934cae4a9028b8588c9adb64d8ce68c # setup-github-token@0.1.2 + with: + aws-role-arn: ${{ secrets.AWS_OIDC_GLOBAL_READ_ONLY_TOKEN_ISSUER_ROLE_ARN }} + aws-lambda-url: ${{ secrets.GATI_RELENG_LAMBDA_URL }} + aws-region: ${{ secrets.QA_AWS_REGION }} + - name: Setup Go with private repo access + uses: ./.github/actions/setup-github-private-access + with: + gati_token: ${{ steps.setup-github-token.outputs.access-token }} - name: Install Nix uses: cachix/install-nix-action@3715ab1a11cac9e991980d7b4a28d80c7ebdd8f9 # nix:v2.24.6 with: @@ -74,10 +88,24 @@ jobs: golang_lint_integration_tests: name: Golang Lint Integration Tests runs-on: ubuntu-latest + permissions: + id-token: write + contents: read needs: [golangci-lint-version] steps: - name: Checkout sources uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 + - name: Setup GitHub Token + id: setup-github-token + uses: smartcontractkit/.github/actions/setup-github-token@9e7cc0779934cae4a9028b8588c9adb64d8ce68c # setup-github-token@0.1.2 + with: + aws-role-arn: ${{ secrets.AWS_OIDC_GLOBAL_READ_ONLY_TOKEN_ISSUER_ROLE_ARN }} + aws-lambda-url: ${{ secrets.GATI_RELENG_LAMBDA_URL }} + aws-region: ${{ secrets.QA_AWS_REGION }} + - name: Setup Go with private repo access + uses: ./.github/actions/setup-github-private-access + with: + gati_token: ${{ steps.setup-github-token.outputs.access-token }} - name: Install Nix uses: cachix/install-nix-action@3715ab1a11cac9e991980d7b4a28d80c7ebdd8f9 # nix:v2.24.6 with: diff --git a/.github/workflows/integration-tests-smoke.yml b/.github/workflows/integration-tests-smoke.yml index c87094d24..1efe9c5eb 100644 --- a/.github/workflows/integration-tests-smoke.yml +++ b/.github/workflows/integration-tests-smoke.yml @@ -109,6 +109,13 @@ jobs: hostname: ${{ secrets.GRAFANA_INTERNAL_HOST }} this-job-name: Build Test Image continue-on-error: true + - name: Setup GitHub Token + id: setup-github-token + uses: smartcontractkit/.github/actions/setup-github-token@9e7cc0779934cae4a9028b8588c9adb64d8ce68c # setup-github-token@0.1.2 + with: + aws-role-arn: ${{ secrets.AWS_OIDC_GLOBAL_READ_ONLY_TOKEN_ISSUER_ROLE_ARN }} + aws-lambda-url: ${{ secrets.GATI_RELENG_LAMBDA_URL }} + aws-region: ${{ secrets.QA_AWS_REGION }} - name: Checkout the repo uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # v4.1.1 with: @@ -119,6 +126,7 @@ jobs: QA_AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }} QA_AWS_ACCOUNT_NUMBER: ${{ secrets.QA_AWS_ACCOUNT_NUMBER }} + GITHUB_TOKEN: ${{ steps.setup-github-token.outputs.access-token }} run_tests: name: Run Smoke Tests ${{matrix.image.name}} @@ -162,6 +170,13 @@ jobs: nix_path: nixpkgs=channel:nixos-unstable - name: Install Cairo uses: ./.github/actions/install-cairo + - name: Setup GitHub Token + id: setup-github-token + uses: smartcontractkit/.github/actions/setup-github-token@9e7cc0779934cae4a9028b8588c9adb64d8ce68c # setup-github-token@0.1.2 + with: + aws-role-arn: ${{ secrets.AWS_OIDC_GLOBAL_READ_ONLY_TOKEN_ISSUER_ROLE_ARN }} + aws-lambda-url: ${{ secrets.GATI_RELENG_LAMBDA_URL }} + aws-region: ${{ secrets.QA_AWS_REGION }} - name: Build contracts run: | cd contracts && scarb --profile release build @@ -184,7 +199,7 @@ jobs: # shellcheck disable=SC2086 echo "BASE64_CONFIG_OVERRIDE=$BASE64_CONFIG_OVERRIDE" >> $GITHUB_ENV - name: Run Tests ${{ matrix.image.name }} - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@00c164251be2a7c5b2b23a6e5f7014982f232c14 # v2.3.31 + uses: smartcontractkit/.github/actions/ctf-run-tests@002596f65dc8eb807f5c8729dc1080921f7d0b24 # 0.2.1 with: aws_registries: ${{ secrets.QA_AWS_ACCOUNT_NUMBER }} test_command_to_run: nix develop -c sh -c "make test=${{ matrix.image.test-name }} test-integration-smoke-ci" @@ -197,6 +212,7 @@ jobs: QA_AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }} QA_KUBECONFIG: ${{ secrets.QA_KUBECONFIG }} artifacts_location: /home/runner/work/chainlink-starknet/chainlink-starknet/integration-tests/smoke/logs + gati_token: ${{ steps.setup-github-token.outputs.access-token }} env: KILLGRAVE_INTERNAL_IMAGE: ${{ secrets.QA_AWS_ACCOUNT_NUMBER }}.dkr.ecr.${{ secrets.QA_AWS_REGION }}.amazonaws.com/friendsofgo/killgrave CHAINLINK_IMAGE: ${{ env.CL_ECR }} diff --git a/.github/workflows/integration-tests-soak.yml b/.github/workflows/integration-tests-soak.yml index 204537d98..0d0a3ce63 100644 --- a/.github/workflows/integration-tests-soak.yml +++ b/.github/workflows/integration-tests-soak.yml @@ -68,7 +68,7 @@ jobs: echo "::add-mask::$BASE64_CONFIG_OVERRIDE" echo "BASE64_CONFIG_OVERRIDE=$BASE64_CONFIG_OVERRIDE" >> "$GITHUB_ENV" - name: Run Tests - uses: smartcontractkit/chainlink-github-actions/chainlink-testing-framework/run-tests@00c164251be2a7c5b2b23a6e5f7014982f232c14 # v2.3.31 + uses: smartcontractkit/.github/actions/ctf-run-tests@002596f65dc8eb807f5c8729dc1080921f7d0b24 # 0.2.1 with: aws_registries: ${{ secrets.QA_AWS_ACCOUNT_NUMBER }} test_command_to_run: cd ./integration-tests && go test -timeout 24h -count=1 -run TestOCRBasicSoak/embedded ./soak diff --git a/.github/workflows/relayer.yml b/.github/workflows/relayer.yml index 11e110087..8815e75a3 100644 --- a/.github/workflows/relayer.yml +++ b/.github/workflows/relayer.yml @@ -59,6 +59,9 @@ jobs: check-tidy: runs-on: ubuntu-latest + permissions: + id-token: write + contents: read steps: - name: Checkout uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 @@ -66,6 +69,17 @@ jobs: uses: actions/setup-go@0c52d547c9bc32b1aa3301fd7a9cb496313a4491 # v5.0.0 with: go-version-file: "relayer/go.mod" + - name: Setup GitHub Token + id: setup-github-token + uses: smartcontractkit/.github/actions/setup-github-token@9e7cc0779934cae4a9028b8588c9adb64d8ce68c # setup-github-token@0.1.2 + with: + aws-role-arn: ${{ secrets.AWS_OIDC_GLOBAL_READ_ONLY_TOKEN_ISSUER_ROLE_ARN }} + aws-lambda-url: ${{ secrets.GATI_RELENG_LAMBDA_URL }} + aws-region: ${{ secrets.QA_AWS_REGION }} + - name: Setup Go with private repo access + uses: ./.github/actions/setup-github-private-access + with: + gati_token: ${{ steps.setup-github-token.outputs.access-token }} - name: Ensure "make gomodtidy" has been run run: | make gomodtidy diff --git a/.golangci.yml b/.golangci.yml index 8765d4b10..480ec761a 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -147,4 +147,9 @@ issues: - path: test text: "^G404:" linters: - - gosec \ No newline at end of file + - gosec + # TODO: re-add gpp op file once we integrate into workflows + - path: "common/gauntlet_plus_plus_common.go" + text: ".*" + linters: + - unused diff --git a/Makefile b/Makefile index 7cdd24af0..bea87f567 100644 --- a/Makefile +++ b/Makefile @@ -170,15 +170,15 @@ format-ts-check: .PHONY: lint-go-ops lint-go-ops: - cd ./ops && golangci-lint --color=always --out-format checkstyle:golangci-lint-ops-report.xml run + cd ./ops && golangci-lint --config ../.golangci.yml --color=always --out-format checkstyle:golangci-lint-ops-report.xml run .PHONY: lint-go-relayer lint-go-relayer: - cd ./relayer && golangci-lint --color=always --out-format checkstyle:golangci-lint-relayer-report.xml run + cd ./relayer && golangci-lint --config ../.golangci.yml --color=always --out-format checkstyle:golangci-lint-relayer-report.xml run .PHONY: lint-go-test lint-go-test: - cd ./integration-tests && golangci-lint --color=always --exclude=dot-imports --out-format checkstyle:golangci-lint-integration-tests-report.xml run + cd ./integration-tests && golangci-lint --config ../.golangci.yml --color=always --exclude=dot-imports --out-format checkstyle:golangci-lint-integration-tests-report.xml run .PHONY: test-go test-go: test-unit-go test-unit-go-race test-integration-go diff --git a/integration-tests/common/gauntlet_plus_plus_common.go b/integration-tests/common/gauntlet_plus_plus_common.go new file mode 100644 index 000000000..79f745fe7 --- /dev/null +++ b/integration-tests/common/gauntlet_plus_plus_common.go @@ -0,0 +1,57 @@ +package common + +import ( + "encoding/json" + "os" +) + +func (m *OCRv2TestState) deployAccessControllerWithGpp() error { + var err error + m.Contracts.AccessControllerAddr, err = m.Clients.GauntletPPClient.DeployAccessControllerContract(m.Account.Account) + if err != nil { + return err + } + err = os.Setenv("BILLING_ACCESS_CONTROLLER", m.Contracts.AccessControllerAddr) + if err != nil { + return err + } + return nil +} + +func (m *OCRv2TestState) declareLinkToken() error { + err := m.Clients.GauntletPPClient.DeclareLinkTokenContract() + if err != nil { + return err + } + + return nil +} + +func (m *OCRv2TestState) deployLinkTokenWithGpp() error { + var err error + m.Contracts.LinkTokenAddr, err = m.Clients.GauntletPPClient.DeployLinkTokenContract(m.Account.Account) + + if err != nil { + return err + } + + err = os.Setenv("LINK", m.Contracts.LinkTokenAddr) + if err != nil { + return err + } + return nil +} + +func (m *OCRv2TestState) setConfigDetailsWithGpp(ocrAddress string) error { + cfg, err := m.LoadOCR2Config() + if err != nil { + return err + } + var parsedConfig []byte + parsedConfig, err = json.Marshal(cfg) + if err != nil { + return err + } + _, err = m.Clients.GauntletPPClient.SetConfigDetails(string(parsedConfig), ocrAddress) + return err +} diff --git a/integration-tests/common/test_common.go b/integration-tests/common/test_common.go index 29bfdf494..2bcc9b191 100644 --- a/integration-tests/common/test_common.go +++ b/integration-tests/common/test_common.go @@ -56,13 +56,14 @@ type AccountDetails struct { // Clients to access internal methods type Clients struct { - StarknetClient *starknet.Client - DevnetClient *starknetdevnet.DevNet - KillgraveClient *test_env_ctf.Killgrave - OCR2Client *ocr2.Client - ChainlinkClient *ChainlinkClient - GauntletClient *gauntlet.StarknetGauntlet - DockerEnv *StarknetClusterTestEnv + StarknetClient *starknet.Client + DevnetClient *starknetdevnet.DevNet + KillgraveClient *test_env_ctf.Killgrave + OCR2Client *ocr2.Client + ChainlinkClient *ChainlinkClient + GauntletClient *gauntlet.StarknetGauntlet + DockerEnv *StarknetClusterTestEnv + GauntletPPClient *gauntlet.StarknetGauntletPlusPlus } // Contracts to store current deployed contract state @@ -212,6 +213,7 @@ func (m *OCRv2TestState) DeployCluster() { m.Clients.ChainlinkClient.NKeys, m.TestConfig.err = m.Common.CreateNodeKeysBundle(m.Clients.DockerEnv.CLClusterTestEnv.ClCluster.NodeAPIs()) require.NoError(m.TestConfig.T, m.TestConfig.err) } + lggr := logger.Nop() m.Clients.StarknetClient, m.TestConfig.err = starknet.NewClient(m.Common.ChainDetails.ChainID, m.Common.RPCDetails.RPCL2External, m.Common.RPCDetails.RPCL2InternalAPIKey, lggr, &rpcRequestTimeout) require.NoError(m.TestConfig.T, m.TestConfig.err, "Creating starknet client should not fail") diff --git a/integration-tests/go.mod b/integration-tests/go.mod index 9dc615bba..462549dc6 100644 --- a/integration-tests/go.mod +++ b/integration-tests/go.mod @@ -57,6 +57,7 @@ require ( github.com/XSAM/otelsql v0.27.0 // indirect github.com/alecthomas/units v0.0.0-20240626203959-61d1e3462e30 // indirect github.com/andybalholm/brotli v1.1.0 // indirect + github.com/apapsch/go-jsonmerge/v2 v2.0.0 // indirect github.com/armon/go-metrics v0.4.1 // indirect github.com/asaskevich/govalidator v0.0.0-20230301143203-a9d515a09cc2 // indirect github.com/atombender/go-jsonschema v0.16.1-0.20240916205339-a74cd4e2851c // indirect @@ -166,6 +167,7 @@ require ( github.com/gagliardetto/treeout v0.1.4 // indirect github.com/gballet/go-libpcsclite v0.0.0-20191108122812-4678299bea08 // indirect github.com/gballet/go-verkle v0.1.1-0.20231031103413-a67434b50f46 // indirect + github.com/getkin/kin-openapi v0.120.0 // indirect github.com/getsentry/sentry-go v0.23.0 // indirect github.com/gin-contrib/sessions v0.0.5 // indirect github.com/gin-contrib/sse v0.1.0 // indirect @@ -267,6 +269,7 @@ require ( github.com/imdario/mergo v0.3.16 // indirect github.com/inconshreveable/mousetrap v1.1.0 // indirect github.com/invopop/jsonschema v0.12.0 // indirect + github.com/invopop/yaml v0.2.0 // indirect github.com/jackc/chunkreader/v2 v2.0.1 // indirect github.com/jackc/pgconn v1.14.3 // indirect github.com/jackc/pgio v1.0.0 // indirect @@ -321,6 +324,7 @@ require ( github.com/moby/term v0.5.0 // indirect github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect github.com/modern-go/reflect2 v1.0.2 // indirect + github.com/mohae/deepcopy v0.0.0-20170929034955-c48cc78d4826 // indirect github.com/monochromegane/go-gitignore v0.0.0-20200626010858-205db1a8cc00 // indirect github.com/montanaflynn/stats v0.7.1 // indirect github.com/morikuni/aec v1.0.0 // indirect @@ -330,6 +334,7 @@ require ( github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect github.com/mwitkow/go-conntrack v0.0.0-20190716064945-2f068394615f // indirect github.com/mxk/go-flowrate v0.0.0-20140419014527-cca7078d478f // indirect + github.com/oapi-codegen/runtime v1.1.1 // indirect github.com/oklog/run v1.1.0 // indirect github.com/oklog/ulid v1.3.1 // indirect github.com/olekukonko/tablewriter v0.0.5 // indirect @@ -342,6 +347,7 @@ require ( github.com/patrickmn/go-cache v2.1.0+incompatible // indirect github.com/pbnjay/memory v0.0.0-20210728143218-7b4eea64cf58 // indirect github.com/pelletier/go-toml v1.9.5 // indirect + github.com/perimeterx/marshmallow v1.1.5 // indirect github.com/peterbourgon/diskv v2.0.1+incompatible // indirect github.com/petermattis/goid v0.0.0-20230317030725-371a4b8eda08 // indirect github.com/pkg/browser v0.0.0-20240102092130-5ac0b6a4141c // indirect @@ -385,6 +391,7 @@ require ( github.com/smartcontractkit/chainlink-solana v1.1.1-0.20241010140936-4e1d0ae8315a // indirect github.com/smartcontractkit/chainlink-testing-framework/lib/grafana v1.50.0 // indirect github.com/smartcontractkit/chainlink-testing-framework/wasp v1.50.0 // indirect + github.com/smartcontractkit/gauntlet-plus-plus/sdks/go-gauntlet v1.1.3 // indirect github.com/smartcontractkit/grpc-proxy v0.0.0-20240830132753-a7e17fec5ab7 // indirect github.com/smartcontractkit/libocr v0.0.0-20241007185508-adbe57025f12 // indirect github.com/smartcontractkit/tdh2/go/ocr2/decryptionplugin v0.0.0-20241009055228-33d0c0bf38de // indirect diff --git a/integration-tests/go.sum b/integration-tests/go.sum index 3a2db62c0..73d7c2cfa 100644 --- a/integration-tests/go.sum +++ b/integration-tests/go.sum @@ -136,6 +136,7 @@ github.com/Nvveen/Gotty v0.0.0-20120604004816-cd527374f1e5/go.mod h1:lmUJ/7eu/Q8 github.com/OneOfOne/xxhash v1.2.2/go.mod h1:HSdplMjZKSmBqAxg5vPj2TmRDmfkzw+cTzAElWljhcU= github.com/OneOfOne/xxhash v1.2.8 h1:31czK/TI9sNkxIKfaUfGlU47BAxQ0ztGgd9vPyqimf8= github.com/OneOfOne/xxhash v1.2.8/go.mod h1:eZbhyaAYD41SGSSsnmcpxVoRiQ/MPUTjUdIIOT9Um7Q= +github.com/RaveNoX/go-jsoncommentstrip v1.0.0/go.mod h1:78ihd09MekBnJnxpICcwzCMzGrKSKYe4AqU6PDYYpjk= github.com/VictoriaMetrics/fastcache v1.12.1 h1:i0mICQuojGDL3KblA7wUNlY5lOK6a4bwt3uRKnkZU40= github.com/VictoriaMetrics/fastcache v1.12.1/go.mod h1:tX04vaqcNoQeGLD+ra5pU5sWkuxnzWhEzLwhP9w653o= github.com/VividCortex/gohistogram v1.0.0 h1:6+hBz+qvs0JOrrNhhmR7lFxo5sINxBCGXrdtl/UvroE= @@ -168,6 +169,8 @@ github.com/andreyvit/diff v0.0.0-20170406064948-c7f18ee00883/go.mod h1:rCTlJbsFo github.com/andybalholm/brotli v1.1.0 h1:eLKJA0d02Lf0mVpIDgYnqXcUn0GqVmEFny3VuID1U3M= github.com/andybalholm/brotli v1.1.0/go.mod h1:sms7XGricyQI9K10gOSf56VKKWS4oLer58Q+mhRPtnY= github.com/antihax/optional v1.0.0/go.mod h1:uupD/76wgC+ih3iEmQUL+0Ugr19nfwCT1kdvxnR2qWY= +github.com/apapsch/go-jsonmerge/v2 v2.0.0 h1:axGnT1gRIfimI7gJifB699GoE/oq+F2MU7Dml6nw9rQ= +github.com/apapsch/go-jsonmerge/v2 v2.0.0/go.mod h1:lvDnEdqiQrp0O42VQGgmlKpxL1AP2+08jFMw88y4klk= github.com/armon/circbuf v0.0.0-20150827004946-bbbad097214e/go.mod h1:3U/XgcO3hCbHZ8TKRvWD2dDTCfh9M9ya+I9JpbB7O8o= github.com/armon/consul-api v0.0.0-20180202201655-eb2c6b5be1b6/go.mod h1:grANhF5doyWs3UAsr3K4I6qtAmlQcZDesFNEHPZAzj8= github.com/armon/go-metrics v0.0.0-20180917152333-f0300d1749da/go.mod h1:Q73ZrmVTwzkszR9V5SSuryQ31EELlFMUz1kKyl939pY= @@ -249,6 +252,7 @@ github.com/blang/semver/v4 v4.0.0 h1:1PFHFE6yCCTv8C1TeyNNarDzntLi7wMI5i/pzqYIsAM github.com/blang/semver/v4 v4.0.0/go.mod h1:IbckMUScFkM3pff0VJDNKRiT6TG/YpiHIM2yvyW5YoQ= github.com/blendle/zapdriver v1.3.1 h1:C3dydBOWYRiOk+B8X9IVZ5IOe+7cl+tGOexN4QqHfpE= github.com/blendle/zapdriver v1.3.1/go.mod h1:mdXfREi6u5MArG4j9fewC+FGnXaBR+T4Ox4J2u4eHCc= +github.com/bmatcuk/doublestar v1.1.1/go.mod h1:UD6OnuiIn0yFxxA2le/rnRU1G4RaI4UvFv1sNto9p6w= github.com/btcsuite/btcd v0.22.1 h1:CnwP9LM/M9xuRrGSCGeMVs9iv09uMqwsVX7EeIpgV2c= github.com/btcsuite/btcd/btcec/v2 v2.3.2 h1:5n0X6hX0Zk+6omWcihdYvdAlGf2DfasC0GMf7DClJ3U= github.com/btcsuite/btcd/btcec/v2 v2.3.2/go.mod h1:zYzJ8etWJQIv1Ogk7OzpWjowwOdXY1W/17j2MW85J04= @@ -515,6 +519,8 @@ github.com/gballet/go-verkle v0.1.1-0.20231031103413-a67434b50f46 h1:BAIP2Gihuqh github.com/gballet/go-verkle v0.1.1-0.20231031103413-a67434b50f46/go.mod h1:QNpY22eby74jVhqH4WhDLDwxc/vqsern6pW+u2kbkpc= github.com/gedex/inflector v0.0.0-20170307190818-16278e9db813 h1:Uc+IZ7gYqAf/rSGFplbWBSHaGolEQlNLgMgSE3ccnIQ= github.com/gedex/inflector v0.0.0-20170307190818-16278e9db813/go.mod h1:P+oSoE9yhSRvsmYyZsshflcR6ePWYLql6UU1amW13IM= +github.com/getkin/kin-openapi v0.120.0 h1:MqJcNJFrMDFNc07iwE8iFC5eT2k/NPUFDIpNeiZv8Jg= +github.com/getkin/kin-openapi v0.120.0/go.mod h1:PCWw/lfBrJY4HcdqE3jj+QFkaFK8ABoqo7PvqVhXXqw= github.com/getsentry/sentry-go v0.23.0 h1:dn+QRCeJv4pPt9OjVXiMcGIBIefaTJPw/h0bZWO05nE= github.com/getsentry/sentry-go v0.23.0/go.mod h1:lc76E2QywIyW8WuBnwl8Lc4bkmQH4+w1gwTf25trprY= github.com/ghodss/yaml v1.0.0/go.mod h1:4dBDuWmgqj2HViK6kFavaiC9ZROes6MMH2rRYeMEF04= @@ -600,8 +606,9 @@ github.com/go-task/slim-sprig v0.0.0-20210107165309-348f09dbbbc0/go.mod h1:fyg78 github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572 h1:tfuBGBXKqDEevZMzYi5KSi8KkcZtzBcTgAUUtapy0OI= github.com/go-task/slim-sprig/v3 v3.0.0 h1:sUs3vkvUymDpBKi3qH1YSqBQk9+9D/8M2mN1vB6EwHI= github.com/go-task/slim-sprig/v3 v3.0.0/go.mod h1:W848ghGpv3Qj3dhTPRyJypKRiqCdHZiAzKg9hl15HA8= -github.com/go-test/deep v1.0.4 h1:u2CU3YKy9I2pmu9pX0eq50wCgjfGIt539SqR7FbHiho= github.com/go-test/deep v1.0.4/go.mod h1:wGDj63lr65AM2AQyKZd/NYHGb0R+1RLqB8NKt3aSFNA= +github.com/go-test/deep v1.0.8 h1:TDsG77qcSprGbC6vTN8OuXp5g+J+b5Pcguhf7Zt61VM= +github.com/go-test/deep v1.0.8/go.mod h1:5C2ZWiW0ErCdrYzpqxLbTX7MG14M9iiw8DgHncVwcsE= github.com/go-viper/mapstructure/v2 v2.1.0 h1:gHnMa2Y/pIxElCH2GlZZ1lZSsn6XMtufpGyP1XxdC/w= github.com/go-viper/mapstructure/v2 v2.1.0/go.mod h1:oJDH3BJKyqBA2TXFhDsKDGDTlndYOZ6rGS0BRZIxGhM= github.com/go-webauthn/webauthn v0.9.4 h1:YxvHSqgUyc5AK2pZbqkWWR55qKeDPhP8zLDr6lpIc2g= @@ -907,6 +914,8 @@ github.com/inconshreveable/mousetrap v1.1.0 h1:wN+x4NVGpMsO7ErUn/mUI3vEoE6Jt13X2 github.com/inconshreveable/mousetrap v1.1.0/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= github.com/invopop/jsonschema v0.12.0 h1:6ovsNSuvn9wEQVOyc72aycBMVQFKz7cPdMJn10CvzRI= github.com/invopop/jsonschema v0.12.0/go.mod h1:ffZ5Km5SWWRAIN6wbDXItl95euhFz2uON45H2qjYt+0= +github.com/invopop/yaml v0.2.0 h1:7zky/qH+O0DwAyoobXUqvVBwgBFRxKoQ/3FjcVpjTMY= +github.com/invopop/yaml v0.2.0/go.mod h1:2XuRLgs/ouIrW3XNzuNj7J3Nvu/Dig5MXvbCEdiBN3Q= github.com/ionos-cloud/sdk-go/v6 v6.1.11 h1:J/uRN4UWO3wCyGOeDdMKv8LWRzKu6UIkLEaes38Kzh8= github.com/ionos-cloud/sdk-go/v6 v6.1.11/go.mod h1:EzEgRIDxBELvfoa/uBN0kOQaqovLjUWEB7iW4/Q+t4k= github.com/jackc/chunkreader v1.0.0/go.mod h1:RT6O25fNZIuasFJRyZ4R/Y2BbhasbmZXF9QQ7T3kePo= @@ -988,6 +997,7 @@ github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHm github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU= github.com/jstemmer/go-junit-report v0.9.1/go.mod h1:Brl9GWCQeLvo8nXZwPNNblvFj/XSXhF0NWZEnDohbsk= github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU= +github.com/juju/gnuflag v0.0.0-20171113085948-2ce1bb71843d/go.mod h1:2PavIy+JPciBPrBUjwbNvtwB6RQlve+hkpll6QSNmOE= github.com/julienschmidt/httprouter v1.2.0/go.mod h1:SYymIcj16QtmaHHD7aYtjjsJG7VTCxuUUipMqKk8s4w= github.com/julienschmidt/httprouter v1.3.0 h1:U0609e9tgbseu3rBINet9P48AI/D3oJs4dN7jwJOQ1U= github.com/julienschmidt/httprouter v1.3.0/go.mod h1:JR6WtHb+2LUe8TCKY3cZOxFyyO8IZAc4RVcycCCAKdM= @@ -1141,6 +1151,8 @@ github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lN github.com/modern-go/reflect2 v1.0.1/go.mod h1:bx2lNnkwVCuqBIxFjflWJWanXIb3RllmbCylyMrvgv0= github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M= github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= +github.com/mohae/deepcopy v0.0.0-20170929034955-c48cc78d4826 h1:RWengNIwukTxcDr9M+97sNutRR1RKhG96O6jWumTTnw= +github.com/mohae/deepcopy v0.0.0-20170929034955-c48cc78d4826/go.mod h1:TaXosZuwdSHYgviHp1DAtfrULt5eUgsSMsZf+YrPgl8= github.com/monochromegane/go-gitignore v0.0.0-20200626010858-205db1a8cc00 h1:n6/2gBQ3RWajuToeY6ZtZTIKv2v7ThUy5KKusIT0yc0= github.com/monochromegane/go-gitignore v0.0.0-20200626010858-205db1a8cc00/go.mod h1:Pm3mSP3c5uWn86xMLZ5Sa7JB9GsEZySvHYXCTK4E9q4= github.com/montanaflynn/stats v0.0.0-20171201202039-1bf9dbcd8cbe/go.mod h1:wL8QJuTMNUDYhXwkmfOly8iTdp5TEcJFWZD2D7SIkUc= @@ -1168,6 +1180,8 @@ github.com/nsf/jsondiff v0.0.0-20230430225905-43f6cf3098c1/go.mod h1:mpRZBD8SJ55 github.com/nxadm/tail v1.4.4/go.mod h1:kenIhsEOeOJmVchQTgglprH7qJGnHDVpk1VPCcaMI8A= github.com/nxadm/tail v1.4.8 h1:nPr65rt6Y5JFSKQO7qToXr7pePgD6Gwiw05lkbyAQTE= github.com/nxadm/tail v1.4.8/go.mod h1:+ncqLTQzXmGhMZNUePPaPqPvBxHAIsmXswZKocGu+AU= +github.com/oapi-codegen/runtime v1.1.1 h1:EXLHh0DXIJnWhdRPN2w4MXAzFyE4CskzhNLUmtpMYro= +github.com/oapi-codegen/runtime v1.1.1/go.mod h1:SK9X900oXmPWilYR5/WKPzt3Kqxn/uS/+lbpREv+eCg= github.com/oklog/run v1.1.0 h1:GEenZ1cK0+q0+wsJew9qUg/DyD8k3JzYsZAi5gYi2mA= github.com/oklog/run v1.1.0/go.mod h1:sVPdnTZT1zYwAJeCMu2Th4T21pA3FPOQRfWjQlk7DVU= github.com/oklog/ulid v1.3.1 h1:EGfNDEx6MqHz8B3uNV6QAib1UR2Lm97sHi3ocA6ESJ4= @@ -1221,6 +1235,8 @@ github.com/pelletier/go-toml v1.9.5 h1:4yBQzkHv+7BHq2PQUZF3Mx0IYxG7LsP222s7Agd3v github.com/pelletier/go-toml v1.9.5/go.mod h1:u1nR/EPcESfeI/szUZKdtJ0xRNbUoANCkoOuaOx1Y+c= github.com/pelletier/go-toml/v2 v2.2.2 h1:aYUidT7k73Pcl9nb2gScu7NSrKCSHIDE89b3+6Wq+LM= github.com/pelletier/go-toml/v2 v2.2.2/go.mod h1:1t835xjRzz80PqgE6HHgN2JOsmgYu/h4qDAS4n929Rs= +github.com/perimeterx/marshmallow v1.1.5 h1:a2LALqQ1BlHM8PZblsDdidgv1mWi1DgC2UmX50IvK2s= +github.com/perimeterx/marshmallow v1.1.5/go.mod h1:dsXbUu8CRzfYP5a87xpp0xq9S3u0Vchtcl8we9tYaXw= github.com/peterbourgon/diskv v2.0.1+incompatible h1:UBdAOUP5p4RWqPBg048CAvpKN+vxiaj6gdUUzhl4XmI= github.com/peterbourgon/diskv v2.0.1+incompatible/go.mod h1:uqqh8zWWbv1HBMNONnaR/tNboyR3/BZd58JJSHlUSCU= github.com/petermattis/goid v0.0.0-20180202154549-b0b1615b78e5/go.mod h1:jvVRKCrJTQWu0XVbaOlby/2lO20uSCHEMzzplHXte1o= @@ -1392,6 +1408,8 @@ github.com/smartcontractkit/chainlink/integration-tests v0.0.0-20241012135014-37 github.com/smartcontractkit/chainlink/integration-tests v0.0.0-20241012135014-37f3132362ec/go.mod h1:kMiICu9TUtelsGy44wkwnKbFRINnsBBoAMXotfNm78Q= github.com/smartcontractkit/chainlink/v2 v2.14.0-mercury-20240807.0.20241012135014-37f3132362ec h1:CxaKhs+aBGE/shiox4nv59Oneh2B9jJv3NEtA2Q15CM= github.com/smartcontractkit/chainlink/v2 v2.14.0-mercury-20240807.0.20241012135014-37f3132362ec/go.mod h1:KbO2His3P8Lg9qcikZeZ1KdYCutV6tkoyT/sJw92bjE= +github.com/smartcontractkit/gauntlet-plus-plus/sdks/go-gauntlet v1.1.3 h1:RIApVijvhHI6iW9pyT35Nk39rPGEC4TwVe/f+YA1G5k= +github.com/smartcontractkit/gauntlet-plus-plus/sdks/go-gauntlet v1.1.3/go.mod h1:oiUkQxoi0kZzbW125oIt4lr/pqaRSDol1rWHLCyqmNQ= github.com/smartcontractkit/grpc-proxy v0.0.0-20240830132753-a7e17fec5ab7 h1:12ijqMM9tvYVEm+nR826WsrNi6zCKpwBhuApq127wHs= github.com/smartcontractkit/grpc-proxy v0.0.0-20240830132753-a7e17fec5ab7/go.mod h1:FX7/bVdoep147QQhsOPkYsPEXhGZjeYx6lBSaSXtZOA= github.com/smartcontractkit/libocr v0.0.0-20241007185508-adbe57025f12 h1:NzZGjaqez21I3DU7objl3xExTH4fxYvzTqar8DC6360= @@ -1434,6 +1452,7 @@ github.com/spf13/viper v1.7.0/go.mod h1:8WkrPz2fc9jxqZNCJI/76HCieCp4Q8HaLFoCha5q github.com/spf13/viper v1.7.1/go.mod h1:8WkrPz2fc9jxqZNCJI/76HCieCp4Q8HaLFoCha5qpdg= github.com/spf13/viper v1.19.0 h1:RWq5SEjt8o25SROyN3z2OrDB9l7RPd3lwTWU8EcEdcI= github.com/spf13/viper v1.19.0/go.mod h1:GQUN9bilAbhU/jgc1bKs99f/suXKeUMct8Adx5+Ntkg= +github.com/spkg/bom v0.0.0-20160624110644-59b7046e48ad/go.mod h1:qLr4V1qq6nMqFKkMo8ZTx3f+BZEkzsRUY10Xsm2mwU0= github.com/status-im/keycard-go v0.2.0 h1:QDLFswOQu1r5jsycloeQh3bVU8n/NatHHaZobtDnDzA= github.com/status-im/keycard-go v0.2.0/go.mod h1:wlp8ZLbsmrF6g6WjugPAx+IzoLrkdf9+mHxBEeo3Hbg= github.com/streamingfast/logging v0.0.0-20220405224725-2755dab2ce75 h1:ZqpS7rAhhKD7S7DnrpEdrnW1/gZcv82ytpMviovkli4= @@ -2146,6 +2165,7 @@ gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= +gopkg.in/yaml.v3 v3.0.0/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gotest.tools v2.2.0+incompatible h1:VsBPFP1AI068pPrMxtb/S8Zkgf9xEmTLJjfM+P5UIEo= diff --git a/integration-tests/scripts/buildTests b/integration-tests/scripts/buildTests index ed2ec1132..7e60f9d2d 100755 --- a/integration-tests/scripts/buildTests +++ b/integration-tests/scripts/buildTests @@ -10,6 +10,14 @@ SCRIPT_DIR=$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")" &>/dev/null && pwd) helm repo update +if [ -n "$2" ]; then + temp2="${2%\"}" + github_token="${temp2#\"}" +fi + +git config --global url."https://x-access-token:${github_token}@github.com/".insteadOf "https://github.com/" +go env -w GOPRIVATE=github.com/smartcontractkit/* + cd "$SCRIPT_DIR"/../../ || exit 1 # integration prep diff --git a/integration-tests/smoke/ocr2_test.go b/integration-tests/smoke/ocr2_test.go index 8616f61a8..289465783 100644 --- a/integration-tests/smoke/ocr2_test.go +++ b/integration-tests/smoke/ocr2_test.go @@ -73,6 +73,12 @@ func TestOCRBasic(t *testing.T) { }) } state.DeployCluster() + // Setting up G++ Client + rpcURL := state.Common.RPCDetails.RPCL2External + gppPort := "http://localhost:" + *state.TestConfig.TestConfig.Common.GauntletPlusPlusPort + state.Clients.GauntletPPClient, err = gauntlet.NewStarknetGauntletPlusPlus(gppPort, rpcURL, state.Account.Account, state.Account.PrivateKey) + require.NoError(t, err, "Setting up gauntlet ++ should not fail") + state.Clients.GauntletClient, err = gauntlet.NewStarknetGauntlet(fmt.Sprintf("%s/", utils.ProjectRoot)) require.NoError(t, err, "Setting up gauntlet should not fail") err = state.Clients.GauntletClient.SetupNetwork(state.Common.RPCDetails.RPCL2External, state.Account.Account, state.Account.PrivateKey) diff --git a/integration-tests/test.Dockerfile b/integration-tests/test.Dockerfile index 1c87a720e..dcffeab2b 100644 --- a/integration-tests/test.Dockerfile +++ b/integration-tests/test.Dockerfile @@ -1,11 +1,13 @@ FROM nixos/nix:latest ARG SUITES=smoke soak +ARG GITHUB_TOKEN="" +RUN ENV NIX_USER_CONF_FILES=/repo/nix.conf ENV PATH="/repo/cairo-build/bin:/repo/scarb-build/bin:${PATH}" COPY . /repo/ WORKDIR /repo RUN nix develop -c helm repo update -RUN nix develop -c /repo/integration-tests/scripts/buildTests "${SUITES}" +RUN nix develop -c /repo/integration-tests/scripts/buildTests "${SUITES}" "${GITHUB_TOKEN}" ENTRYPOINT ["/repo/integration-tests/scripts/entrypoint"] diff --git a/integration-tests/testconfig/testconfig.go b/integration-tests/testconfig/testconfig.go index df058391a..270608527 100644 --- a/integration-tests/testconfig/testconfig.go +++ b/integration-tests/testconfig/testconfig.go @@ -183,14 +183,16 @@ type Common struct { InsideK8s *bool `toml:"inside_k8"` User *string `toml:"user"` // if rpc requires api key to be passed as an HTTP header - L2RPCApiKey *string `toml:"l2_rpc_url_api_key"` - L2RPCUrl *string `toml:"l2_rpc_url"` - PrivateKey *string `toml:"private_key"` - Account *string `toml:"account"` - Stateful *bool `toml:"stateful_db"` - InternalDockerRepo *string `toml:"internal_docker_repo"` - DevnetImage *string `toml:"devnet_image"` - PostgresVersion *string `toml:"postgres_version"` + L2RPCApiKey *string `toml:"l2_rpc_url_api_key"` + L2RPCUrl *string `toml:"l2_rpc_url"` + PrivateKey *string `toml:"private_key"` + Account *string `toml:"account"` + Stateful *bool `toml:"stateful_db"` + InternalDockerRepo *string `toml:"internal_docker_repo"` + DevnetImage *string `toml:"devnet_image"` + GauntletPlusPlusImage *string `toml:"gauntlet_plus_plus_image"` + PostgresVersion *string `toml:"postgres_version"` + GauntletPlusPlusPort *string `toml:"gauntlet_plus_plus_port"` } func (c *Common) Validate() error { @@ -203,6 +205,9 @@ func (c *Common) Validate() error { if c.DevnetImage == nil { return fmt.Errorf("devnet_image must be set") } + if c.GauntletPlusPlusImage == nil { + return fmt.Errorf("gauntlet_plus_plus_image must be set") + } case "testnet": if c.PrivateKey == nil { return fmt.Errorf("private_key must be set") diff --git a/ops/gauntlet/gauntlet_plus_plus_starknet.go b/ops/gauntlet/gauntlet_plus_plus_starknet.go new file mode 100644 index 000000000..368a208e6 --- /dev/null +++ b/ops/gauntlet/gauntlet_plus_plus_starknet.go @@ -0,0 +1,413 @@ +package gauntlet + +import ( + "context" + "encoding/json" + "fmt" + "net/http" + + "github.com/rs/zerolog/log" + g "github.com/smartcontractkit/gauntlet-plus-plus/sdks/go-gauntlet/client" +) + +var ( + sgpp *StarknetGauntletPlusPlus +) + +type Request struct { + Input map[string]any `json:"input"` + Command string `json:"command"` +} + +type StarknetGauntletPlusPlus struct { + client *g.ClientWithResponses + gr *http.Response + providers *[]g.Provider +} + +func toPointerMap(input map[string]interface{}) map[string]*interface{} { + result := make(map[string]*interface{}) + for k, v := range input { + // Create a new variable to hold the value + valueCopy := v + // Store the pointer to the new variable + result[k] = &valueCopy + } + return result +} + +func (sgpp *StarknetGauntletPlusPlus) BuildProviders(address string, rpcURL string, privateKey string) *[]g.Provider { + accountProviderInput := map[string]interface{}{ + "address": address, + } + AccountProvider := g.Provider{ + Name: "basic-address", + Type: "@chainlink/gauntlet-starknet/lib/starknet.js/account", + Input: toPointerMap(accountProviderInput), + } + + signerProviderInput := map[string]interface{}{ + "privateKey": privateKey, + "debug": true, + } + SignerProvider := g.Provider{ + Name: "basic-pk", + Type: "@chainlink/gauntlet-starknet/lib/starknet.js/signer", + Input: toPointerMap(signerProviderInput), + } + + providerInput := map[string]interface{}{ + "url": rpcURL, + "checkStatus": false, + } + RPCProvider := g.Provider{ + Name: "basic-url", + Type: "@chainlink/gauntlet-starknet/lib/starknet.js/provider", + Input: toPointerMap(providerInput), + } + + providers := []g.Provider{AccountProvider, SignerProvider, RPCProvider} + + return &providers +} + +// New StarknetGauntletPlusPlus creates a default g++ client with responses +func NewStarknetGauntletPlusPlus(gauntletPPEndpoint string, rpcURL string, address string, privateKey string) (*StarknetGauntletPlusPlus, error) { + log.Info().Str("Creating G++ Client with Endpoint: ", gauntletPPEndpoint).Msg("Gauntlet++") + log.Info().Str("Connecting G++ Client to RPC URL: ", rpcURL).Msg("Gauntlet++") + newClient, err := g.NewClientWithResponses(gauntletPPEndpoint) + + if err != nil { + return nil, err + } + + sgpp = &StarknetGauntletPlusPlus{ + client: newClient, + gr: &http.Response{}, + providers: sgpp.BuildProviders(address, rpcURL, privateKey), + } + + return sgpp, nil +} + +func (sgpp *StarknetGauntletPlusPlus) ExtractValueFromResponseBody(report g.Report, key string) (string, error) { + if report.Output != nil { + // Attempt to assert the Output as a map + if outputMap, ok := (*report.Output).(map[string]interface{}); ok { + if value, exists := outputMap[key]; exists { + // Assert value to a string + if strValue, ok := value.(string); ok { + return strValue, nil + } + err := fmt.Errorf("parsed Value is not of type string") + return "", err + } + } + } + return "", nil +} + +func (sgpp *StarknetGauntletPlusPlus) BuildRequestBody(request Request) *g.PostExecuteJSONRequestBody { + var args any = request.Input + + body := g.PostExecuteJSONRequestBody{ + Config: &g.Config{ + Providers: *sgpp.providers, + Datasources: []g.Datasource{}, + }, + Operation: g.Operation{ + Args: &args, + Name: request.Command, + }, + } + + return &body +} + +func (sgpp *StarknetGauntletPlusPlus) execute(request *Request) error { + body := sgpp.BuildRequestBody(*request) + + tmp, err := json.Marshal(body) + if err != nil { + return err // Handle marshaling error + } + + // Show request body + log.Info().Str("Request Body: ", string(tmp)).Msg("Gauntlet++") + + headers := &g.PostExecuteParams{} + response, err := sgpp.client.PostExecuteWithResponse(context.Background(), headers, *body) + if err != nil { + return err // Handle post execution error + } + + // Show Response Status + log.Info().Str("Response Status:", response.Status()).Msg("Gauntlet++") + return nil +} + +func (sgpp *StarknetGauntletPlusPlus) executeReturnsReport(request *Request) (g.Report, error) { + body := sgpp.BuildRequestBody(*request) + + tmp, err := json.Marshal(body) + if err != nil { + return g.Report{}, err // Handle marshaling error + } + + // Show request body + log.Info().Str("Request Body: ", string(tmp)).Msg("Gauntlet++") + + headers := &g.PostExecuteParams{} + response, err := sgpp.client.PostExecuteWithResponse(context.Background(), headers, *body) + if err != nil { + return g.Report{}, err // Handle post execution error + } + + return *response.JSON200, nil +} + +func (sgpp *StarknetGauntletPlusPlus) executeDeploy(request *Request) (string, error) { + report, err := sgpp.executeReturnsReport(request) + + if err != nil { + return "", err // Handle post execution error + } + contractAddress, err := sgpp.ExtractValueFromResponseBody(report, "contractAddress") + if err != nil { + log.Err(err).Str("G++ Request returned with err", err.Error()).Msg("Gauntlet++") + return "", err + } + + return contractAddress, nil +} + +func (sgpp *StarknetGauntletPlusPlus) TransferToken(tokenAddress string, to string, from string) error { + inputMap := map[string]interface{}{ + "to": to, + "from": from, + "address": tokenAddress, + } + + request := Request{ + Command: "starknet/token/erc20:transfer", + Input: inputMap, + } + + return sgpp.execute(&request) +} + +func (sgpp *StarknetGauntletPlusPlus) DeclareOCR2Controllercontract() error { + inputMap := make(map[string]interface{}) + request := Request{ + Command: "starknet/data-feeds/aggregator@1.0.0:declare", + Input: inputMap, + } + + return sgpp.execute(&request) +} + +func (sgpp *StarknetGauntletPlusPlus) DeployOCR2ControllerContract(minSubmissionValue int64, maxSubmissionValue int64, decimals int, name string, + linkTokenAddress string, address string, accessControllerAddress string) (string, error) { + // Delare Contract First + err := sgpp.DeclareOCR2Controllercontract() + if err != nil { + return "", err + } + + constructorCalldata := map[string]interface{}{ + "owner": address, + "link": linkTokenAddress, + "minAnswer": minSubmissionValue, + "maxAnswer": maxSubmissionValue, + "billingAccessController": accessControllerAddress, + "decimals": decimals, + "description": "USDT/LINK", + } + inputMap := map[string]interface{}{ + "constructorCalldata": &constructorCalldata, + } + + request := Request{ + Command: "starknet/data-feeds/aggregator@1.0.0:deploy", + Input: inputMap, + } + + return sgpp.executeDeploy(&request) +} + +func (sgpp *StarknetGauntletPlusPlus) DeclareOCR2ControllerProxyContract() error { + inputMap := make(map[string]interface{}) + request := Request{ + Command: "starknet/data-feeds/aggregator-proxy@1.0.0:declare", + Input: inputMap, + } + return sgpp.execute(&request) +} + +func (sgpp *StarknetGauntletPlusPlus) DeployOCR2ControllerProxyContract(address string, controllerContractAddress string) (string, error) { + // Declare Contract First + err := sgpp.DeclareOCR2ControllerProxyContract() + if err != nil { + return "", err + } + + constructorCalldata := map[string]interface{}{ + "owner": address, + "address": controllerContractAddress, + } + inputMap := map[string]interface{}{ + "constructorCalldata": &constructorCalldata, + } + + request := Request{ + Command: "starknet/data-feeds/aggregator-proxy@1.0.0:deploy", + Input: inputMap, + } + + return sgpp.executeDeploy(&request) +} + +func (sgpp *StarknetGauntletPlusPlus) AddAccess(aggregatorAddress string, grantAddress string) error { + inputMap := map[string]interface{}{ + "address": aggregatorAddress, + "grantAddress": grantAddress, + } + + request := Request{ + Command: "starknet/data-feeds/access-controller@1.0.0:add-access", + Input: inputMap, + } + + return sgpp.execute(&request) +} + +func (sgpp *StarknetGauntletPlusPlus) DeclareAccessControllerContract() error { + inputMap := make(map[string]interface{}) + request := Request{ + Command: "starknet/data-feeds/access-controller@1.0.0:declare", + Input: inputMap, + } + + return sgpp.execute(&request) +} + +func (sgpp *StarknetGauntletPlusPlus) DeployAccessControllerContract(address string) (string, error) { + // Declare Contract first + err := sgpp.DeclareAccessControllerContract() + if err != nil { + return "", err + } + + constructorCalldata := map[string]interface{}{ + "owner": address, + } + inputMap := map[string]interface{}{ + "constructorCalldata": &constructorCalldata, + } + + request := Request{ + Command: "starknet/token/link:declare", + Input: inputMap, + } + return sgpp.executeDeploy(&request) +} + +func (sgpp *StarknetGauntletPlusPlus) DeclareLinkTokenContract() error { + inputMap := make(map[string]interface{}) + request := Request{ + Command: "starknet/token/link:declare", + Input: inputMap, + } + + return sgpp.execute(&request) +} + +func (sgpp *StarknetGauntletPlusPlus) DeployLinkTokenContract(address string) (string, error) { + // Declare token first + err := sgpp.DeclareLinkTokenContract() + + if err != nil { + return "", err + } + + inputMap := map[string]interface{}{ + "minter": address, + "owner": address, + } + + request := Request{ + Command: "starknet/token/link:deploy", + Input: inputMap, + } + + return sgpp.executeDeploy(&request) +} + +func (sgpp *StarknetGauntletPlusPlus) SetConfigDetails(cfg string, ocrAddress string) (g.Report, error) { + txArgs := make(map[string]interface{}) + err := json.Unmarshal([]byte(cfg), &txArgs) + if err != nil { + // Handle the error appropriately (return, log, etc.) + return g.Report{}, nil + } + inputMap := map[string]interface{}{ + "address": ocrAddress, + "txArgs": &txArgs, + } + request := Request{ + Command: "starknet/data-feeds/aggregator@1.0.0:set-config", + Input: inputMap, + } + return sgpp.executeReturnsReport(&request) +} + +func (sgpp *StarknetGauntletPlusPlus) SetOCRBilling(observationPaymentGjuels int64, transmissionPaymentGjuels int64, ocrAddress string) (g.Report, error) { + txArgs := map[string]interface{}{ + "transmissionPaymentGjuels": transmissionPaymentGjuels, + "observationPaymentGjuels": observationPaymentGjuels, + "gasPerSignature": "0", + "gasBase": "0", + } + inputMap := map[string]interface{}{ + "address": ocrAddress, + "txArgs": &txArgs, + } + + request := Request{ + Command: "starknet/data-feeds/aggregator@1.0.0:set-billing", + Input: inputMap, + } + + return sgpp.executeReturnsReport(&request) +} + +func (sgpp *StarknetGauntletPlusPlus) DeclareOzAccount() error { + inputMap := make(map[string]interface{}) + request := Request{ + Command: "starknet/chain/open-zeppelin:declare", + Input: inputMap, + } + + return sgpp.execute(&request) +} + +func (sgpp *StarknetGauntletPlusPlus) DeployOzAccount(publicKey string) (string, error) { + err := sgpp.DeclareOzAccount() + if err != nil { + return "", err + } + + constructorCalldata := map[string]interface{}{ + "publicKey": publicKey, + } + inputMap := map[string]interface{}{ + "constructorCalldata": &constructorCalldata, + } + + request := Request{ + Command: "starknet/chain/open-zeppelin:deploy", + Input: inputMap, + } + + return sgpp.executeDeploy(&request) +} diff --git a/ops/go.mod b/ops/go.mod index 0f09f9930..f17d88083 100644 --- a/ops/go.mod +++ b/ops/go.mod @@ -6,6 +6,7 @@ require ( github.com/rs/zerolog v1.30.0 github.com/smartcontractkit/chainlink-env v0.3.29 github.com/smartcontractkit/chainlink-testing-framework/lib v1.50.5 + github.com/smartcontractkit/gauntlet-plus-plus/sdks/go-gauntlet v1.1.3 ) require ( @@ -16,6 +17,7 @@ require ( github.com/Microsoft/go-winio v0.6.1 // indirect github.com/Microsoft/hcsshim v0.11.4 // indirect github.com/alecthomas/units v0.0.0-20211218093645-b94a6e3cc137 // indirect + github.com/apapsch/go-jsonmerge/v2 v2.0.0 // indirect github.com/avast/retry-go v3.0.0+incompatible // indirect github.com/aws/constructs-go/constructs/v10 v10.1.255 // indirect github.com/aws/jsii-runtime-go v1.75.0 // indirect @@ -41,6 +43,7 @@ require ( github.com/felixge/httpsnoop v1.0.4 // indirect github.com/fsnotify/fsnotify v1.7.0 // indirect github.com/fxamacker/cbor/v2 v2.7.0 // indirect + github.com/getkin/kin-openapi v0.120.0 // indirect github.com/go-errors/errors v1.4.2 // indirect github.com/go-logr/logr v1.4.2 // indirect github.com/go-logr/stdr v1.2.2 // indirect @@ -62,6 +65,7 @@ require ( github.com/gregjones/httpcache v0.0.0-20190611155906-901d90724c79 // indirect github.com/imdario/mergo v0.3.16 // indirect github.com/inconshreveable/mousetrap v1.1.0 // indirect + github.com/invopop/yaml v0.2.0 // indirect github.com/josharian/intern v1.0.0 // indirect github.com/json-iterator/go v1.1.12 // indirect github.com/klauspost/compress v1.17.8 // indirect @@ -79,12 +83,15 @@ require ( github.com/moby/term v0.5.0 // indirect github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect github.com/modern-go/reflect2 v1.0.2 // indirect + github.com/mohae/deepcopy v0.0.0-20170929034955-c48cc78d4826 // indirect github.com/monochromegane/go-gitignore v0.0.0-20200626010858-205db1a8cc00 // indirect github.com/morikuni/aec v1.0.0 // indirect github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect github.com/mxk/go-flowrate v0.0.0-20140419014527-cca7078d478f // indirect + github.com/oapi-codegen/runtime v1.1.1 // indirect github.com/opencontainers/go-digest v1.0.0 // indirect github.com/opencontainers/image-spec v1.1.0-rc5 // indirect + github.com/perimeterx/marshmallow v1.1.5 // indirect github.com/peterbourgon/diskv v2.0.1+incompatible // indirect github.com/pkg/errors v0.9.1 // indirect github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect diff --git a/ops/go.sum b/ops/go.sum index d4159a144..49853a095 100644 --- a/ops/go.sum +++ b/ops/go.sum @@ -14,8 +14,11 @@ github.com/Microsoft/go-winio v0.6.1 h1:9/kr64B9VUZrLm5YYwbGtUJnMgqWVOdUAXu6Migc github.com/Microsoft/go-winio v0.6.1/go.mod h1:LRdKpFKfdobln8UmuiYcKPot9D2v6svN5+sAH+4kjUM= github.com/Microsoft/hcsshim v0.11.4 h1:68vKo2VN8DE9AdN4tnkWnmdhqdbpUFM8OF3Airm7fz8= github.com/Microsoft/hcsshim v0.11.4/go.mod h1:smjE4dvqPX9Zldna+t5FG3rnoHhaB7QYxPRqGcpAD9w= +github.com/RaveNoX/go-jsoncommentstrip v1.0.0/go.mod h1:78ihd09MekBnJnxpICcwzCMzGrKSKYe4AqU6PDYYpjk= github.com/alecthomas/units v0.0.0-20211218093645-b94a6e3cc137 h1:s6gZFSlWYmbqAuRjVTiNNhvNRfY2Wxp9nhfyel4rklc= github.com/alecthomas/units v0.0.0-20211218093645-b94a6e3cc137/go.mod h1:OMCwj8VM1Kc9e19TLln2VL61YJF0x1XFtfdL4JdbSyE= +github.com/apapsch/go-jsonmerge/v2 v2.0.0 h1:axGnT1gRIfimI7gJifB699GoE/oq+F2MU7Dml6nw9rQ= +github.com/apapsch/go-jsonmerge/v2 v2.0.0/go.mod h1:lvDnEdqiQrp0O42VQGgmlKpxL1AP2+08jFMw88y4klk= github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5 h1:0CwZNZbxp69SHPdPJAN/hZIm0C4OItdklCFmMRWYpio= github.com/armon/go-socks5 v0.0.0-20160902184237-e75332964ef5/go.mod h1:wHh0iHkYZB8zMSxRWpUBQtwG5a7fFgvEO+odwuTv2gs= github.com/avast/retry-go v3.0.0+incompatible h1:4SOWQ7Qs+oroOTQOYnAHqelpCO0biHSxpiH9JdtuBj0= @@ -28,6 +31,7 @@ github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw= github.com/blang/semver/v4 v4.0.0 h1:1PFHFE6yCCTv8C1TeyNNarDzntLi7wMI5i/pzqYIsAM= github.com/blang/semver/v4 v4.0.0/go.mod h1:IbckMUScFkM3pff0VJDNKRiT6TG/YpiHIM2yvyW5YoQ= +github.com/bmatcuk/doublestar v1.1.1/go.mod h1:UD6OnuiIn0yFxxA2le/rnRU1G4RaI4UvFv1sNto9p6w= github.com/bxcodec/faker v2.0.1+incompatible h1:P0KUpUw5w6WJXwrPfv35oc91i4d8nf40Nwln+M/+faA= github.com/bxcodec/faker v2.0.1+incompatible/go.mod h1:BNzfpVdTwnFJ6GtfYTcQu6l6rHShT+veBxNCnjCx5XM= github.com/cdk8s-team/cdk8s-core-go/cdk8s/v2 v2.7.5 h1:rvc39Ol6z3MvaBzXkxFC6Nfsnixq/dRypushKDd7Nc0= @@ -89,6 +93,8 @@ github.com/fsnotify/fsnotify v1.7.0 h1:8JEhPFa5W2WU7YfeZzPNqzMP6Lwt7L2715Ggo0nos github.com/fsnotify/fsnotify v1.7.0/go.mod h1:40Bi/Hjc2AVfZrqy+aj+yEI+/bRxZnMJyTJwOpGvigM= github.com/fxamacker/cbor/v2 v2.7.0 h1:iM5WgngdRBanHcxugY4JySA0nk1wZorNOpTgCMedv5E= github.com/fxamacker/cbor/v2 v2.7.0/go.mod h1:pxXPTn3joSm21Gbwsv0w9OSA2y1HFR9qXEeXQVeNoDQ= +github.com/getkin/kin-openapi v0.120.0 h1:MqJcNJFrMDFNc07iwE8iFC5eT2k/NPUFDIpNeiZv8Jg= +github.com/getkin/kin-openapi v0.120.0/go.mod h1:PCWw/lfBrJY4HcdqE3jj+QFkaFK8ABoqo7PvqVhXXqw= github.com/go-errors/errors v1.4.2 h1:J6MZopCL4uSllY1OfXM374weqZFFItUbrImctkmUxIA= github.com/go-errors/errors v1.4.2/go.mod h1:sIVyrIiJhuEF+Pj9Ebtd6P/rEYROXFi3BopGUQ5a5Og= github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= @@ -113,6 +119,8 @@ github.com/go-resty/resty/v2 v2.11.0/go.mod h1:iiP/OpA0CkcL3IGt1O0+/SIItFUbkkyw5 github.com/go-task/slim-sprig v0.0.0-20230315185526-52ccab3ef572 h1:tfuBGBXKqDEevZMzYi5KSi8KkcZtzBcTgAUUtapy0OI= github.com/go-task/slim-sprig/v3 v3.0.0 h1:sUs3vkvUymDpBKi3qH1YSqBQk9+9D/8M2mN1vB6EwHI= github.com/go-task/slim-sprig/v3 v3.0.0/go.mod h1:W848ghGpv3Qj3dhTPRyJypKRiqCdHZiAzKg9hl15HA8= +github.com/go-test/deep v1.0.8 h1:TDsG77qcSprGbC6vTN8OuXp5g+J+b5Pcguhf7Zt61VM= +github.com/go-test/deep v1.0.8/go.mod h1:5C2ZWiW0ErCdrYzpqxLbTX7MG14M9iiw8DgHncVwcsE= github.com/godbus/dbus/v5 v5.0.4/go.mod h1:xhWf0FNVPg57R7Z0UbKHbJfkEywrmjJnf7w5xrFpKfA= github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da h1:oI5xCqsCo564l8iNU+DwB5epxmsaqB+rhGL0m5jtYqE= @@ -164,10 +172,13 @@ github.com/imdario/mergo v0.3.16 h1:wwQJbIsHYGMUyLSPrEq1CT16AhnhNJQ51+4fdHUnCl4= github.com/imdario/mergo v0.3.16/go.mod h1:WBLT9ZmE3lPoWsEzCh9LPo3TiwVN+ZKEjmz+hD27ysY= github.com/inconshreveable/mousetrap v1.1.0 h1:wN+x4NVGpMsO7ErUn/mUI3vEoE6Jt13X2s0bqwp9tc8= github.com/inconshreveable/mousetrap v1.1.0/go.mod h1:vpF70FUmC8bwa3OWnCshd2FqLfsEA9PFc4w1p2J65bw= +github.com/invopop/yaml v0.2.0 h1:7zky/qH+O0DwAyoobXUqvVBwgBFRxKoQ/3FjcVpjTMY= +github.com/invopop/yaml v0.2.0/go.mod h1:2XuRLgs/ouIrW3XNzuNj7J3Nvu/Dig5MXvbCEdiBN3Q= github.com/josharian/intern v1.0.0 h1:vlS4z54oSdjm0bgjRigI+G1HpF+tI+9rE5LLzOg8HmY= github.com/josharian/intern v1.0.0/go.mod h1:5DoeVV0s6jJacbCEi61lwdGj/aVlrQvzHFFd8Hwg//Y= github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM= github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHmT4TnhNGBo= +github.com/juju/gnuflag v0.0.0-20171113085948-2ce1bb71843d/go.mod h1:2PavIy+JPciBPrBUjwbNvtwB6RQlve+hkpll6QSNmOE= github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= github.com/klauspost/compress v1.17.8 h1:YcnTYrq7MikUT7k0Yb5eceMmALQPYBW/Xltxn0NAMnU= @@ -213,6 +224,8 @@ github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M= github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= +github.com/mohae/deepcopy v0.0.0-20170929034955-c48cc78d4826 h1:RWengNIwukTxcDr9M+97sNutRR1RKhG96O6jWumTTnw= +github.com/mohae/deepcopy v0.0.0-20170929034955-c48cc78d4826/go.mod h1:TaXosZuwdSHYgviHp1DAtfrULt5eUgsSMsZf+YrPgl8= github.com/monochromegane/go-gitignore v0.0.0-20200626010858-205db1a8cc00 h1:n6/2gBQ3RWajuToeY6ZtZTIKv2v7ThUy5KKusIT0yc0= github.com/monochromegane/go-gitignore v0.0.0-20200626010858-205db1a8cc00/go.mod h1:Pm3mSP3c5uWn86xMLZ5Sa7JB9GsEZySvHYXCTK4E9q4= github.com/morikuni/aec v1.0.0 h1:nP9CBfwrvYnBRgY6qfDQkygYDmYwOilePFkwzv4dU8A= @@ -221,6 +234,8 @@ github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 h1:C3w9PqII01/Oq github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ= github.com/mxk/go-flowrate v0.0.0-20140419014527-cca7078d478f h1:y5//uYreIhSUg3J1GEMiLbxo1LJaP8RfCpH6pymGZus= github.com/mxk/go-flowrate v0.0.0-20140419014527-cca7078d478f/go.mod h1:ZdcZmHo+o7JKHSa8/e818NopupXU1YMK5fe1lsApnBw= +github.com/oapi-codegen/runtime v1.1.1 h1:EXLHh0DXIJnWhdRPN2w4MXAzFyE4CskzhNLUmtpMYro= +github.com/oapi-codegen/runtime v1.1.1/go.mod h1:SK9X900oXmPWilYR5/WKPzt3Kqxn/uS/+lbpREv+eCg= github.com/onsi/ginkgo/v2 v2.19.0 h1:9Cnnf7UHo57Hy3k6/m5k3dRfGTMXGvxhHFvkDTCTpvA= github.com/onsi/ginkgo/v2 v2.19.0/go.mod h1:rlwLi9PilAFJ8jCg9UE1QP6VBpd6/xj3SRC0d6TU0To= github.com/onsi/gomega v1.33.1 h1:dsYjIxxSR755MDmKVsaFQTE22ChNBcuuTWgkUDSubOk= @@ -229,6 +244,8 @@ github.com/opencontainers/go-digest v1.0.0 h1:apOUWs51W5PlhuyGyz9FCeeBIOUDA/6nW8 github.com/opencontainers/go-digest v1.0.0/go.mod h1:0JzlMkj0TRzQZfJkVvzbP0HBR3IKzErnv2BNG4W4MAM= github.com/opencontainers/image-spec v1.1.0-rc5 h1:Ygwkfw9bpDvs+c9E34SdgGOj41dX/cbdlwvlWt0pnFI= github.com/opencontainers/image-spec v1.1.0-rc5/go.mod h1:X4pATf0uXsnn3g5aiGIsVnJBR4mxhKzfwmvK/B2NTm8= +github.com/perimeterx/marshmallow v1.1.5 h1:a2LALqQ1BlHM8PZblsDdidgv1mWi1DgC2UmX50IvK2s= +github.com/perimeterx/marshmallow v1.1.5/go.mod h1:dsXbUu8CRzfYP5a87xpp0xq9S3u0Vchtcl8we9tYaXw= github.com/peterbourgon/diskv v2.0.1+incompatible h1:UBdAOUP5p4RWqPBg048CAvpKN+vxiaj6gdUUzhl4XmI= github.com/peterbourgon/diskv v2.0.1+incompatible/go.mod h1:uqqh8zWWbv1HBMNONnaR/tNboyR3/BZd58JJSHlUSCU= github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= @@ -272,10 +289,13 @@ github.com/smartcontractkit/chainlink-env v0.3.29 h1:hcIw/BeuB0wKiiE3umAUNBZzWkH github.com/smartcontractkit/chainlink-env v0.3.29/go.mod h1:9c0Czq4a6wZKY20BcoAlK29DnejQIiLo/MwKYtSFnHk= github.com/smartcontractkit/chainlink-testing-framework/lib v1.50.5 h1:Owb1MQZn0NZHwtZAnPZE6TVoTx6xLrfPaUdeOYswE9M= github.com/smartcontractkit/chainlink-testing-framework/lib v1.50.5/go.mod h1:hS4yNF94C1lkS9gvtFXW8Km8K9NzGeR20aNfkqo5qbE= +github.com/smartcontractkit/gauntlet-plus-plus/sdks/go-gauntlet v1.1.3 h1:RIApVijvhHI6iW9pyT35Nk39rPGEC4TwVe/f+YA1G5k= +github.com/smartcontractkit/gauntlet-plus-plus/sdks/go-gauntlet v1.1.3/go.mod h1:oiUkQxoi0kZzbW125oIt4lr/pqaRSDol1rWHLCyqmNQ= github.com/spf13/cobra v1.8.1 h1:e5/vxKd/rZsfSJMUX1agtjeTDf+qv1/JdBF8gg5k9ZM= github.com/spf13/cobra v1.8.1/go.mod h1:wHxEcudfqmLYa8iTfL+OuZPbBZkmvliBWKIezN3kD9Y= github.com/spf13/pflag v1.0.5 h1:iy+VFUOCP1a+8yFto/drg2CJ5u0yRoB7fZw3DKv/JXA= github.com/spf13/pflag v1.0.5/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= +github.com/spkg/bom v0.0.0-20160624110644-59b7046e48ad/go.mod h1:qLr4V1qq6nMqFKkMo8ZTx3f+BZEkzsRUY10Xsm2mwU0= github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw= github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpEOglKo= @@ -297,6 +317,8 @@ github.com/tklauser/go-sysconf v0.3.12 h1:0QaGUFOdQaIVdPgfITYzaTegZvdCjmYO52cSFA github.com/tklauser/go-sysconf v0.3.12/go.mod h1:Ho14jnntGE1fpdOqQEEaiKRpvIavV0hSfmBq8nJbHYI= github.com/tklauser/numcpus v0.6.1 h1:ng9scYS7az0Bk4OZLvrNXNSAO2Pxr1XXRAPyjhIx+Fk= github.com/tklauser/numcpus v0.6.1/go.mod h1:1XfjsgE2zo8GVw7POkMbHENHzVg3GzmoZ9fESEdAacY= +github.com/ugorji/go/codec v1.2.11 h1:BMaWp1Bb6fHwEtbplGBGJ498wD+LKlNSl25MjdZY4dU= +github.com/ugorji/go/codec v1.2.11/go.mod h1:UNopzCgEMSXjBc6AOMqYvWC1ktqTAfzJZUZgYf6w6lg= github.com/x448/float16 v0.8.4 h1:qLwI1I70+NjRFUR3zs1JPUCgaCXSh3SW62uAKT1mSBM= github.com/x448/float16 v0.8.4/go.mod h1:14CWIYCyZA/cWjXOioeEpHeN/83MdbZDRQHoFcYsOfg= github.com/xlab/treeprint v1.2.0 h1:HzHnuAF1plUN2zGlAFHbSQP2qJ0ZAD3XF5XD7OesXRQ= @@ -482,6 +504,7 @@ gopkg.in/yaml.v2 v2.2.8/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= +gopkg.in/yaml.v3 v3.0.0/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= gotest.tools/v3 v3.5.0 h1:Ljk6PdHdOhAb5aDMWXjDLMMhph+BpztA4v1QdqEW2eY=