From 773a4adc0d6f312b5773f3d68f6827e05d2e920d Mon Sep 17 00:00:00 2001 From: kayan Date: Tue, 30 Jul 2024 14:49:46 +0800 Subject: [PATCH 01/11] test cicd with spring --- .cicd/defaults.json | 4 +++ .github/workflows/node.yml | 54 ++++++++++++++++---------------------- 2 files changed, 27 insertions(+), 31 deletions(-) diff --git a/.cicd/defaults.json b/.cicd/defaults.json index 5116a4a..a785b0a 100644 --- a/.cicd/defaults.json +++ b/.cicd/defaults.json @@ -1,4 +1,8 @@ { + "antelope-spring-dev":{ + "target":"main", + "prerelease":false + }, "leap-dev":{ "target":"5", "prerelease":false diff --git a/.github/workflows/node.yml b/.github/workflows/node.yml index 4124908..1bcb64f 100644 --- a/.github/workflows/node.yml +++ b/.github/workflows/node.yml @@ -153,6 +153,8 @@ jobs: name: Determine Versions runs-on: ubuntu-latest outputs: + antelope-spring-dev-target: ${{steps.versions.outputs.antelope-spring-dev-target}} + antelope-spring-dev-prerelease: ${{steps.versions.outputs.antelope-spring-dev-prerelease}} leap-dev-target: ${{steps.versions.outputs.leap-dev-target}} leap-dev-prerelease: ${{steps.versions.outputs.leap-dev-prerelease}} leap-target: ${{steps.versions.outputs.leap-target}} @@ -169,6 +171,8 @@ jobs: GH_TOKEN: ${{secrets.GITHUB_TOKEN}} run: | DEFAULTS_JSON=$(curl -sSfL $(gh api https://api.github.com/repos/${{github.repository}}/contents/.cicd/defaults.json?ref=${{github.sha}} --jq .download_url)) + echo antelope-spring-dev-target=$(echo "$DEFAULTS_JSON" | jq -r '."antelope-spring-dev".target') >> $GITHUB_OUTPUT + echo antelope-spring-dev-prerelease=$(echo "$DEFAULTS_JSON" | jq -r '."antelope-spring-dev".prerelease') >> $GITHUB_OUTPUT echo leap-dev-target=$(echo "$DEFAULTS_JSON" | jq -r '."leap-dev".target') >> $GITHUB_OUTPUT echo leap-dev-prerelease=$(echo "$DEFAULTS_JSON" | jq -r '."leap-dev".prerelease') >> $GITHUB_OUTPUT echo leap-target=$(echo "$DEFAULTS_JSON" | jq -r '."leap".target') >> $GITHUB_OUTPUT @@ -230,48 +234,36 @@ jobs: apt update apt upgrade -y - - name: Download CDT + - name: Download cdt uses: AntelopeIO/asset-artifact-download-action@v3 with: owner: AntelopeIO repo: cdt - target: '${{needs.versions.outputs.cdt-target}}' - prereleases: ${{fromJSON(needs.versions.outputs.cdt-prerelease)}} file: 'cdt_.*amd64.deb' - token: ${{ secrets.GITHUB_TOKEN }} - - - name: Install CDT - run: apt-get install -y ./cdt*.deb + target: '${{steps.versions.outputs.cdt-target}}' + prereleases: ${{fromJSON(steps.versions.outputs.cdt-prerelease)}} + artifact-name: cdt_ubuntu_package_amd64 - - name: Download leap-dev binary + - name: Download antelope-spring-dev uses: AntelopeIO/asset-artifact-download-action@v3 with: owner: AntelopeIO - repo: leap - target: '${{needs.versions.outputs.leap-dev-target}}' - prereleases: ${{fromJSON(needs.versions.outputs.leap-dev-prerelease)}} - file: 'leap-dev.*ubuntu22\.04_amd64.deb' - container-package: experimental-binaries - artifact-name: leap-dev-ubuntu22-amd64 - token: ${{ secrets.GITHUB_TOKEN }} - - - name: Download leap binary - uses: AntelopeIO/asset-artifact-download-action@v3 - with: - owner: AntelopeIO - repo: leap - target: '${{needs.versions.outputs.leap-target}}' - prereleases: ${{fromJSON(needs.versions.outputs.leap-prerelease)}} - file: 'leap_.*_amd64.deb' - artifact-name: leap-deb-amd64 - token: ${{ secrets.GITHUB_TOKEN }} - - - name: Install Leap + repo: spring + file: 'antelope-spring-dev.*ubuntu22\.04_amd64.deb' + target: '${{steps.versions.outputs.antelope-spring-dev-target}}' + prereleases: ${{fromJSON(steps.versions.outputs.antelope-spring-dev-prerelease)}} + artifact-name: antelope-spring-dev-ubuntu22-amd64 + container-package: antelope-spring-experimental-binaries + + - name: Install packages run: | - apt-get install -y ./leap*.deb + sudo apt-get update && sudo apt-get upgrade -y + sudo apt install ./*.deb + sudo apt-get install cmake + rm ./*.deb - - name: Link Leap TestHarness Module (fix for v4 of leap) - run: ln -s /usr/share/leap_testing/tests/TestHarness /usr/lib/python3/dist-packages/TestHarness + - name: Link Spring TestHarness Module + run: ln -s /usr/share/spring_testing/tests/TestHarness /usr/lib/python3/dist-packages/TestHarness - name: Download EOS EVM Contract uses: AntelopeIO/asset-artifact-download-action@v3 From 1bb35d73c5aaeeef0ac19439e31fffa9f34e86f3 Mon Sep 17 00:00:00 2001 From: kayan Date: Tue, 30 Jul 2024 15:25:06 +0800 Subject: [PATCH 02/11] test --- .github/workflows/node.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/node.yml b/.github/workflows/node.yml index 1bcb64f..1dd3af5 100644 --- a/.github/workflows/node.yml +++ b/.github/workflows/node.yml @@ -240,8 +240,8 @@ jobs: owner: AntelopeIO repo: cdt file: 'cdt_.*amd64.deb' - target: '${{steps.versions.outputs.cdt-target}}' - prereleases: ${{fromJSON(steps.versions.outputs.cdt-prerelease)}} + target: '${{needs.versions.outputs.cdt-target}}' + prereleases: ${{fromJSON(needs.versions.outputs.cdt-prerelease)}} artifact-name: cdt_ubuntu_package_amd64 - name: Download antelope-spring-dev @@ -250,8 +250,8 @@ jobs: owner: AntelopeIO repo: spring file: 'antelope-spring-dev.*ubuntu22\.04_amd64.deb' - target: '${{steps.versions.outputs.antelope-spring-dev-target}}' - prereleases: ${{fromJSON(steps.versions.outputs.antelope-spring-dev-prerelease)}} + target: '${{needs.versions.outputs.antelope-spring-dev-target}}' + prereleases: ${{fromJSON(needs.versions.outputs.antelope-spring-dev-prerelease)}} artifact-name: antelope-spring-dev-ubuntu22-amd64 container-package: antelope-spring-experimental-binaries From f342c5f932ec270d685554ba1fbe89984cf60491 Mon Sep 17 00:00:00 2001 From: kayan Date: Tue, 30 Jul 2024 15:58:42 +0800 Subject: [PATCH 03/11] test cicd --- .github/workflows/node.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/node.yml b/.github/workflows/node.yml index 1dd3af5..28c7db2 100644 --- a/.github/workflows/node.yml +++ b/.github/workflows/node.yml @@ -257,9 +257,9 @@ jobs: - name: Install packages run: | - sudo apt-get update && sudo apt-get upgrade -y - sudo apt install ./*.deb - sudo apt-get install cmake + apt-get update && apt-get upgrade -y + apt install ./*.deb + apt-get install cmake rm ./*.deb - name: Link Spring TestHarness Module From 1088987b77b53fb034832df0d2ea4b17ba4a46fb Mon Sep 17 00:00:00 2001 From: kayan Date: Tue, 30 Jul 2024 16:22:10 +0800 Subject: [PATCH 04/11] test cicd --- .github/workflows/node.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/node.yml b/.github/workflows/node.yml index 28c7db2..fe0a6c5 100644 --- a/.github/workflows/node.yml +++ b/.github/workflows/node.yml @@ -258,8 +258,8 @@ jobs: - name: Install packages run: | apt-get update && apt-get upgrade -y - apt install ./*.deb - apt-get install cmake + apt install -y ./*.deb + apt-get install -y cmake rm ./*.deb - name: Link Spring TestHarness Module From 7eab716a22e6e97bfe197804f5b5e7e3085965e4 Mon Sep 17 00:00:00 2001 From: Your Name Date: Wed, 31 Jul 2024 11:23:36 +0800 Subject: [PATCH 05/11] test --- .github/workflows/node.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/node.yml b/.github/workflows/node.yml index fe0a6c5..b017ea6 100644 --- a/.github/workflows/node.yml +++ b/.github/workflows/node.yml @@ -261,6 +261,11 @@ jobs: apt install -y ./*.deb apt-get install -y cmake rm ./*.deb + echo "=== after install packages ===" + ls -ltr /usr + ls -ltr /usr/bin/ + ls -ltr /usr/lib/ + ls -ltr /usr/share/ - name: Link Spring TestHarness Module run: ln -s /usr/share/spring_testing/tests/TestHarness /usr/lib/python3/dist-packages/TestHarness From 00d60a6269422146963aab9a55f702b702b5cca1 Mon Sep 17 00:00:00 2001 From: Your Name Date: Wed, 31 Jul 2024 14:00:39 +0800 Subject: [PATCH 06/11] test --- .github/workflows/node.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.github/workflows/node.yml b/.github/workflows/node.yml index b017ea6..0fb8ae5 100644 --- a/.github/workflows/node.yml +++ b/.github/workflows/node.yml @@ -266,6 +266,10 @@ jobs: ls -ltr /usr/bin/ ls -ltr /usr/lib/ ls -ltr /usr/share/ + echo "=== files in /usr/share/spring_testing ===" + ls -ltr /usr/share/spring_testing/ + echo "=== files in /usr/share/spring_testing/bin ===" + ls -ltr /usr/share/spring_testing/bin/ - name: Link Spring TestHarness Module run: ln -s /usr/share/spring_testing/tests/TestHarness /usr/lib/python3/dist-packages/TestHarness From 11242244f8f7e6f314a220e84c7e975155a0ce11 Mon Sep 17 00:00:00 2001 From: Your Name Date: Wed, 31 Jul 2024 17:22:11 +0800 Subject: [PATCH 07/11] test --- .github/workflows/node.yml | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/.github/workflows/node.yml b/.github/workflows/node.yml index 0fb8ae5..ad75683 100644 --- a/.github/workflows/node.yml +++ b/.github/workflows/node.yml @@ -255,6 +255,16 @@ jobs: artifact-name: antelope-spring-dev-ubuntu22-amd64 container-package: antelope-spring-experimental-binaries + - name: Download antelope-spring binary + uses: AntelopeIO/asset-artifact-download-action@v3 + with: + owner: AntelopeIO + repo: spring + file: 'antelope-spring_.*_amd64.deb' + target: '${{needs.versions.outputs.antelope-spring-dev-target}}' + prereleases: ${{fromJSON(needs.versions.outputs.antelope-spring-dev-prerelease)}} + artifact-name: antelope-spring-deb-amd64 + - name: Install packages run: | apt-get update && apt-get upgrade -y From 3200add4d5b06f331a8fff04b5479608f4e58c49 Mon Sep 17 00:00:00 2001 From: kayan Date: Thu, 1 Aug 2024 12:42:44 +0800 Subject: [PATCH 08/11] test --- tests/nodeos_eos_evm_test.py | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/tests/nodeos_eos_evm_test.py b/tests/nodeos_eos_evm_test.py index bf8ec70..24b96a5 100755 --- a/tests/nodeos_eos_evm_test.py +++ b/tests/nodeos_eos_evm_test.py @@ -1056,6 +1056,13 @@ def get_block(num): # Validate all balances (check evmtx event) validate_all_balances() + sys.stdout.flush() + sys.stderr.flush() + + Utils.Print("checking %s for errors" % (nodeStdErrDir)) + sys.stdout.flush() + sys.stderr.flush() + foundErr = False stdErrFile = open(nodeStdErrDir, "r") lines = stdErrFile.readlines() @@ -1064,6 +1071,10 @@ def get_block(num): Utils.Print(" Found ERROR in EOS EVM NODE log: ", line) foundErr = True + Utils.Print("checking %s for errors" % (rpcStdErrDir)) + sys.stdout.flush() + sys.stderr.flush() + stdErrFile = open(rpcStdErrDir, "r") lines = stdErrFile.readlines() for line in lines: @@ -1072,9 +1083,24 @@ def get_block(num): foundErr = True testSuccessful= not foundErr + + if testSuccessful: + Utils.Print("test success, ready to shut down cluster") + else: + Utils.Print("test failed, ready to shut down cluster") + + sys.stdout.flush() + sys.stderr.flush() finally: + Utils.Print("test success, shutting down cluster") + sys.stdout.flush() + sys.stderr.flush() + TestHelper.shutdown(cluster, walletMgr, testSuccessful=testSuccessful, dumpErrorDetails=dumpErrorDetails) if killEosInstances: + Utils.Print("killing EOS instances") + sys.stdout.flush() + sys.stderr.flush() if evmNodePOpen is not None: evmNodePOpen.kill() if evmRPCPOpen is not None: From 6254459a671b9821121ef063975b80d2af057c21 Mon Sep 17 00:00:00 2001 From: kayan Date: Fri, 2 Aug 2024 14:35:08 +0800 Subject: [PATCH 09/11] remove leap --- .cicd/defaults.json | 8 ------- .github/workflows/node.yml | 46 +++----------------------------------- 2 files changed, 3 insertions(+), 51 deletions(-) diff --git a/.cicd/defaults.json b/.cicd/defaults.json index a785b0a..9d6424d 100644 --- a/.cicd/defaults.json +++ b/.cicd/defaults.json @@ -3,14 +3,6 @@ "target":"main", "prerelease":false }, - "leap-dev":{ - "target":"5", - "prerelease":false - }, - "leap":{ - "target":"5", - "prerelease":false - }, "cdt":{ "target":"3.1.0", "prerelease":false diff --git a/.github/workflows/node.yml b/.github/workflows/node.yml index ad75683..08b2b74 100644 --- a/.github/workflows/node.yml +++ b/.github/workflows/node.yml @@ -8,26 +8,6 @@ on: pull_request: workflow_dispatch: inputs: - override-leap-dev: - description: Override leap-dev target - type: string - override-leap-dev-prerelease: - type: choice - description: Override leap-dev prelease - options: - - default - - true - - false - override-leap: - description: Override leap target - type: string - override-leap-prerelease: - type: choice - description: Override leap prelease - options: - - default - - true - - false override-cdt: description: 'Override cdt target' type: string @@ -155,10 +135,6 @@ jobs: outputs: antelope-spring-dev-target: ${{steps.versions.outputs.antelope-spring-dev-target}} antelope-spring-dev-prerelease: ${{steps.versions.outputs.antelope-spring-dev-prerelease}} - leap-dev-target: ${{steps.versions.outputs.leap-dev-target}} - leap-dev-prerelease: ${{steps.versions.outputs.leap-dev-prerelease}} - leap-target: ${{steps.versions.outputs.leap-target}} - leap-prerelease: ${{steps.versions.outputs.leap-prerelease}} cdt-target: ${{steps.versions.outputs.cdt-target}} cdt-prerelease: ${{steps.versions.outputs.cdt-prerelease}} eos-evm-contract-target: ${{steps.versions.outputs.eos-evm-contract-target}} @@ -173,28 +149,12 @@ jobs: DEFAULTS_JSON=$(curl -sSfL $(gh api https://api.github.com/repos/${{github.repository}}/contents/.cicd/defaults.json?ref=${{github.sha}} --jq .download_url)) echo antelope-spring-dev-target=$(echo "$DEFAULTS_JSON" | jq -r '."antelope-spring-dev".target') >> $GITHUB_OUTPUT echo antelope-spring-dev-prerelease=$(echo "$DEFAULTS_JSON" | jq -r '."antelope-spring-dev".prerelease') >> $GITHUB_OUTPUT - echo leap-dev-target=$(echo "$DEFAULTS_JSON" | jq -r '."leap-dev".target') >> $GITHUB_OUTPUT - echo leap-dev-prerelease=$(echo "$DEFAULTS_JSON" | jq -r '."leap-dev".prerelease') >> $GITHUB_OUTPUT - echo leap-target=$(echo "$DEFAULTS_JSON" | jq -r '."leap".target') >> $GITHUB_OUTPUT - echo leap-prerelease=$(echo "$DEFAULTS_JSON" | jq -r '."leap".prerelease') >> $GITHUB_OUTPUT echo cdt-target=$(echo "$DEFAULTS_JSON" | jq -r '."cdt".target') >> $GITHUB_OUTPUT echo cdt-prerelease=$(echo "$DEFAULTS_JSON" | jq -r '."cdt".prerelease') >> $GITHUB_OUTPUT echo eos-evm-contract-target=$(echo "$DEFAULTS_JSON" | jq -r '."eos-evm-contract".target') >> $GITHUB_OUTPUT echo eos-evm-contract-prerelease=$(echo "$DEFAULTS_JSON" | jq -r '."eos-evm-contract".prerelease') >> $GITHUB_OUTPUT echo eos-evm-miner-target=$(echo "$DEFAULTS_JSON" | jq -r '."eos-evm-miner".target') >> $GITHUB_OUTPUT - if [[ "${{inputs.override-leap-dev}}" != "" ]]; then - echo leap-dev-target=${{inputs.override-leap-dev}} >> $GITHUB_OUTPUT - fi - if [[ "${{inputs.override-leap-dev-prerelease}}" == +(true|false) ]]; then - echo leap-dev-prerelease=${{inputs.override-leap-dev-prerelease}} >> $GITHUB_OUTPUT - fi - if [[ "${{inputs.override-leap}}" != "" ]]; then - echo leap-target=${{inputs.override-leap}} >> $GITHUB_OUTPUT - fi - if [[ "${{inputs.override-leap-prerelease}}" == +(true|false) ]]; then - echo leap-prerelease=${{inputs.override-leap-prerelease}} >> $GITHUB_OUTPUT - fi if [[ "${{inputs.override-cdt}}" != "" ]]; then echo cdt-target=${{inputs.override-cdt}} >> $GITHUB_OUTPUT fi @@ -448,11 +408,11 @@ jobs: - name: Prepare Logs if: failure() run: | - tar -czf leap-int-test-logs.tar.gz test_run_root/* ws_test_run_root/* + tar -czf sprint-int-test-logs.tar.gz test_run_root/* ws_test_run_root/* - name: Upload logs from failed tests uses: actions/upload-artifact@v3 if: failure() with: - name: leap-int-test-logs.tar.gz - path: leap-int-test-logs.tar.gz + name: spring-int-test-logs.tar.gz + path: spring-int-test-logs.tar.gz From 9c75dedf93a7fd9c4cecaf38a98ba661ab098ab1 Mon Sep 17 00:00:00 2001 From: kayan Date: Mon, 5 Aug 2024 11:35:20 +0800 Subject: [PATCH 10/11] remove logs --- tests/nodeos_eos_evm_test.py | 17 ----------------- 1 file changed, 17 deletions(-) diff --git a/tests/nodeos_eos_evm_test.py b/tests/nodeos_eos_evm_test.py index 24b96a5..2f6736a 100755 --- a/tests/nodeos_eos_evm_test.py +++ b/tests/nodeos_eos_evm_test.py @@ -1056,13 +1056,7 @@ def get_block(num): # Validate all balances (check evmtx event) validate_all_balances() - sys.stdout.flush() - sys.stderr.flush() - Utils.Print("checking %s for errors" % (nodeStdErrDir)) - sys.stdout.flush() - sys.stderr.flush() - foundErr = False stdErrFile = open(nodeStdErrDir, "r") lines = stdErrFile.readlines() @@ -1072,9 +1066,6 @@ def get_block(num): foundErr = True Utils.Print("checking %s for errors" % (rpcStdErrDir)) - sys.stdout.flush() - sys.stderr.flush() - stdErrFile = open(rpcStdErrDir, "r") lines = stdErrFile.readlines() for line in lines: @@ -1083,24 +1074,16 @@ def get_block(num): foundErr = True testSuccessful= not foundErr - if testSuccessful: Utils.Print("test success, ready to shut down cluster") else: Utils.Print("test failed, ready to shut down cluster") - sys.stdout.flush() - sys.stderr.flush() finally: Utils.Print("test success, shutting down cluster") - sys.stdout.flush() - sys.stderr.flush() - TestHelper.shutdown(cluster, walletMgr, testSuccessful=testSuccessful, dumpErrorDetails=dumpErrorDetails) if killEosInstances: Utils.Print("killing EOS instances") - sys.stdout.flush() - sys.stderr.flush() if evmNodePOpen is not None: evmNodePOpen.kill() if evmRPCPOpen is not None: From 4764911f93cbee6e1a429c62b2ec6bd1578b2f15 Mon Sep 17 00:00:00 2001 From: Matias Romeo Date: Mon, 5 Aug 2024 20:34:00 -0300 Subject: [PATCH 11/11] Update silkworm with kGasCap=100M --- external/silkworm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/external/silkworm b/external/silkworm index c4da9c7..4b28334 160000 --- a/external/silkworm +++ b/external/silkworm @@ -1 +1 @@ -Subproject commit c4da9c735207b8d2a2a018ebfc6bb9f3bfd3add4 +Subproject commit 4b283349f765c6d7010b2b5a51cc8f10ac11520b