Skip to content

Commit

Permalink
fix(taiko-client): revert path changes about SocialScan endpoint (#18119
Browse files Browse the repository at this point in the history
)
  • Loading branch information
YoGhurt111 authored and mask-pp committed Sep 17, 2024
1 parent 109595e commit 7d6db54
Show file tree
Hide file tree
Showing 2 changed files with 46 additions and 2 deletions.
46 changes: 45 additions & 1 deletion packages/taiko-client/integration_test/hive_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ func TestHiveHandler(t *testing.T) {

clientGroups := [][]string{
{
"taiko/anvil",
"anvil",
"taiko/taiko-geth",
"taiko/driver",
"taiko/proposer",
Expand Down Expand Up @@ -46,6 +46,50 @@ func TestHiveHandler(t *testing.T) {
t.Run("taiko-reorg/taiko-reorg/clusters(1)", func(t *testing.T) {
testDenebReorg(t, "taiko-reorg/taiko-reorg", [][]string{clientGroups[0]})
})

t.Run("taiko-blob/blob-l1-beacon", func(t *testing.T) {
testBlobScan(t, "taiko-blob/blob-server", []string{
"geth",
"prysm/prysm-bn",
"prysm/prysm-vc",
"taiko/taiko-geth",
"taiko/driver",
"taiko/proposer",
"taiko/prover",
"storage/redis",
"storage/postgres",
"blobscan/blobscan-api",
"blobscan/blobscan-indexer",
})
})

t.Run("taiko-blob/blob-server", func(t *testing.T) {
testBlobScan(t, "taiko-blob/blob-l1-beacon", []string{
"geth",
"prysm/prysm-bn",
"prysm/prysm-vc",
"taiko/taiko-geth",
"taiko/driver",
"taiko/proposer",
"taiko/prover",
})
})
}

func testBlobScan(t *testing.T, pattern string, clients []string) {
handler, err := hivesim.NewHiveFramework(&hivesim.HiveConfig{
BuildOutput: false,
ContainerOutput: true,
BaseDir: "/Users/huan/projects/taiko/hive",
SimPattern: "taiko",
SimTestPattern: pattern,
ClientGroups: [][]string{clients},
})
assert.NoError(t, err)

failedCount, err := handler.Run(context.Background())
assert.NoError(t, err)
assert.Equal(t, 0, failedCount)
}

func testDenebGenesis(t *testing.T, simPattern string, clientGroups [][]string) {
Expand Down
2 changes: 1 addition & 1 deletion packages/taiko-client/pkg/rpc/blob_datasource.go
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ func (ds *BlobDataSource) getBlobFromServer(ctx context.Context, blobHash common
err error
)
if ds.socialScanEndpoint != nil {
route = "/blobs/" + blobHash.String()
route = "/blob/" + blobHash.String()
requestURL, err = url.JoinPath(ds.socialScanEndpoint.String(), route)
} else {
route = "/blobs/" + blobHash.String()
Expand Down

0 comments on commit 7d6db54

Please sign in to comment.