Skip to content

Commit 9cb92a5

Browse files
committed
Merge remote-tracking branch 'origin/master' into proto-getter
Signed-off-by: litt3 <[email protected]>
2 parents 9f3b417 + 6454a33 commit 9cb92a5

File tree

82 files changed

+2779
-7319
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

82 files changed

+2779
-7319
lines changed

.github/workflows/integration-tests.yml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -76,9 +76,6 @@ jobs:
7676
- name: Node Plugin
7777
run: go test -v ./node/plugin/tests
7878

79-
- name: eigenda-client
80-
run: go test -v ./api/clients --testnet-integration
81-
8279
- name: Inabox E2E
8380
run: make build && cd inabox && make run-e2e
8481

.github/workflows/live-network-tests.yaml

Lines changed: 56 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ env:
99
MISE_VERSION: 2024.12.14
1010

1111
jobs:
12-
test:
12+
test-v2:
1313
runs-on: ubuntu-latest
1414
env:
1515
LIVE_TESTS: "true"
@@ -31,6 +31,61 @@ jobs:
3131
- name: Run Live Network Tests
3232
run: make live-tests
3333

34+
- name: Notify Slack
35+
if: always()
36+
run: |
37+
if [ "${{ job.status }}" == "success" ]; then
38+
COLOR="good"
39+
STATUS_EMOJI="✅"
40+
MENTION=""
41+
else
42+
COLOR="danger"
43+
STATUS_EMOJI="❌"
44+
MENTION="@here "
45+
fi
46+
47+
PAYLOAD=$(jq -n \
48+
--arg channel "#da-live-tests" \
49+
--arg text "${MENTION}Live Network Tests completed, status: ${STATUS_EMOJI} ${{ job.status }}" \
50+
--arg title "logs" \
51+
--arg title_link "${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}" \
52+
--arg color "$COLOR" \
53+
'{
54+
channel: $channel,
55+
text: $text,
56+
attachments: [
57+
{
58+
color: $color,
59+
title: $title,
60+
title_link: $title_link
61+
}
62+
]
63+
}')
64+
65+
curl -X POST -H "Authorization: Bearer ${{ secrets.DA_TEST_REPORTER_SLACK_OATH_TOKEN }}" \
66+
-H 'Content-type: application/json; charset=utf-8' \
67+
--data "$PAYLOAD" \
68+
https://slack.com/api/chat.postMessage
69+
70+
71+
test-v1:
72+
runs-on: ubuntu-latest
73+
steps:
74+
- name: Checkout repository
75+
uses: actions/checkout@v4
76+
77+
- uses: jdx/mise-action@v2
78+
with:
79+
version: ${{ env.MISE_VERSION }}
80+
experimental: true
81+
- run: go version
82+
83+
- name: Install dependencies
84+
run: go mod download
85+
86+
- name: Run live v1 eigenda-client tests
87+
run: make live-tests-v1
88+
3489
- name: Notify Slack
3590
if: always()
3691
run: |

.gitignore

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
inabox/testdata/*
22
inabox/anvil.pid
33

4-
test/testdata/*
4+
test/v1/testdata/*
55
inabox/resources/kzg/SRSTables/*
66
encoding/kzgrs/prover/data/SRSTable/*
77
resources/srs/SRSTables/*
@@ -17,8 +17,7 @@ lightnode/docker/args.sh
1717
.idea
1818
.env
1919
.vscode
20-
.cursor
21-
.serena
20+
.claude
2221

2322
icicle/*
2423

Makefile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -89,6 +89,8 @@ unit-tests:
8989

9090
live-tests:
9191
go test -v ./test/v2/live -v -timeout 60m
92+
live-tests-v1:
93+
go test -v ./api/clients --live-test
9294

9395
fuzz-tests:
9496
go test --fuzz=FuzzParseSignatureKMS -fuzztime=5m ./common

api/clients/eigenda_client_e2e_test.go renamed to api/clients/eigenda_client_e2e_live_test.go

Lines changed: 27 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -12,46 +12,60 @@ import (
1212
"github.com/stretchr/testify/assert"
1313
)
1414

15-
var runTestnetIntegrationTests bool
15+
var runTestnetLiveTests bool
16+
17+
const (
18+
// Test configuration constants
19+
testRPC = "disperser-holesky.eigenda.xyz:443"
20+
// TODO: we should use a more reliable RPC provider, injected via secrets
21+
testEthRpcUrl = "https://ethereum-holesky-rpc.publicnode.com"
22+
testSignerPrivateKeyHex = "2d23e142a9e86a9175b9dfa213f20ea01f6c1731e09fa6edf895f70fe279cbb1"
23+
testSvcManagerAddr = "0xD4A7E1Bd8015057293f0D0A557088c286942e84b"
24+
testStatusQueryTimeout = 20 * time.Minute
25+
testStatusQueryRetryInterval = 5 * time.Second
26+
)
1627

1728
func init() {
18-
flag.BoolVar(&runTestnetIntegrationTests, "testnet-integration", false, "Run testnet-based integration tests")
29+
// Off by default so that this test is not run as part of the unit tests.
30+
// To run it, use the flag -live-test when running `go test`.`
31+
flag.BoolVar(&runTestnetLiveTests, "live-test", false, "Run live test against holesky testnet")
1932
}
2033

2134
// TestClientUsingTestnet tests the eigenda client against holesky testnet disperser.
2235
// We don't test waiting for finality because that adds 12 minutes to the test, and is not necessary
2336
// because we already test for this in the unit tests using a mock disperser which is much faster.
2437
func TestClientUsingTestnet(t *testing.T) {
25-
if !runTestnetIntegrationTests {
26-
t.Skip("Skipping testnet integration test")
38+
if !runTestnetLiveTests {
39+
t.Skip("Skipping testnet live test")
2740
}
2841

2942
t.Run("PutBlobWaitForConfirmationDepth0AndGetBlob", func(t *testing.T) {
3043
t.Parallel()
3144

3245
client, err := NewEigenDAClient(testutils.GetLogger(), EigenDAClientConfig{
33-
RPC: "disperser-holesky.eigenda.xyz:443",
46+
RPC: testRPC,
3447
// Should need way less than 20 minutes, but we set it to 20 minutes to be safe
3548
// In worst case we had 10 min batching interval + some time for the tx to land onchain,
3649
// plus wait for 3 blocks of confirmation.
37-
StatusQueryTimeout: 20 * time.Minute,
38-
StatusQueryRetryInterval: 5 * time.Second,
50+
StatusQueryTimeout: testStatusQueryTimeout,
51+
StatusQueryRetryInterval: testStatusQueryRetryInterval,
3952
CustomQuorumIDs: []uint{},
40-
SignerPrivateKeyHex: "2d23e142a9e86a9175b9dfa213f20ea01f6c1731e09fa6edf895f70fe279cbb1",
53+
SignerPrivateKeyHex: testSignerPrivateKeyHex,
4154
WaitForFinalization: false,
4255
WaitForConfirmationDepth: 0,
43-
SvcManagerAddr: "0xD4A7E1Bd8015057293f0D0A557088c286942e84b",
44-
EthRpcUrl: "https://1rpc.io/holesky",
56+
SvcManagerAddr: testSvcManagerAddr,
57+
EthRpcUrl: testEthRpcUrl,
4558
})
46-
data := "hello world!"
4759
assert.NoError(t, err)
48-
blobInfo, err := client.PutBlob(context.Background(), []byte(data))
60+
61+
testData := "hello world!"
62+
blobInfo, err := client.PutBlob(context.Background(), []byte(testData))
4963
assert.NoError(t, err)
5064
batchHeaderHash := blobInfo.GetBlobVerificationProof().GetBatchMetadata().GetBatchHeaderHash()
5165
blobIndex := blobInfo.GetBlobVerificationProof().GetBlobIndex()
5266
blob, err := client.GetBlob(context.Background(), batchHeaderHash, blobIndex)
5367
assert.NoError(t, err)
54-
assert.Equal(t, data, string(blob))
68+
assert.Equal(t, testData, string(blob))
5569
})
5670

5771
t.Run("PutBlobWaitForConfirmationDepth3AndGetBlob", func(t *testing.T) {

0 commit comments

Comments
 (0)