Skip to content

Commit

Permalink
feat(taiko-client): updates for protocol preconfirmation changes (#17690
Browse files Browse the repository at this point in the history
)

Co-authored-by: gavin <[email protected]>
Co-authored-by: YoGhurt111 <[email protected]>
Co-authored-by: Jeffery Walsh <[email protected]>
Co-authored-by: jeff <[email protected]>
Co-authored-by: cyberhorsey <[email protected]>
  • Loading branch information
6 people authored Jul 16, 2024
1 parent 14f5b94 commit 0b2a987
Show file tree
Hide file tree
Showing 44 changed files with 3,002 additions and 152 deletions.
5 changes: 5 additions & 0 deletions .github/workflows/taiko-client--docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@ on:
- "taiko-client-v*"
paths:
- "packages/taiko-client/**"
pull_request:
paths:
- "packages/taiko-client/**"
- "go.mod"
- "go.sum"

jobs:
push-docker-image:
Expand Down
8 changes: 8 additions & 0 deletions packages/protocol/script/DeployOnL1.s.sol
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ import "../test/common/erc20/FreeMintERC20.sol";
import "../test/common/erc20/MayFailFreeMintERC20.sol";
import "../test/L1/TestTierProvider.sol";
import "../test/DeployCapability.sol";
import "../contracts/L1/SequencerRegistry.sol";

// Actually this one is deployed already on mainnet, but we are now deploying our own (non via-ir)
// version. For mainnet, it is easier to go with one of:
Expand Down Expand Up @@ -251,6 +252,13 @@ contract DeployOnL1 is DeployCapability {
copyRegister(rollupAddressManager, _sharedAddressManager, "signal_service");
// copyRegister(rollupAddressManager, _sharedAddressManager, "bridge");

deployProxy({
name: "sequencer_registry",
impl: address(new SequencerRegistry()),
data: abi.encodeCall(SequencerRegistry.init, (owner)),
registerTo: rollupAddressManager
});

deployProxy({
name: "taiko",
impl: address(new TaikoL1()),
Expand Down
2 changes: 1 addition & 1 deletion packages/taiko-client/bindings/.githead
Original file line number Diff line number Diff line change
@@ -1 +1 @@
3c95477a284ac94c7e3ce85c9cefdadc1aaacd06
c9b2d94656751e368a82a16f9e2170d022636a58
38 changes: 26 additions & 12 deletions packages/taiko-client/bindings/encoding/input.go
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,14 @@ var (
Name: "signature",
Type: "bytes",
},
{
Name: "l1StateBlockNumber",
Type: "uint32",
},
{
Name: "timestamp",
Type: "uint64",
},
}
proverAssignmentComponents = []abi.ArgumentMarshaling{
{
Expand Down Expand Up @@ -239,18 +247,19 @@ var (

// Contract ABIs.
var (
TaikoL1ABI *abi.ABI
TaikoL2ABI *abi.ABI
TaikoTokenABI *abi.ABI
GuardianProverABI *abi.ABI
LibProposingABI *abi.ABI
LibProvingABI *abi.ABI
LibUtilsABI *abi.ABI
LibVerifyingABI *abi.ABI
AssignmentHookABI *abi.ABI
SGXVerifierABI *abi.ABI
GuardianVerifierABI *abi.ABI
ProverSetABI *abi.ABI
TaikoL1ABI *abi.ABI
TaikoL2ABI *abi.ABI
TaikoTokenABI *abi.ABI
GuardianProverABI *abi.ABI
LibProposingABI *abi.ABI
LibProvingABI *abi.ABI
LibUtilsABI *abi.ABI
LibVerifyingABI *abi.ABI
AssignmentHookABI *abi.ABI
SGXVerifierABI *abi.ABI
GuardianVerifierABI *abi.ABI
ProverSetABI *abi.ABI
SequencerRegistryABI *abi.ABI

customErrorMaps []map[string]abi.Error
)
Expand Down Expand Up @@ -306,6 +315,10 @@ func init() {
log.Crit("Get ProverSet ABI error", "error", err)
}

if SequencerRegistryABI, err = bindings.SequencerRegistryMetaData.GetAbi(); err != nil {
log.Crit("Get SequencerRegistry ABI error", "error", err)
}

customErrorMaps = []map[string]abi.Error{
TaikoL1ABI.Errors,
TaikoL2ABI.Errors,
Expand All @@ -318,6 +331,7 @@ func init() {
SGXVerifierABI.Errors,
GuardianVerifierABI.Errors,
ProverSetABI.Errors,
SequencerRegistryABI.Errors,
}
}

Expand Down
14 changes: 8 additions & 6 deletions packages/taiko-client/bindings/encoding/struct.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,14 @@ type HookCall struct {

// BlockParams should be same with TaikoData.BlockParams.
type BlockParams struct {
AssignedProver common.Address
Coinbase common.Address
ExtraData [32]byte
ParentMetaHash [32]byte
HookCalls []HookCall
Signature []byte
AssignedProver common.Address
Coinbase common.Address
ExtraData [32]byte
ParentMetaHash [32]byte
HookCalls []HookCall
Signature []byte
L1StateBlockNumber uint32
Timestamp uint64
}

// TierFee should be same with TaikoData.TierFee.
Expand Down
35 changes: 35 additions & 0 deletions packages/taiko-client/bindings/gen_guardian_prover.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 0b2a987

Please sign in to comment.