From d7489c90305e71a8ebfd6b7eba0a1a3fbc9aeac8 Mon Sep 17 00:00:00 2001 From: Bernat Canal Garceran Date: Mon, 20 May 2024 15:09:58 +0200 Subject: [PATCH 1/6] feat(repo): pr title cleanup (#17269) --- .github/workflows/repo--validate-pr-title.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/repo--validate-pr-title.yml b/.github/workflows/repo--validate-pr-title.yml index 1a58f1fc18a..0897249d0d5 100644 --- a/.github/workflows/repo--validate-pr-title.yml +++ b/.github/workflows/repo--validate-pr-title.yml @@ -40,8 +40,7 @@ jobs: guardian-prover-health-check-ui protocol relayer - taikoon - snaefell-ui + nfts ui-lib taiko-client supplementary-contracts From bca493f686181a9bbe9b6722742efa3fa98eaf99 Mon Sep 17 00:00:00 2001 From: Daniel Wang <99078276+dantaik@users.noreply.github.com> Date: Mon, 20 May 2024 21:11:05 +0800 Subject: [PATCH 2/6] feat(protocol): allow getTransition to be called for all blocks (#17268) Co-authored-by: dantaik --- packages/protocol/contracts/L1/libs/LibUtils.sol | 13 +------------ .../protocol/deployments/mainnet-contract-logs.md | 2 ++ 2 files changed, 3 insertions(+), 12 deletions(-) diff --git a/packages/protocol/contracts/L1/libs/LibUtils.sol b/packages/protocol/contracts/L1/libs/LibUtils.sol index bc59d2f70ff..56f78ca25df 100644 --- a/packages/protocol/contracts/L1/libs/LibUtils.sol +++ b/packages/protocol/contracts/L1/libs/LibUtils.sol @@ -33,7 +33,6 @@ library LibUtils { view returns (TaikoData.TransitionState storage) { - _checkBlockId(_state, _blockId); (TaikoData.Block storage blk, uint64 slot) = getBlock(_state, _config, _blockId); uint32 tid = getTransitionId(_state, blk, slot, _parentHash); @@ -59,7 +58,6 @@ library LibUtils { view returns (TaikoData.TransitionState storage) { - _checkBlockId(_state, _blockId); (TaikoData.Block storage blk, uint64 slot) = getBlock(_state, _config, _blockId); if (_tid == 0 || _tid >= blk.nextTransitionId) revert L1_TRANSITION_NOT_FOUND(); @@ -81,9 +79,7 @@ library LibUtils { { slot_ = _blockId % _config.blockRingBufferSize; blk_ = _state.blocks[slot_]; - if (blk_.blockId != _blockId) { - revert L1_INVALID_BLOCK_ID(); - } + if (blk_.blockId != _blockId) revert L1_INVALID_BLOCK_ID(); } /// @dev Retrieves the ID of the transition with a given parentHash. @@ -121,11 +117,4 @@ library LibUtils { return block.timestamp >= deadline; } } - - function _checkBlockId(TaikoData.State storage _state, uint64 _blockId) private view { - TaikoData.SlotB memory b = _state.slotB; - if (_blockId < b.lastVerifiedBlockId || _blockId >= b.numBlocks) { - revert L1_INVALID_BLOCK_ID(); - } - } } diff --git a/packages/protocol/deployments/mainnet-contract-logs.md b/packages/protocol/deployments/mainnet-contract-logs.md index 92ea78ac4bc..96f748d67d0 100644 --- a/packages/protocol/deployments/mainnet-contract-logs.md +++ b/packages/protocol/deployments/mainnet-contract-logs.md @@ -167,6 +167,8 @@ - deployed on May 1, 2024 @commit `56dddf2b6` - Upgraded from `0x99Ba70E62cab0cB983e66F72330fBDDC11d85501` to `0x9fBBedBBcBb753E7214BE08381efE10d89D712fE` @commit `b90b932` @tx`0x416560cd96dc75ccffebe889e8d1ab3e08b33f814dc4a2bf7c6f9555071d1f6f` - `Init2()` called and reset block hash to `0411D9F84A525864E0A7E8BB51667D49C6BF73820AF9E4BC76EA66ADB6BE8903` @tx `0x7311fee56f87294e336393b55939489bc1e810c402f304013475d04c90ca32a9` +- todo: + - upgrade the implementation again #### assignment_hook From e7111e0a84dcdad0a695c62be69304a02763e4a0 Mon Sep 17 00:00:00 2001 From: maskpp Date: Mon, 20 May 2024 22:52:46 +0800 Subject: [PATCH 3/6] feat(taiko-client): only invalid status need to return error (#17266) Co-authored-by: David --- packages/taiko-client/driver/chain_syncer/beaconsync/syncer.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/taiko-client/driver/chain_syncer/beaconsync/syncer.go b/packages/taiko-client/driver/chain_syncer/beaconsync/syncer.go index d593d868be2..f03a9309d1d 100644 --- a/packages/taiko-client/driver/chain_syncer/beaconsync/syncer.go +++ b/packages/taiko-client/driver/chain_syncer/beaconsync/syncer.go @@ -76,7 +76,7 @@ func (s *Syncer) TriggerBeaconSync(blockID uint64) error { if err != nil { return err } - if fcRes.PayloadStatus.Status != engine.SYNCING { + if fcRes.PayloadStatus.Status == engine.INVALID { return fmt.Errorf("unexpected ForkchoiceUpdate response status: %s", fcRes.PayloadStatus.Status) } From 6e56475413c3240d56d70d413ca5195cd1ced4cc Mon Sep 17 00:00:00 2001 From: David Date: Mon, 20 May 2024 23:29:44 +0800 Subject: [PATCH 4/6] feat(protocol): deploy `ProverSet` in `DeployOnL1` script (#17272) --- packages/protocol/script/DeployOnL1.s.sol | 18 ++++++++++++++++-- packages/protocol/script/test_deploy_on_l1.sh | 1 + 2 files changed, 17 insertions(+), 2 deletions(-) diff --git a/packages/protocol/script/DeployOnL1.s.sol b/packages/protocol/script/DeployOnL1.s.sol index fcd1fbb0971..d19f54de472 100644 --- a/packages/protocol/script/DeployOnL1.s.sol +++ b/packages/protocol/script/DeployOnL1.s.sol @@ -22,6 +22,7 @@ import "../contracts/automata-attestation/AutomataDcapV3Attestation.sol"; import "../contracts/automata-attestation/utils/SigVerifyLib.sol"; import "../contracts/automata-attestation/lib/PEMCertChainLib.sol"; import "../contracts/verifiers/SgxVerifier.sol"; +import "../contracts/team/proving/ProverSet.sol"; import "../test/common/erc20/FreeMintERC20.sol"; import "../test/common/erc20/MayFailFreeMintERC20.sol"; import "../test/L1/TestTierProvider.sol"; @@ -273,7 +274,8 @@ contract DeployOnL1 is DeployCapability { deployProxy({ name: "assignment_hook", impl: address(new AssignmentHook()), - data: abi.encodeCall(AssignmentHook.init, (owner, rollupAddressManager)) + data: abi.encodeCall(AssignmentHook.init, (owner, rollupAddressManager)), + registerTo: rollupAddressManager }); deployProxy({ @@ -301,7 +303,11 @@ contract DeployOnL1 is DeployCapability { register(rollupAddressManager, "tier_guardian_minority", guardianProverMinority); register(rollupAddressManager, "tier_guardian", guardianProver); - register(rollupAddressManager, "tier_provider", address(new TestTierProvider())); + register( + rollupAddressManager, + "tier_provider", + address(deployTierProvider(vm.envString("TIER_PROVIDER"))) + ); address[] memory guardians = vm.envAddress("GUARDIAN_PROVERS", ","); @@ -333,6 +339,14 @@ contract DeployOnL1 is DeployCapability { console2.log("SigVerifyLib", address(sigVerifyLib)); console2.log("PemCertChainLib", address(pemCertChainLib)); console2.log("AutomataDcapVaAttestation", automataProxy); + + deployProxy({ + name: "prover_set", + impl: address(new ProverSet()), + data: abi.encodeCall( + ProverSet.init, (owner, vm.envAddress("PROVER_SET_ADMIN"), rollupAddressManager) + ) + }); } function deployTierProvider(string memory tierProviderName) private returns (address) { diff --git a/packages/protocol/script/test_deploy_on_l1.sh b/packages/protocol/script/test_deploy_on_l1.sh index 28e20309c1e..c4df51742f9 100755 --- a/packages/protocol/script/test_deploy_on_l1.sh +++ b/packages/protocol/script/test_deploy_on_l1.sh @@ -11,6 +11,7 @@ GUARDIAN_PROVERS="0x1000777700000000000000000000000000000001,0x10007777000000000 TAIKO_L2_ADDRESS=0x1000777700000000000000000000000000000001 \ L2_SIGNAL_SERVICE=0x1000777700000000000000000000000000000007 \ CONTRACT_OWNER=0x60997970C51812dc3A010C7d01b50e0d17dc79C8 \ +PROVER_SET_ADMIN=0x60997970C51812dc3A010C7d01b50e0d17dc79C8 \ TAIKO_TOKEN_PREMINT_RECIPIENT=0xa0Ee7A142d267C1f36714E4a8F75612F20a79720 \ TAIKO_TOKEN_NAME="Taiko Token Katla" \ TAIKO_TOKEN_SYMBOL=TTKOk \ From 6b7f44a2e2e6dc9ee63a565c95ba5023e66940c6 Mon Sep 17 00:00:00 2001 From: Bernat Canal Garceran Date: Mon, 20 May 2024 18:54:15 +0200 Subject: [PATCH 5/6] feat(nfts): adapt taikoon-ui to the new package structure (#17271) --- packages/taikoon-ui/package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/taikoon-ui/package.json b/packages/taikoon-ui/package.json index ba8e65b8eac..2805e20384d 100644 --- a/packages/taikoon-ui/package.json +++ b/packages/taikoon-ui/package.json @@ -15,7 +15,7 @@ "test:integration": "playwright test", "test:unit": "vitest", "start": "npm run generate:abi && vite dev --open", - "generate:abi": "cd ../taikoon && pnpm compile && cd - && wagmi generate" + "generate:abi": "cd ../nfts && pnpm compile && cd - && wagmi generate" }, "devDependencies": { "@chromatic-com/storybook": "^1.3.1", From 293618e484e855ee897ae9fd958322401bb867e5 Mon Sep 17 00:00:00 2001 From: d1onys1us <13951458+d1onys1us@users.noreply.github.com> Date: Mon, 20 May 2024 17:24:40 -0400 Subject: [PATCH 6/6] ci(repo): revert and fix workflow triggers (#17275) --- .github/workflows/blobstorage.yml | 3 +++ .github/workflows/bridge-ui.yml | 8 +++----- .github/workflows/eventindexer.yml | 3 +++ .github/workflows/guardian-prover-health-check-ui.yml | 7 ++++--- .github/workflows/guardian-prover-health-check.yml | 3 +++ .github/workflows/relayer.yml | 3 +++ .github/workflows/snaefell-ui.yml | 8 +++----- .github/workflows/taiko-client--test.yml | 3 +++ .github/workflows/taikoon-ui.yml | 7 ++++--- 9 files changed, 29 insertions(+), 16 deletions(-) diff --git a/.github/workflows/blobstorage.yml b/.github/workflows/blobstorage.yml index 7a1fb6109c8..bf1018dbae3 100644 --- a/.github/workflows/blobstorage.yml +++ b/.github/workflows/blobstorage.yml @@ -5,6 +5,9 @@ on: branches: [main] paths: - "packages/blobstorage/**" + pull_request: + paths: + - "packages/blobstorage/**" jobs: test-blobstorage: diff --git a/.github/workflows/bridge-ui.yml b/.github/workflows/bridge-ui.yml index e79231aa272..9f8ce7acb24 100644 --- a/.github/workflows/bridge-ui.yml +++ b/.github/workflows/bridge-ui.yml @@ -2,13 +2,11 @@ name: Bridge UI CI/CD on: push: - branches-ignore: - - main - - release-please-* - paths: - - "packages/bridge-ui/**" tags: - "bridge-ui-v*" + pull_request: + paths: + - "packages/bridge-ui/**" jobs: build-and-test: diff --git a/.github/workflows/eventindexer.yml b/.github/workflows/eventindexer.yml index aa1a89f9904..5f947171e48 100644 --- a/.github/workflows/eventindexer.yml +++ b/.github/workflows/eventindexer.yml @@ -3,6 +3,9 @@ name: Eventindexer on: push: branches: [main] + paths: + - "packages/eventindexer/**" + pull_request: paths: - "packages/eventindexer/**" - "go.mod" diff --git a/.github/workflows/guardian-prover-health-check-ui.yml b/.github/workflows/guardian-prover-health-check-ui.yml index 42bc780874a..743b30527da 100644 --- a/.github/workflows/guardian-prover-health-check-ui.yml +++ b/.github/workflows/guardian-prover-health-check-ui.yml @@ -2,8 +2,9 @@ name: Guardians UI CI/CD on: push: - branches-ignore: - - release-please-* + tags: + - "bridge-ui-v*" + pull_request: paths: - "packages/guardian-prover-health-check-ui/**" @@ -37,7 +38,7 @@ jobs: vercel_token: ${{ secrets.VERCEL_TOKEN }} deploy_guardians-ui_hekla_production: - if: ${{ github.ref_name == 'main' && contains(github.ref, 'refs/tags/guardians-ui-') }} + if: ${{ startsWith(github.ref, 'refs/tags/guardians-ui-v') }} needs: build-and-test uses: ./.github/workflows/repo--vercel-deploy.yml with: diff --git a/.github/workflows/guardian-prover-health-check.yml b/.github/workflows/guardian-prover-health-check.yml index eb9f7cf6f23..6bbe33e603a 100644 --- a/.github/workflows/guardian-prover-health-check.yml +++ b/.github/workflows/guardian-prover-health-check.yml @@ -3,6 +3,9 @@ name: Guardians Health Check on: push: branches: [main] + paths: + - "packages/guardian-prover-health-check/**" + pull_request: paths: - "packages/guardian-prover-health-check/**" - "go.mod" diff --git a/.github/workflows/relayer.yml b/.github/workflows/relayer.yml index 5185322a742..e8f334219f9 100644 --- a/.github/workflows/relayer.yml +++ b/.github/workflows/relayer.yml @@ -3,6 +3,9 @@ name: Relayer on: push: branches: [main] + paths: + - "packages/relayer/**" + pull_request: paths: - "packages/relayer/**" - "go.mod" diff --git a/.github/workflows/snaefell-ui.yml b/.github/workflows/snaefell-ui.yml index 16b2316f25d..ab659c53353 100644 --- a/.github/workflows/snaefell-ui.yml +++ b/.github/workflows/snaefell-ui.yml @@ -2,10 +2,8 @@ name: Snaefell UI CI/CD on: push: - branches-ignore: - - release-please-* - paths: - - "packages/snaefell-ui/**" + tags: + - "snaefull-ui-v*" pull_request: paths: - "packages/snaefell-ui/**" @@ -28,7 +26,7 @@ jobs: vercel_token: ${{ secrets.VERCEL_TOKEN }} deploy_snaefell-ui_mainnet_production: - if: ${{ github.ref_name == 'main' && contains(github.ref, 'refs/tags/snaefell-ui-') }} + if: ${{ startsWith(github.ref, 'refs/tags/snaefull-ui-v') }} needs: build-and-test uses: ./.github/workflows/repo--vercel-deploy.yml with: diff --git a/.github/workflows/taiko-client--test.yml b/.github/workflows/taiko-client--test.yml index 3560261a511..44664f18a40 100644 --- a/.github/workflows/taiko-client--test.yml +++ b/.github/workflows/taiko-client--test.yml @@ -3,6 +3,9 @@ name: "CI" on: push: branches: [main] + paths: + - "packages/taiko-client/**" + pull_request: paths: - "packages/taiko-client/**" - "go.mod" diff --git a/.github/workflows/taikoon-ui.yml b/.github/workflows/taikoon-ui.yml index 685d3a96d77..c62bccee488 100644 --- a/.github/workflows/taikoon-ui.yml +++ b/.github/workflows/taikoon-ui.yml @@ -2,8 +2,9 @@ name: Taikoon UI CI/CD on: push: - branches-ignore: - - release-please-* + tags: + - "taikoon-ui-v*" + pull_request: paths: - "packages/taikoon-ui/**" @@ -25,7 +26,7 @@ jobs: vercel_token: ${{ secrets.VERCEL_TOKEN }} deploy_taikoon-ui_mainnet_production: - if: ${{ github.ref_name == 'main' && contains(github.ref, 'refs/tags/taikoon-ui-') }} + if: ${{ startsWith(github.ref, 'refs/tags/taikoon-ui-v') }} needs: build-and-test uses: ./.github/workflows/repo--vercel-deploy.yml with: