Skip to content

Commit

Permalink
Merge branch 'develop' of https://github.com/smartcontractkit/chainlink
Browse files Browse the repository at this point in the history
… into CRIB-322-keystone-evm-contract-deployment-tooling
  • Loading branch information
HenryNguyen5 committed Dec 13, 2024
2 parents a05aab5 + 6a0f4d5 commit f4bb112
Show file tree
Hide file tree
Showing 177 changed files with 6,150 additions and 3,969 deletions.
5 changes: 5 additions & 0 deletions .changeset/big-camels-report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"chainlink": patch
---

#bugfix fix non-idempotent loopp registry.Register
5 changes: 5 additions & 0 deletions .changeset/giant-eels-jump.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"chainlink": patch
---

Add error handling for Arbitrum RPC server timeouts. #added
5 changes: 5 additions & 0 deletions .changeset/tiny-kangaroos-switch.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"chainlink": patch
---

Added new fatal error cases for transactions to the Solana TXM. #added
132 changes: 73 additions & 59 deletions .github/e2e-tests.yml

Large diffs are not rendered by default.

9 changes: 5 additions & 4 deletions .github/workflows/ci-core-partial.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ jobs:
permissions:
id-token: write
contents: write
actions: write
strategy:
fail-fast: false
matrix:
Expand Down Expand Up @@ -86,7 +87,7 @@ jobs:
go-mod-download-directory: ${{ matrix.type.test-suite == 'ccip-deployment' && matrix.type.module-directory || '' }}

- name: Build Tests
uses: smartcontractkit/.github/apps/go-conditional-tests@37882e110590e636627a26371bdbd56ddfcce821 # go-conditional-tests@0.1.0
uses: smartcontractkit/.github/apps/go-conditional-tests@57f99fbea73056c490c766d50ef582a13ec4f3bb # go-conditional-tests@0.2.0
timeout-minutes: 10
with:
pipeline-step: "build"
Expand All @@ -98,7 +99,7 @@ jobs:
build-flags: ${{ matrix.type.build-flags }}

- name: Run Tests
uses: smartcontractkit/.github/apps/go-conditional-tests@37882e110590e636627a26371bdbd56ddfcce821 # go-conditional-tests@0.1.0
uses: smartcontractkit/.github/apps/go-conditional-tests@57f99fbea73056c490c766d50ef582a13ec4f3bb # go-conditional-tests@0.2.0
timeout-minutes: 15
env:
CL_DATABASE_URL: ${{ env.DB_URL }}
Expand All @@ -112,7 +113,7 @@ jobs:
github-token: ${{ secrets.GITHUB_TOKEN }}

- name: Update Test Index
uses: smartcontractkit/.github/apps/go-conditional-tests@37882e110590e636627a26371bdbd56ddfcce821 # go-conditional-tests@0.1.0
uses: smartcontractkit/.github/apps/go-conditional-tests@57f99fbea73056c490c766d50ef582a13ec4f3bb # go-conditional-tests@0.2.0
with:
pipeline-step: "update"
collect-coverage: ${{ needs.filter.outputs.should-collect-coverage }}
Expand All @@ -130,7 +131,7 @@ jobs:
if: ${{ needs.filter.outputs.should-collect-coverage == 'true' }}
runs-on: ubuntu-latest
steps:
- name: Checkout the repo
- name: Checkout the repo
uses: actions/[email protected]
with:
# fetches all history for all tags and branches to provide more metadata for sonar reports
Expand Down
3 changes: 0 additions & 3 deletions .github/workflows/client-compatibility-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -668,9 +668,6 @@ jobs:
E2E_TEST_PYROSCOPE_KEY: ${{ secrets.QA_PYROSCOPE_KEY }}
E2E_TEST_PYROSCOPE_ENVIRONMENT: ci-client-compatability-${{ matrix.eth_client }}-testnet
E2E_TEST_PYROSCOPE_ENABLED: "true"
E2E_TEST_LOGGING_RUN_ID: ${{ github.run_id }}
E2E_TEST_LOG_COLLECT: ${{ vars.TEST_LOG_COLLECT }}
E2E_TEST_LOG_STREAM_LOG_TARGETS: ${{ vars.LOGSTREAM_LOG_TARGETS }}
E2E_TEST_PRIVATE_ETHEREUM_EXECUTION_LAYER: ${{ matrix.evm_node.eth_implementation || 'geth' }}
E2E_TEST_PRIVATE_ETHEREUM_ETHEREUM_VERSION: auto_fill # Auto fill the version based on the docker image
E2E_TEST_PRIVATE_ETHEREUM_CUSTOM_DOCKER_IMAGE: ${{ matrix.evm_node.docker_image }}
Expand Down
7 changes: 3 additions & 4 deletions .github/workflows/flakeguard-on-demand.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,13 @@ on:
description: 'The path to the project to run the flaky test detection.'
default: '.'
baseRef:
required: true
required: false
type: string
description: 'The base reference or branch to compare changes for detecting flaky tests.'
default: 'origin/develop'
description: 'The base reference or branch to compare changes for detecting flaky tests. Set only when running diffs between branches. E.g. (develop)'
headRef:
required: false
type: string
description: 'The head reference or branch to compare changes for detecting flaky tests. Default is the current branch.'
description: 'The head reference or branch to compare changes for detecting flaky tests. Default is the current branch. E.g. (develop)'
runAllTests:
required: false
type: boolean
Expand Down
53 changes: 39 additions & 14 deletions .github/workflows/flakeguard.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,11 +15,11 @@ on:
baseRef:
required: false
type: string
description: 'The base reference or branch to compare changes for detecting flaky tests.'
description: 'The base reference or branch to compare changes for detecting flaky tests. Set only when running diffs between branches. E.g. (develop)'
headRef:
required: false
type: string
description: 'The head reference or branch to compare changes for detecting flaky tests. Default is the current branch.'
description: 'The head reference or branch to compare changes for detecting flaky tests. Default is the current branch. E.g. (develop)'
runAllTests:
required: false
type: boolean
Expand Down Expand Up @@ -56,6 +56,7 @@ on:
required: true

env:
GIT_BASE_REF: ${{ inputs.baseRef }}
GIT_HEAD_REF: ${{ inputs.headRef || github.ref }}
SKIPPED_TESTS: ${{ fromJSON(inputs.extraArgs)['skipped_tests'] || '' }} # Comma separated list of test names to skip running in the flaky detector. Related issue: TT-1823
DEFAULT_MAX_RUNNER_COUNT: ${{ fromJSON(inputs.extraArgs)['default_max_runner_count'] || '8' }} # The default maximum number of GitHub runners to use for parallel test execution.
Expand All @@ -80,29 +81,49 @@ jobs:
affected_test_packages: ${{ steps.get-tests.outputs.packages }}
git_head_sha: ${{ steps.get_commit_sha.outputs.git_head_sha }}
git_head_short_sha: ${{ steps.get_commit_sha.outputs.git_head_short_sha }}
git_base_sha: ${{ steps.get_commit_sha.outputs.git_base_sha }}
steps:
- name: Checkout repository
uses: actions/checkout@9bb56186c3b09b4f86b1c65136769dd318469633 # v4.1.2
with:
fetch-depth: 0
ref: ${{ env.GIT_HEAD_REF }}

- name: Get commit SHA
- name: Get SHA
id: get_commit_sha
run: |
# Resolve HEAD SHA
git_head_sha=$(git rev-parse HEAD)
git_head_short_sha=$(git rev-parse --short HEAD)
echo "git_head_sha=$git_head_sha" >> $GITHUB_OUTPUT
echo "git_head_short_sha=$git_head_short_sha" >> $GITHUB_OUTPUT
# Print HEAD SHAs to the console
echo "HEAD SHA: $git_head_sha"
echo "HEAD Short SHA: $git_head_short_sha"
# Conditionally resolve BASE SHA
if [ -n "${{ env.GIT_BASE_REF }}" ]; then
git fetch origin ${{ env.GIT_BASE_REF }} --quiet
git_base_sha=$(git rev-parse origin/${{ env.GIT_BASE_REF }})
echo "git_base_sha=$git_base_sha" >> $GITHUB_OUTPUT
# Print BASE SHA to the console
echo "BASE SHA: $git_base_sha"
else
echo "BASE SHA not provided."
echo "git_base_sha=" >> $GITHUB_OUTPUT
fi
- name: Set up Go 1.21.9
uses: actions/[email protected]
with:
cache: false

- name: Install flakeguard
shell: bash
run: go install github.com/smartcontractkit/chainlink-testing-framework/tools/flakeguard@404e04e1e2e2dd5a384b09bd05b8d80409b6609a # [email protected]
run: go install github.com/smartcontractkit/chainlink-testing-framework/tools/flakeguard@fc2d7e38486853d2bed06e9074868087f5b55506 # [email protected]

- name: Find new or updated test packages
if: ${{ inputs.runAllTests == false }}
Expand All @@ -115,7 +136,7 @@ jobs:
PATH=$PATH:$(go env GOPATH)/bin
export PATH
PACKAGES=$(flakeguard find --find-by-test-files-diff=${{ inputs.findByTestFilesDiff }} --find-by-affected-packages=${{ inputs.findByAffectedPackages }} --base-ref=origin/${{ inputs.baseRef }} --project-path=${{ inputs.projectPath }})
PACKAGES=$(flakeguard find --find-by-test-files-diff=${{ inputs.findByTestFilesDiff }} --find-by-affected-packages=${{ inputs.findByAffectedPackages }} --base-ref=origin/${{ env.GIT_BASE_REF }} --project-path=${{ inputs.projectPath }})
echo $PACKAGES
echo "packages=$PACKAGES" >> $GITHUB_OUTPUT
Expand All @@ -130,7 +151,7 @@ jobs:
PATH=$PATH:$(go env GOPATH)/bin
export PATH
TEST_FILES=$(flakeguard find --only-show-changed-test-files=true --base-ref=origin/${{ inputs.baseRef }} --project-path=${{ inputs.projectPath }})
TEST_FILES=$(flakeguard find --only-show-changed-test-files=true --base-ref=origin/${{ env.GIT_BASE_REF }} --project-path=${{ inputs.projectPath }})
echo $TEST_FILES
echo "test_files=$TEST_FILES" >> $GITHUB_OUTPUT
Expand Down Expand Up @@ -261,11 +282,11 @@ jobs:

- name: Install flakeguard
shell: bash
run: go install github.com/smartcontractkit/chainlink-testing-framework/tools/flakeguard@404e04e1e2e2dd5a384b09bd05b8d80409b6609a # [email protected]
run: go install github.com/smartcontractkit/chainlink-testing-framework/tools/flakeguard@fc2d7e38486853d2bed06e9074868087f5b55506 # [email protected]

- name: Run tests with flakeguard
shell: bash
run: flakeguard run --project-path=${{ inputs.projectPath }} --test-packages=${{ matrix.testPackages }} --run-count=${{ env.TEST_REPEAT_COUNT }} --max-pass-ratio=${{ inputs.maxPassRatio }} --race=${{ env.RUN_WITH_RACE }} --shuffle=${{ env.RUN_WITH_SHUFFLE }} --shuffle-seed=${{ env.SHUFFLE_SEED }} --skip-tests=${{ env.SKIPPED_TESTS }} --output-json=test-result.json
run: flakeguard run --project-path=${{ inputs.projectPath }} --test-packages=${{ matrix.testPackages }} --run-count=${{ env.TEST_REPEAT_COUNT }} --max-pass-ratio=${{ inputs.maxPassRatio }} --race=${{ env.RUN_WITH_RACE }} --shuffle=${{ env.RUN_WITH_SHUFFLE }} --shuffle-seed=${{ env.SHUFFLE_SEED }} --skip-tests=${{ env.SKIPPED_TESTS }} --output-json=test-result.json --omit-test-outputs-on-success=true
env:
CL_DATABASE_URL: ${{ env.DB_URL }}

Expand All @@ -281,7 +302,7 @@ jobs:
needs: [get-tests, run-tests]
if: always()
name: Report
runs-on: ubuntu-24.04-8cores-32GB-ARM # Use a runner with more resources to avoid OOM errors when aggregating test results.
runs-on: ubuntu-latest
outputs:
test_results: ${{ steps.results.outputs.results }}
steps:
Expand All @@ -308,7 +329,7 @@ jobs:

- name: Install flakeguard
shell: bash
run: go install github.com/smartcontractkit/chainlink-testing-framework/tools/flakeguard@404e04e1e2e2dd5a384b09bd05b8d80409b6609a # [email protected]
run: go install github.com/smartcontractkit/chainlink-testing-framework/tools/flakeguard@fc2d7e38486853d2bed06e9074868087f5b55506 # [email protected]

- name: Aggregate Flakeguard Results
id: results
Expand All @@ -329,7 +350,11 @@ jobs:
--output-path ./flakeguard-report \
--repo-path "${{ github.workspace }}" \
--codeowners-path "${{ github.workspace }}/.github/CODEOWNERS" \
--max-pass-ratio "${{ inputs.maxPassRatio }}"
--max-pass-ratio "${{ inputs.maxPassRatio }}" \
--repo-url "${{ inputs.repoUrl }}" \
--base-sha "${{ needs.get-tests.outputs.git_base_sha }}" \
--head-sha "${{ needs.get-tests.outputs.git_head_sha }}" \
--github-workflow-name "${{ github.workflow }}"

# Print out the summary file
echo -e "\nFlakeguard Summary:"
Expand Down Expand Up @@ -461,7 +486,7 @@ jobs:
"type": "section",
"text": {
"type": "mrkdwn",
"text": "${{ inputs.runAllTests == true && format('Ran all tests for `{0}` branch.', inputs.headRef) || format('Ran changed tests between `{0}` and `{1}` (`{2}`).', inputs.baseRef, needs.get-tests.outputs.git_head_short_sha, env.GIT_HEAD_REF) }}"
"text": "${{ inputs.runAllTests == true && format('Ran all tests for `{0}` branch.', env.GIT_HEAD_REF) || format('Ran changed tests between `{0}` and `{1}` (`{2}`).', env.GIT_BASE_REF, needs.get-tests.outputs.git_head_short_sha, env.GIT_HEAD_REF) }}"
}
},
{
Expand All @@ -481,7 +506,7 @@ jobs:
"type": "section",
"text": {
"type": "mrkdwn",
"text": "${{ format('<{0}/{1}/actions/runs/{2}|View Flaky Detector Details> | <{3}/compare/{4}...{5}#files_bucket|Compare Changes>{6}', github.server_url, github.repository, github.run_id, inputs.repoUrl, inputs.baseRef, needs.get-tests.outputs.git_head_sha, github.event_name == 'pull_request' && format(' | <{0}|View PR>', github.event.pull_request.html_url) || '') }}"
"text": "${{ format('<{0}/{1}/actions/runs/{2}|View Flaky Detector Details> | <{3}/compare/{4}...{5}#files_bucket|Compare Changes>{6}', github.server_url, github.repository, github.run_id, inputs.repoUrl, env.GIT_BASE_REF, needs.get-tests.outputs.git_head_sha, github.event_name == 'pull_request' && format(' | <{0}|View PR>', github.event.pull_request.html_url) || '') }}"
}
}
]
Expand Down Expand Up @@ -514,7 +539,7 @@ jobs:
"type": "section",
"text": {
"type": "mrkdwn",
"text": "${{ inputs.runAllTests == true && format('Ran all tests for `{0}` branch.', env.GIT_HEAD_REF) || format('Ran changed tests between `{0}` and `{1}` (`{2}`).', inputs.baseRef, needs.get-tests.outputs.git_head_short_sha, env.GIT_HEAD_REF) }}"
"text": "${{ inputs.runAllTests == true && format('Ran all tests for `{0}` branch.', env.GIT_HEAD_REF) || format('Ran changed tests between `{0}` and `{1}` (`{2}`).', env.GIT_BASE_REF, needs.get-tests.outputs.git_head_short_sha, env.GIT_HEAD_REF) }}"
}
},
{
Expand Down
47 changes: 43 additions & 4 deletions .github/workflows/integration-chaos-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,49 @@ on:
tags:
- "*"
workflow_dispatch:
inputs:
team:
description: Team to run the tests for (e.g. BIX, CCIP)
required: true
type: string

jobs:
run-e2e-tests-workflow-dispatch:
name: Run E2E Tests (Workflow Dispatch)
uses: smartcontractkit/.github/.github/workflows/run-e2e-tests.yml@0d4a2b2b009c87b5c366d0b97f7a8d7de2f60760
if: github.event_name == 'workflow_dispatch'
with:
test_path: .github/e2e-tests.yml
chainlink_version: ${{ github.sha }}
require_chainlink_image_versions_in_qa_ecr: ${{ github.sha }}
test_trigger: E2E Chaos Tests
test_log_level: debug
team: ${{ inputs.team }}
secrets:
QA_AWS_REGION: ${{ secrets.QA_AWS_REGION }}
QA_AWS_ROLE_TO_ASSUME: ${{ secrets.QA_AWS_ROLE_TO_ASSUME }}
QA_AWS_ACCOUNT_NUMBER: ${{ secrets.QA_AWS_ACCOUNT_NUMBER }}
PROD_AWS_ACCOUNT_NUMBER: ${{ secrets.AWS_ACCOUNT_ID_PROD }}
QA_PYROSCOPE_INSTANCE: ${{ secrets.QA_PYROSCOPE_INSTANCE }}
QA_PYROSCOPE_KEY: ${{ secrets.QA_PYROSCOPE_KEY }}
QA_KUBECONFIG: ${{ secrets.QA_KUBECONFIG }}
GRAFANA_INTERNAL_TENANT_ID: ${{ secrets.GRAFANA_INTERNAL_TENANT_ID }}
GRAFANA_INTERNAL_BASIC_AUTH: ${{ secrets.GRAFANA_INTERNAL_BASIC_AUTH }}
GRAFANA_INTERNAL_HOST: ${{ secrets.GRAFANA_INTERNAL_HOST }}
GRAFANA_INTERNAL_URL_SHORTENER_TOKEN: ${{ secrets.GRAFANA_INTERNAL_URL_SHORTENER_TOKEN }}
LOKI_TENANT_ID: ${{ secrets.LOKI_TENANT_ID }}
LOKI_URL: ${{ secrets.LOKI_URL }}
LOKI_BASIC_AUTH: ${{ secrets.LOKI_BASIC_AUTH }}
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
AWS_REGION: ${{ secrets.QA_AWS_REGION }}
AWS_OIDC_IAM_ROLE_VALIDATION_PROD_ARN: ${{ secrets.AWS_OIDC_IAM_ROLE_VALIDATION_PROD_ARN }}
AWS_API_GW_HOST_GRAFANA: ${{ secrets.AWS_API_GW_HOST_GRAFANA }}
SLACK_BOT_TOKEN: ${{ secrets.QA_SLACK_API_KEY }}

run-e2e-tests-workflow:
name: Run E2E Tests
uses: smartcontractkit/.github/.github/workflows/run-e2e-tests.yml@5412507526722a7b1c5d719fa686eed5a1bc4035 # [email protected]
name: Run E2E Tests (Push and Sechedule)
uses: smartcontractkit/.github/.github/workflows/run-e2e-tests.yml@0d4a2b2b009c87b5c366d0b97f7a8d7de2f60760
if: github.event_name != 'workflow_dispatch'
with:
test_path: .github/e2e-tests.yml
chainlink_version: ${{ github.sha }}
Expand All @@ -32,8 +70,9 @@ jobs:
LOKI_TENANT_ID: ${{ secrets.LOKI_TENANT_ID }}
LOKI_URL: ${{ secrets.LOKI_URL }}
LOKI_BASIC_AUTH: ${{ secrets.LOKI_BASIC_AUTH }}
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
AWS_REGION: ${{ secrets.QA_AWS_REGION }}
AWS_OIDC_IAM_ROLE_VALIDATION_PROD_ARN: ${{ secrets.AWS_OIDC_IAM_ROLE_VALIDATION_PROD_ARN }}
AWS_API_GW_HOST_GRAFANA: ${{ secrets.AWS_API_GW_HOST_GRAFANA }}
AWS_API_GW_HOST_GRAFANA: ${{ secrets.AWS_API_GW_HOST_GRAFANA }}
SLACK_BOT_TOKEN: ${{ secrets.QA_SLACK_API_KEY }}

4 changes: 2 additions & 2 deletions .github/workflows/integration-in-memory-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ jobs:
contents: read
needs: changes
if: github.event_name == 'pull_request' && ( needs.changes.outputs.ccip_changes == 'true' || needs.changes.outputs.core_changes == 'true' || needs.changes.outputs.github_ci_changes == 'true')
uses: smartcontractkit/.github/.github/workflows/run-integration-tests.yml@57112554b9e5cfae79e795a8b1c36acf7e9dead7
uses: smartcontractkit/.github/.github/workflows/run-integration-tests.yml@0632b5652dd5eb03bfa87e23a2b3e2911484fe59
with:
workflow_name: Run CCIP Integration Tests For PR
test_path: .github/integration-in-memory-tests.yml
Expand All @@ -95,7 +95,7 @@ jobs:
contents: read
needs: changes
if: github.event_name == 'merge_group' && ( needs.changes.outputs.ccip_changes == 'true' || needs.changes.outputs.core_changes == 'true' || needs.changes.outputs.github_ci_changes == 'true')
uses: smartcontractkit/.github/.github/workflows/run-integration-tests.yml@57112554b9e5cfae79e795a8b1c36acf7e9dead7
uses: smartcontractkit/.github/.github/workflows/run-integration-tests.yml@0632b5652dd5eb03bfa87e23a2b3e2911484fe59
with:
workflow_name: Run CCIP Integration Tests For Merge Queue
test_path: .github/integration-in-memory-tests.yml
Expand Down
Loading

0 comments on commit f4bb112

Please sign in to comment.