Skip to content

qa-tests: use a specific version of the prebuilt db in RPC tests#19565

Open
mriccobene wants to merge 1 commit intomainfrom
qa-tests/rpc_test_use_specific_version
Open

qa-tests: use a specific version of the prebuilt db in RPC tests#19565
mriccobene wants to merge 1 commit intomainfrom
qa-tests/rpc_test_use_specific_version

Conversation

@mriccobene
Copy link
Member

This PR allows us to use different DB versions between main branch and release branch to avoid any incompatibility problems between databases

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates QA RPC-related GitHub Actions workflows to use a version-pinned prebuilt DB path, intended to let release branches run against a DB compatible with that release.

Changes:

  • Pin ERIGON_REFERENCE_DATA_DIR to /opt/erigon-versions/*reference-version-3.4*/datadir in multiple RPC performance and integration workflows.
  • Apply the same pinning for the Gnosis RPC integration workflow.

Reviewed changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
.github/workflows/qa-rpc-performance-tests.yml Pins the reference datadir used by the historic RPC performance workflow.
.github/workflows/qa-rpc-performance-comparison-tests.yml Pins the reference datadir used by the “latest” RPC performance comparison workflow.
.github/workflows/qa-rpc-integration-tests.yml Pins the reference datadir used by mainnet RPC integration tests.
.github/workflows/qa-rpc-integration-tests-remote.yml Pins the reference datadir used by mainnet RPC integration tests (remote).
.github/workflows/qa-rpc-integration-tests-latest.yml Pins the reference datadir used by “latest” mainnet RPC integration tests.
.github/workflows/qa-rpc-integration-tests-gnosis.yml Pins the reference datadir used by Gnosis RPC integration tests.
Comments suppressed due to low confidence (4)

.github/workflows/qa-rpc-integration-tests.yml:36

  • This workflow triggers for both main and release/3.* (including PRs), but ERIGON_REFERENCE_DATA_DIR is now hardcoded to a 3.4 datadir. If main is supposed to keep using the main DB while release uses 3.4, make the path conditional on the target branch (use github.base_ref for PRs, github.ref_name for push/workflow_dispatch).
    env:
      ERIGON_REFERENCE_DATA_DIR: /opt/erigon-versions/reference-version-3.4/datadir
      ERIGON_TESTBED_AREA: /opt/erigon-testbed
      ERIGON_QA_PATH: /home/qarunner/erigon-qa
      ERIGON_ASSERT: true
      RPC_PAST_TEST_DIR: /opt/rpc-past-tests

.github/workflows/qa-rpc-integration-tests-remote.yml:36

  • This workflow triggers for both main and release/3.* (including PRs), but ERIGON_REFERENCE_DATA_DIR is now hardcoded to a 3.4 datadir. To avoid main picking up the release DB, make the reference datadir branch-dependent (github.base_ref for PRs; github.ref_name for pushes).
    env:
      ERIGON_REFERENCE_DATA_DIR: /opt/erigon-versions/reference-version-3.4/datadir
      ERIGON_TESTBED_AREA: /opt/erigon-testbed
      ERIGON_QA_PATH: /home/qarunner/erigon-qa
      ERIGON_ASSERT: true
      RPC_PAST_TEST_DIR: /opt/rpc-past-tests/remote

.github/workflows/qa-rpc-integration-tests-latest.yml:40

  • This workflow only runs on main, but ERIGON_REFERENCE_DATA_DIR is now pinned to reference-version-3.4. If the intent is “main uses main DB, release uses versioned DB”, this pin will prevent main from tracking the main reference DB and can cause unnecessary incompatibilities; consider using the unversioned/main reference path here and pinning only in release workflows (or making it conditional).
    env:
      ERIGON_REFERENCE_DATA_DIR: /opt/erigon-versions/reference-version-3.4/datadir
      ERIGON_TESTBED_DATA_DIR: /opt/erigon-testbed/datadir
      ERIGON_QA_PATH: /home/qarunner/erigon-qa
      TOTAL_TIME_SECONDS: 900 # 15 minutes
      REFERENCE_SYSTEM_HOST_ADDRESS: 157.180.55.78:8545

.github/workflows/qa-rpc-integration-tests-gnosis.yml:36

  • This workflow triggers for both main and release/3.* (including PRs), but ERIGON_REFERENCE_DATA_DIR is now hardcoded to the 3.4 gnosis reference datadir. If main should continue using the unversioned gnosis reference DB, make this path conditional based on github.ref/base_ref so main and release can diverge as intended.
    env:
      ERIGON_REFERENCE_DATA_DIR: /opt/erigon-versions/gnosis-reference-version-3.4/datadir
      ERIGON_TESTBED_AREA: /opt/erigon-testbed
      ERIGON_QA_PATH: /home/qarunner/erigon-qa
      ERIGON_ASSERT: true
      RPC_PAST_TEST_DIR: /opt/rpc-past-tests

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment on lines 97 to 102
RUN_ID: ${{ needs.setup.outputs.run_id }}
NETWORK: ${{ needs.setup.outputs.network }}
ERIGON_REFERENCE_DIR: /opt/erigon-versions/reference-version
ERIGON_REFERENCE_DATA_DIR: /opt/erigon-versions/reference-version/datadir
ERIGON_REFERENCE_DATA_DIR: /opt/erigon-versions/reference-version-3.4/datadir
ERIGON_TESTBED_DATA_DIR: /opt/erigon-testbed/datadir
TOTAL_TIME_SECONDS: 1200 # 20 minutes
Copy link

Copilot AI Mar 2, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ERIGON_REFERENCE_DATA_DIR is hardcoded to a release-specific DB path, but this workflow runs on schedule from the default branch as well. To achieve the PR goal of different DBs on main vs release, select the reference datadir based on github.ref/base_ref (e.g., keep /opt/erigon-versions/reference-version/datadir for main and use the versioned directory only for release/*).

Copilot uses AI. Check for mistakes.
@@ -97,7 +97,7 @@ jobs:
RUN_ID: ${{ needs.setup.outputs.run_id }}
NETWORK: ${{ needs.setup.outputs.network }}
ERIGON_REFERENCE_DIR: /opt/erigon-versions/reference-version
Copy link

Copilot AI Mar 2, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ERIGON_REFERENCE_DATA_DIR is now versioned, but ERIGON_REFERENCE_DIR remains unversioned and is later used to read production.ini for db_version. This can desync the metadata you record from the actual reference datadir under test; consider reading production.ini relative to ERIGON_REFERENCE_DATA_DIR (../production.ini) or versioning ERIGON_REFERENCE_DIR together with the datadir selection.

Suggested change
ERIGON_REFERENCE_DIR: /opt/erigon-versions/reference-version
ERIGON_REFERENCE_DIR: /opt/erigon-versions/reference-version-3.4

Copilot uses AI. Check for mistakes.
@@ -88,7 +88,7 @@ jobs:
RUN_ID: ${{ needs.setup.outputs.run_id }}
NETWORK: ${{ needs.setup.outputs.network }}
ERIGON_REFERENCE_DIR: /opt/erigon-versions/reference-version
Copy link

Copilot AI Mar 2, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ERIGON_REFERENCE_DATA_DIR now points at a versioned DB, but ERIGON_REFERENCE_DIR is still the unversioned path and is later used to read production.ini for db_version. This can make the reported DB version (and potentially other reference metadata) inconsistent with the actual datadir being tested; consider deriving production.ini from ERIGON_REFERENCE_DATA_DIR (../production.ini) or versioning ERIGON_REFERENCE_DIR in lockstep. Also note this workflow runs on schedule from the default branch, so hardcoding "-3.4" here will force main’s scheduled runs to use the release DB unless you branch-select the path via github.ref/base_ref.

Suggested change
ERIGON_REFERENCE_DIR: /opt/erigon-versions/reference-version
ERIGON_REFERENCE_DIR: /opt/erigon-versions/reference-version-3.4

Copilot uses AI. Check for mistakes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants