Skip to content

Commit

Permalink
Merge branch 'optimal-commits' into replace-history-commits
Browse files Browse the repository at this point in the history
  • Loading branch information
rauljordan authored Sep 18, 2024
2 parents c1bce8f + 0091ccc commit 242b86c
Show file tree
Hide file tree
Showing 29 changed files with 94 additions and 277 deletions.
3 changes: 1 addition & 2 deletions BUILD.bazel
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
# gazelle:ignore
load("@bazel_gazelle//:def.bzl", "gazelle")
load("@io_bazel_rules_go//go:def.bzl", "TOOLS_NOGO", "nogo")

# gazelle:prefix github.com/OffchainLabs/bold
gazelle(name = "gazelle")
Expand All @@ -14,8 +15,6 @@ gazelle(
command = "update-repos",
)

load("@io_bazel_rules_go//go:def.bzl", "TOOLS_NOGO", "go_binary", "go_library", "nogo")

nogo(
name = "nogo",
config = ":nogo.json",
Expand Down
2 changes: 1 addition & 1 deletion WORKSPACE
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ http_archive(
],
)

load("@io_bazel_rules_go//go:deps.bzl", "go_register_toolchains", "go_rules_dependencies")
load("@bazel_gazelle//:deps.bzl", "gazelle_dependencies")
load("@io_bazel_rules_go//go:deps.bzl", "go_register_toolchains", "go_rules_dependencies")
load("//:deps.bzl", "go_dependencies")

# gazelle:repository_macro deps.bzl%go_dependencies
Expand Down
1 change: 1 addition & 0 deletions api/db/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -32,4 +32,5 @@ go_test(
"@com_github_mattn_go_sqlite3//:go-sqlite3",
"@com_github_stretchr_testify//require",
],
size = "small",
)
1 change: 1 addition & 0 deletions assertions/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -57,4 +57,5 @@ go_test(
"@com_github_ethereum_go_ethereum//common",
"@com_github_stretchr_testify//require",
],
size = "small",
)
7 changes: 2 additions & 5 deletions assertions/manager_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -418,8 +418,7 @@ func TestFastConfirmation(t *testing.T) {

ctx, cancel := context.WithTimeout(ctx, time.Second)
defer cancel()
hash := protocol.AssertionHash{Hash: posted.Unwrap().AssertionHash}
expectAssertionConfirmed(t, ctx, setup.Backend, aliceChain.RollupAddress(), hash)
expectAssertionConfirmed(t, ctx, setup.Backend, aliceChain.RollupAddress())
}

func TestFastConfirmationWithSafe(t *testing.T) {
Expand Down Expand Up @@ -543,8 +542,7 @@ func TestFastConfirmationWithSafe(t *testing.T) {
// Only after both Alice and Bob confirm the assertion, it should be confirmed.
ctx, cancel := context.WithTimeout(ctx, time.Second)
defer cancel()
hash := protocol.AssertionHash{Hash: posted.Unwrap().AssertionHash}
expectAssertionConfirmed(t, ctx, setup.Backend, aliceChain.RollupAddress(), hash)
expectAssertionConfirmed(t, ctx, setup.Backend, aliceChain.RollupAddress())
}

type seqMessage struct {
Expand Down Expand Up @@ -590,7 +588,6 @@ func expectAssertionConfirmed(
ctx context.Context,
backend protocol.ChainBackend,
rollupAddr common.Address,
hash protocol.AssertionHash,
) {
rc, err := rollupgen.NewRollupCore(rollupAddr, backend)
require.NoError(t, err)
Expand Down
1 change: 1 addition & 0 deletions chain-abstraction/sol-implementation/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -69,4 +69,5 @@ go_test(
"@com_github_ethereum_go_ethereum//core/types",
"@com_github_stretchr_testify//require",
],
size = "small",
)
1 change: 1 addition & 0 deletions challenge-manager/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -56,4 +56,5 @@ go_test(
"@com_github_ethereum_go_ethereum//common",
"@com_github_stretchr_testify//require",
],
size = "small",
)
1 change: 1 addition & 0 deletions challenge-manager/chain-watcher/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -39,4 +39,5 @@ go_test(
"@com_github_ethereum_go_ethereum//common",
"@com_github_stretchr_testify//require",
],
size = "small",
)
1 change: 1 addition & 0 deletions challenge-manager/challenge-tree/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -45,4 +45,5 @@ go_test(
"@com_github_ethereum_go_ethereum//common",
"@com_github_stretchr_testify//require",
],
size = "small",
)
2 changes: 1 addition & 1 deletion challenge-manager/challenge-tree/add_edge.go
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ func (ht *RoyalChallengeTree) checkAssertionHash(ctx context.Context, id protoco
return nil
}

func (ht *RoyalChallengeTree) claimedAssertionHash(ctx context.Context, eg protocol.SpecEdge) (protocol.AssertionHash, error) {
func (ht *RoyalChallengeTree) claimedAssertionHash(_ context.Context, eg protocol.SpecEdge) (protocol.AssertionHash, error) {
challengeLevel := eg.GetChallengeLevel()
// If this is a root challege level zero edge.
if challengeLevel == protocol.NewBlockChallengeLevel() && !eg.ClaimId().IsNone() {
Expand Down
1 change: 1 addition & 0 deletions containers/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,5 @@ go_test(
srcs = ["slice_test.go"],
embed = [":containers"],
deps = ["@com_github_stretchr_testify//require"],
size = "small",
)
1 change: 1 addition & 0 deletions containers/events/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,5 @@ go_test(
srcs = ["producer_test.go"],
embed = [":events"],
deps = ["@com_github_stretchr_testify//require"],
size = "small",
)
1 change: 1 addition & 0 deletions containers/fsm/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,5 @@ go_test(
srcs = ["fsm_test.go"],
embed = [":fsm"],
deps = ["@com_github_stretchr_testify//require"],
size = "small",
)
15 changes: 0 additions & 15 deletions containers/in-progress-cache/BUILD.bazel

This file was deleted.

77 changes: 0 additions & 77 deletions containers/in-progress-cache/cache.go

This file was deleted.

105 changes: 0 additions & 105 deletions containers/in-progress-cache/cache_test.go

This file was deleted.

1 change: 1 addition & 0 deletions containers/threadsafe/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -28,4 +28,5 @@ go_test(
],
embed = [":threadsafe"],
deps = ["@com_github_stretchr_testify//require"],
size = "small",
)
5 changes: 5 additions & 0 deletions deps.bzl
Original file line number Diff line number Diff line change
@@ -1,6 +1,11 @@
"""
Auto-gneerated deps file managed by gazelle.
"""

load("@bazel_gazelle//:deps.bzl", "go_repository")

def go_dependencies():
"Auto-generated dependencies function."
go_repository(
name = "co_honnef_go_tools",
importpath = "honnef.co/go/tools",
Expand Down
2 changes: 1 addition & 1 deletion layer2-state-provider/BUILD.bazel
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ go_library(
"//api",
"//api/db",
"//chain-abstraction:protocol",
"//containers/in-progress-cache",
"//containers/option",
"//state-commitments/history",
"//state-commitments/prefix-proofs",
Expand All @@ -30,4 +29,5 @@ go_test(
"//containers/option",
"@com_github_stretchr_testify//require",
],
size = "small",
)
Loading

0 comments on commit 242b86c

Please sign in to comment.