From a37317de392ccabf5995baa47be0c84daaea083c Mon Sep 17 00:00:00 2001 From: Maciej Skrzypkowski Date: Fri, 24 Jan 2025 13:35:16 +0100 Subject: [PATCH] Taiko alethia client 0.43.1 (#15) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * docs(protocol): update `tier_router` in hekla (#18352) * build(deps): bump github.com/prometheus/client_golang from 1.20.4 to 1.20.5 (#18266) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): bump gorm.io/datatypes from 1.2.1 to 1.2.4 (#18265) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): bump github.com/morkid/paginate from 1.1.7 to 1.1.8 (#18264) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * feat(protocol): scripts to deploy new mainnet implementation contracts (#18356) Co-authored-by: Gavin Yu * chore(protocol): remove `TIER_ZKVM_ANY` in `MainnetTierRouter` (#18357) * ci(protocol): trigger patch release (1.10.1) (#18358) * chore(protocol): undo 1.10.0 release (#18363) * chore(protocol): deploy `MainnetTierRouter` and update `RollupAddressCache` (#18359) * ci(repo): trigger release-lease on tag changes (#18364) * chore(main): release protocol 1.10.0 (#18365) * chore(protocol): restore proving window changes (#18368) * feat(protocol): update `B_TIER_ROUTER` in `RollupAddressCache` (#18370) * docs(docs-site): update mainnet prover docs (#18367) * chore(protocol): optimize Taiko L1 gas cost (#18376) * refactor(protocol): remove unused code post Ontake fork (#18150) Co-authored-by: dantaik Co-authored-by: gavin Co-authored-by: David Co-authored-by: Bernat Canal Garceran Co-authored-by: taiko-bot <160625009+taiko-kitty@users.noreply.github.com> Co-authored-by: Roger <50648015+RogerLamTd@users.noreply.github.com> Co-authored-by: maskpp Co-authored-by: smtmfft <99081233+smtmfft@users.noreply.github.com> Co-authored-by: Ivan Lagunovsky Co-authored-by: jeff <113397187+cyberhorsey@users.noreply.github.com> Co-authored-by: Karim Co-authored-by: Karim <162329697+kimo-ice@users.noreply.github.com> Co-authored-by: YoGhurt111 * build(deps): bump github.com/swaggo/swag from 1.16.3 to 1.16.4 (#18372) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): bump github.com/urfave/cli/v2 from 2.27.4 to 2.27.5 (#18373) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): bump github.com/testcontainers/testcontainers-go from 0.30.0 to 0.34.0 (#18374) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * feat(taiko-client): client changes based on #18150 (#18350) * docs(protocol): update mainnet deployment docs (#18366) * feat(protocol): add `lastProposedIn` to slotB (#18379) * feat(protocol): allow any ERC20 tokens or Ether to be used as bonds (#18380) * feat(taiko-client): update Go contract bindings (#18381) * feat(taiko-client): update Go contract bindings (#18384) * ci(repo): improve workflow triggering conditions (#18385) * ci(protocol): release-please only crate draft PRs (#18392) * chore(protocol): change bond amounts, proving windows, and cooldown windows (#18371) * feat(protocol): increase risc0 frequency in Hekla (#18407) * ci(protocol): release-please creates draft PRs (#18423) * chore(taiko-client): update CI badge and path (#18441) * ci(repo): delete some workflows and release configs (#18440) * feat(docs-site): update network config, list cooldown, proving windows and bonds for every tier, remove banner (#18377) Co-authored-by: Daniel Wang <99078276+dantaik@users.noreply.github.com> * fix(protocol): fix debitBond bug and add additional tests (#18443) * feat(taiko-client): add chain ID to `TryDecompress()` (#18444) * refactor(protocol): slightly improve EssentialContract (#18445) * fix(protocol): revert `B_TIER_OPTIMISTIC` back to `""` (#18446) * feat(taiko-client): compatible changes for `lastProposedIn` (#18442) * ci(protocol): revert release-please workflow (#18447) * build(deps): bump github.com/golang-jwt/jwt/v4 from 4.5.0 to 4.5.1 in the go_modules group (#18448) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * chore(main): release docs-site 1.15.0 (#18428) * feat(taiko-client): revert pr 18442 (#18450) * docs(protocol): upgrade verifiers to support proof aggregation in Hekla (#18453) * feat(protocol): allow `local.params.parentMetaHash` to remain as 0 (#18451) * feat(docs-site): update graphic for hekla network config (#18457) * feat(repo): don't run workflows on release-please branches (#18459) * fix(repo): revert release-please (#18461) * refactor(protocol): extra a new function in LibProposing (#18456) * feat(taiko-client): update Go contract bindings (#18462) * chore(main): release docs-site 1.16.0 (#18458) Co-authored-by: Roger <50648015+RogerLamTd@users.noreply.github.com> * feat(protocol): update sp1 to 3.0.0 prod version (#18465) * feat(protocol): request zk proofs(risc0 & sp1) in mainnet (#18467) * feat(protocol): tolerate invalid BaseFeeConfig on L2 (#18338) Co-authored-by: dantaik Co-authored-by: gavin Co-authored-by: David Co-authored-by: Bernat Canal Garceran Co-authored-by: taiko-bot <160625009+taiko-kitty@users.noreply.github.com> Co-authored-by: Roger <50648015+RogerLamTd@users.noreply.github.com> Co-authored-by: maskpp Co-authored-by: smtmfft <99081233+smtmfft@users.noreply.github.com> Co-authored-by: Ivan Lagunovsky Co-authored-by: jeff <113397187+cyberhorsey@users.noreply.github.com> Co-authored-by: Karim Co-authored-by: Karim <162329697+kimo-ice@users.noreply.github.com> Co-authored-by: YoGhurt111 * docs(protocol): upgrade sp1 remote verifier in Hekla (#18469) * feat(relayer): confirmations before indexing for relayer should be configurable (#18466) * feat(docs-site): update testnet address (#18472) * feat(repo): fix workflows, restore merge-gatekeeper (#18471) * docs(protocol): add mainnet zkVM verifiers deployment (#18454) * feat(protocol): measure gas per block using a debug event (#18470) * feat(protocol): increase zk(risc0 & sp1) rate in mainnet (#18481) * test(protocol): check LibEIP1559 function results in fuzz tests (#18475) * chore(docs-site): update block-states.mdx (#18480) * fix(repo): ignore draft PRs merge-gatekeeper (#18488) * feat(docs-site): update tier config and graphic (#18487) * chore(main): release docs-site 1.17.0 (#18476) * chore(repo): improve documentation and changelog (#18489) * docs(protocol): add Ontake fork audit report from OpenZeppelin (#18491) * chore(protocol): fix typos in documentation files (#18490) * feat(eventindexer): eventindexer post ontake fork (#18474) * build(deps): bump github.com/buildkite/terminal-to-html/v3 from 3.8.0 to 3.16.3 (#18478) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): bump golang.org/x/sync from 0.8.0 to 0.9.0 (#18479) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): bump github.com/prysmaticlabs/prysm/v5 from 5.1.0 to 5.1.2 (#18477) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * docs(protocol): update mainnet deployment docs (#18482) * build(deps): bump github.com/go-resty/resty/v2 from 2.15.3 to 2.16.0 (#18492) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): bump github.com/buildkite/terminal-to-html/v3 from 3.16.3 to 3.16.4 (#18493) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * chore(docs-site): update tier router address (#18495) * chore(main): release docs-site 1.17.1 (#18496) * docs(balance-monitor): fix typo Update main.go (#18502) * docs(repo): improve grammar and readability (#18501) * feat(repo): add geth-rpc-gateway (#18382) * fix(relayer): temp fix if `txSender` is not available for `txIndex` when processing events (#18513) * build(deps): bump github.com/pressly/goose/v3 from 3.20.0 to 3.23.0 (#18509) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): bump github.com/go-resty/resty/v2 from 2.16.0 to 2.16.2 (#18510) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * ci(repo): change to trigger hive test manually (#18514) * refactor(taiko-client): move `utils` package from `internal/` to `pkg/` (#18516) * test(taiko-client): fix some lint issues for `taiko-client` (#18517) * ci(repo): update go mod and use random port (#18515) * test(taiko-client): skip `TestCheckL1ReorgToSameHeightFork` temporarily (#18522) * feat(docs-site): add software releases page that shows latest software releases and protocol deployments (#18523) * chore(main): release docs-site 1.18.0 (#18526) * feat(docs-site): add escenario and explanation for contestable rollup (#18530) * chore(main): release docs-site 1.19.0 (#18532) * feat(nfts): trailblazers "registerEvent" contract (#18198) * feat(nfts): trailblazers badges s2 (#18040) Co-authored-by: bearni95 * feat(taiko-client): enable proof aggregation (batch proofs) (#18163) Co-authored-by: David Co-authored-by: maskpp * feat(docs-site): add taiko-protocol section with economics and codebase analysis (#18542) Co-authored-by: RogerLamTd Co-authored-by: swarna1101 * chore(main): release docs-site 1.20.0 (#18550) * chore(docs-site): update hekla proof tier config graphic and address (#18554) * chore(docs-site): add goldsky to dev tools (#18552) * feat(protocol): decrease the rate of risc0 in Hekla (#18553) * fix(docs-site): correct graphic (#18561) * chore(main): release docs-site 1.20.1 (#18555) * fix(docs-site): link of goldsky in dev tools (#18562) * chore(main): release docs-site 1.20.2 (#18563) * fix(docs-site): update hekla graphic (#18572) * chore(main): release docs-site 1.20.3 (#18573) * feat(bridge-ui): remove fee padding (#18546) * feat(nfts): eventRegister contract update (#18547) * chore(main): fix misspelled (#18581) * chore(protocol): remove repetitive words in audit report (#18584) Signed-off-by: RiceChuan * ci(relayer): stop running CI actions when updating `go.mod` (#18591) * build(deps): bump github.com/labstack/echo/v4 from 4.12.0 to 4.13.2 (#18583) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: David * build(deps): bump golang.org/x/sync from 0.9.0 to 0.10.0 (#18560) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): bump github.com/stretchr/testify from 1.9.0 to 1.10.0 (#18539) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: David * feat(repo): don't run vercel workflow on fork (#18593) * feat(repo): disable docs-site preview run on fork (#18596) * chore(docs-site): fix broken link (#18585) Co-authored-by: Roger <50648015+RogerLamTd@users.noreply.github.com> * chore(docs-site): fix typos in node operator guides (#18586) Co-authored-by: Roger <50648015+RogerLamTd@users.noreply.github.com> * feat(bridge-ui): add curve (#18549) * feat(protocol): change HeklaTaikoToken's clock mode to timestamp to test the DAO (#18597) * docs(protocol): update Hekla deployments (#18598) * feat(protocol): introduce ForkManager to improve protocol fork management (#18508) Co-authored-by: dantaik Co-authored-by: David * fix(taiko-client): valid status check in `BatchGetBlocksProofStatus` (#18595) * fix(nft): fix s2 badges remigration (#18578) Co-authored-by: Korbinian Co-authored-by: Korbinian * feat(protocol): propose a batch blocks conditionally (#18570) Co-authored-by: YoGhurt111 * feat(taiko-client): make p2p-sync required (#18571) * chore(main): release bridge-ui 2.13.0 (#18430) * build(deps): bump codecov/codecov-action from 4 to 5 (#18543) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * feat(protocol): adjust the zk ratio(risc0 & sp1) (#18613) * feat(protocol): update `RollupAddressCache` with new `MainnetTierRouter` address (#18619) * chore(protocol): delete gas debug event (#18620) * chore(docs-site): update proof tier graphic (#18617) * build(deps): bump github.com/labstack/echo/v4 from 4.13.2 to 4.13.3 (#18623) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): bump github.com/pressly/goose/v3 from 3.23.0 to 3.24.0 (#18624) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): bump github.com/prysmaticlabs/prysm/v5 from 5.1.2 to 5.2.0 (#18625) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * feat(taiko-client): improve `ProofBuffer` (#18627) * chore(main): release taiko-client 0.40.0 (#18436) * ci(protocol): make the storage layout table clearer (#18633) Co-authored-by: dantaik * feat(docs-site): add doc for SGX Verifier. (#18579) * chore(main): release docs-site 1.21.0 (#18592) * docs(protocol): update mainnet deployment docs (#18621) * chore(repo): fix broken links (#18635) * chore(repo): improve license (#18634) * docs(repo): fix links to LICENSE file (#18641) * chore(main): release protocol 1.11.0 (#18433) Co-authored-by: Daniel Wang <99078276+dantaik@users.noreply.github.com> * docs(protocol): update mainnet deployment docs (#18645) * feat(taiko-client): catch raiko deserialization errors (#18644) * feat(taiko-client): optimize aggregation loggingain (#18643) * test(taiko-client): cleanup pre-ontake tests (#18647) * feat(taiko-client): revert pr-18571 (#18648) * ci(taiko-client): release client as `"taiko-alethia-client"` (#18651) * ci(protocol): improve check-links (#18652) * fix(repo): improve link checking (#18653) * ci(repo): fix release-please (#18654) Co-authored-by: Daniel Wang <99078276+dantaik@users.noreply.github.com> * docs(repo): update `README` (#18650) Co-authored-by: dionysuz <13951458+dionysuzx@users.noreply.github.com> * feat(protocol): make `TaikoL2Deprecated` ABI go-ethereum compatible (#18659) Co-authored-by: Daniel Wang * feat(taiko-client): introduce `TaikoL2.GetBasefeeV2` (#18660) Co-authored-by: Gavin Yu * ci(protocol): revert releasing protocol 1.11.0 (#18662) * chore(main): release taiko-alethia-protocol 1.11.0 (#18663) * fix(taiko-client): fix `GetBasefeeV2` usage (#18664) * build(deps): bump github.com/labstack/echo-contrib from 0.17.1 to 0.17.2 (#18666) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * build(deps): bump gorm.io/datatypes from 1.2.4 to 1.2.5 (#18665) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: David * feat(taiko-client): remove an unused package (#18668) * chore(taiko-client): improve `proofBuffer` logs (#18669) * chore(main): release taiko-alethia-client 0.41.0 (#18655) * ci(taiko-client): update docker image building configs (#18671) * chore(taiko-client): cleanup pre-ontake proposer code (#18672) * chore(main): release taiko-alethia-client 0.41.1 (#18673) * chore(taiko-client): optimize logging (#18674) * chore(taiko-client): cleanup pre-ontake prover code (#18677) * chore(taiko-client): remove some unused flags (#18678) * chore(docs-site): revert zk coverage docs (#18682) Co-authored-by: David * chore(repo): don't run docker build and push on forks (#18687) * feat(protocol): adjust zk(risc0 & sp1) ratio (#18684) * fix(protocol): add timestamp as a new parameter to getBasefeeV2 (#18686) Co-authored-by: Daniel Wang <99078276+dantaik@users.noreply.github.com> Co-authored-by: YoGhurt111 * fix(taiko-client): add #18442 back (#18685) * ci(protocol): revert "chore(main): release taiko-alethia-protocol 1.11.0 (#18663)" (#18688) * chore(taiko-client): fix typos in Swagger documentation for uptime endpoint (#18681) * fix(taiko-client): add timestamp as a new parameter to getBasefeeV2 (#18691) Co-authored-by: Daniel Wang <99078276+dantaik@users.noreply.github.com> * chore(guardian-prover-health-check): fix api doc (#18693) * fix(repo): fix some Go compiler errors (#18689) * chore(protocol): fix documentation (#18694) * feat(taiko-client): introduce `TxBuilderWithFallback` (#18690) * chore(relayer): fix docs (#18697) * chore(taiko-client): fix docs (#18698) * fix(repo): update versioning in version.go for client (#18700) * fix(taiko-client): fix proposing fee estimation (#18702) * chore(repo): workflows skip dependabot prs (#18701) * fix(taiko-client): fix blob transactions estimation when proposing (#18703) * fix(relayer): extra padding for contract messages, always pad non-contracts (#18699) * chore(main): release docs-site 1.21.1 (#18639) * test(taiko-client): add more fallback proposing tests (#18705) * chore(main): release taiko-alethia-protocol 1.11.0 (#18695) * build(deps): bump github.com/go-git/go-git/v5 from 5.12.0 to 5.13.1 (#18708) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * feat(taiko-client): build blob transactions when gas estimation failed (#18712) * feat(taiko-client): remove an unused flag for proposer (#18709) * chore(taiko-client): add more metrics for `TxBuilderWithFallback` (#18711) * chore(taiko-client): more cost estimation metrics (#18713) * chore(docs-site): update codebase analysis to reflect protocol changes (#18714) * chore(taiko-client): add more proof generation metrics (#18715) * chore(taiko-client): improve prover logs (#18718) * chore(main): release taiko-alethia-client 0.42.0 (#18676) * chore(taiko-client): always use `blockID` instead of `height` for L2 blocks in logs (#18719) * chore(eventindexer): rm ei generator (#18723) * ci(repo): standardize workflow naming (#18726) * ci(repo): update pnpm installer (#18725) * chore(repo): update dependabot config (#18722) * build(deps): bump the github-actions-updates group with 2 updates (#18728) Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * chore(taiko-client): improve proposer gas estimation (#18727) * chore(main): release taiko-alethia-client 0.42.1 (#18720) * feat(taiko-client): soft block driver APIs (#18273) Co-authored-by: RogerLamTd Co-authored-by: Roger <50648015+RogerLamTd@users.noreply.github.com> Co-authored-by: github-actions[bot] Co-authored-by: Daniel Wang <99078276+dantaik@users.noreply.github.com> Co-authored-by: maskpp Co-authored-by: Jeffery Walsh * chore(main): release docs-site 1.21.2 (#18716) * chore(taiko-client): bump `taiko-geth` dep (#18730) * chore(taiko-client): add softBlock server start log (#18731) * fix(taiko-client): fix pages workflow (#18734) * fix(taiko-client): remove `finalizedBlock` info when P2P syncing (#18735) * fix(taiko-client): revert `tracker.triggered` related changes (#18737) * chore(taiko-client): improve `TxBuilderWithFallback` logs (#18738) * fix(taiko-client): check the `blockID` of the last verified block before using it as `FinalizedBlockHash` (#18739) * feat(taiko-client): only check and trigger P2P sync progress right after starting (#18745) * feat(taiko-client): remove soft blocks implementation (#18744) * chore(docs-site): update verifier addresses (#18749) * chore(taiko-client): cleanup some unused variables in `bindings` package (#18752) * feat(protocol): upgrade sp1 contract to v4.0.0-rc.3 (#18740) Co-authored-by: smtmfft * chore(docs-site): update mainnet verifier addresses (#18756) * chore(docs-site): update mainnet config graphic (#18758) * chore(main): release docs-site 1.21.3 (#18750) * fix(taiko-client): check inner iterator errors in `BlockProposedIterator` (#18757) * docs(protocol): update mainnet deployment docs (#18754) * ci(protocol): revert "chore(main): release taiko-alethia-protocol 1.11.0 (#18695)" (#18760) * chore(main): release taiko-alethia-protocol 1.11.0 (#18761) * test(taiko-client): improve tests for blob sync (#18764) * chore(main): release taiko-alethia-client 0.43.0 (#18729) * chore(taiko-client): add more logs for `BlockProposedIterator` (#18772) * chore(taiko-client): more logs for `BlockBatchIterator` (#18774) * chore(taiko-client): ensure event block IDs are continuous (#18775) * chore(docs-site): update network config and add batch proof guide (#18776) * chore(taiko-client): rename `io.EOF` in iterators (#18777) * chore(taiko-client): make full sync to sync to the latest header (#18771) * chore(taiko-client): improve `BlobFetcher` (#18786) * chore(main): release taiko-alethia-client 0.43.1 (#18773) * fix(docs-site): omitted L1 HTTP endpoint from taiko client flags (#18798) * chore(docs-site): update documentation for upcoming hekla upgrade (#18810) * chore(main): release docs-site 1.21.4 (#18779) * feat(nfts): tbz s2 recruitments contract upgrade (#18556) * Printing version at the driver and proposer start * Potential fix for code scanning alert no. 4: Clear-text logging of sensitive information Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> * Fixed deploy protocol on l1 script --------- Signed-off-by: dependabot[bot] Signed-off-by: RiceChuan Co-authored-by: Gavin Yu Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: David Co-authored-by: Daniel Wang <99078276+dantaik@users.noreply.github.com> Co-authored-by: taiko-bot <160625009+taiko-kitty@users.noreply.github.com> Co-authored-by: Roger <50648015+RogerLamTd@users.noreply.github.com> Co-authored-by: dantaik Co-authored-by: Bernat Canal Garceran Co-authored-by: maskpp Co-authored-by: smtmfft <99081233+smtmfft@users.noreply.github.com> Co-authored-by: Ivan Lagunovsky Co-authored-by: jeff <113397187+cyberhorsey@users.noreply.github.com> Co-authored-by: Karim Co-authored-by: Karim <162329697+kimo-ice@users.noreply.github.com> Co-authored-by: YoGhurt111 Co-authored-by: AlexWu Co-authored-by: Dmitry <98899785+mdqst@users.noreply.github.com> Co-authored-by: Noisy <125606576+donatik27@users.noreply.github.com> Co-authored-by: leopardracer <136604165+leopardracer@users.noreply.github.com> Co-authored-by: Donny <130464015+defitricks@users.noreply.github.com> Co-authored-by: Hopium <135053852+Hopium21@users.noreply.github.com> Co-authored-by: xiaodino Co-authored-by: Korbinian Co-authored-by: bearni95 Co-authored-by: Jünger <98948000+0xjunger@users.noreply.github.com> Co-authored-by: RogerLamTd Co-authored-by: swarna1101 Co-authored-by: DikaCream Co-authored-by: RiceChuan Co-authored-by: futreall <86553580+futreall@users.noreply.github.com> Co-authored-by: Tristav <124001124+Pricstas@users.noreply.github.com> Co-authored-by: Korbinian Co-authored-by: dionysuz <13951458+dionysuzx@users.noreply.github.com> Co-authored-by: Daniel Wang Co-authored-by: FT <140458077+zeevick10@users.noreply.github.com> Co-authored-by: github-actions[bot] Co-authored-by: Jeffery Walsh Co-authored-by: smtmfft Co-authored-by: brachsterX Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com> --- .release-please-manifest.json | 4 +- go.mod | 7 +- go.sum | 11 +- packages/docs-site/CHANGELOG.md | 22 + packages/docs-site/package.json | 2 +- packages/docs-site/src/content/config.ts | 6 +- .../node-operators/deploy-a-proverset.mdx | 12 +- .../guides/node-operators/enable-a-prover.mdx | 34 +- .../node-operators/node-troubleshooting.mdx | 2 +- .../run-a-taiko-node-with-docker.mdx | 3 +- .../network-reference/mainnet-addresses.md | 2 + .../network-configuration.mdx | 14 +- .../network-reference/testnet-addresses.md | 4 +- .../content/docs/taiko-protocol/bridging.md | 4 +- packages/geth-rpc-gateway/main.go | 2 +- .../script/trailblazers-season-2/Deploy.s.sol | 9 +- .../UpgradeRecruitmentsV2.s.sol | 38 + .../script/layer1/DeployProtocolOnL1.s.sol | 2 +- packages/taiko-client/bindings/.githead | 2 +- .../taiko-client/bindings/encoding/input.go | 178 +--- .../taiko-client/bindings/encoding/struct.go | 17 +- packages/taiko-client/docs/docs.go | 378 ------- packages/taiko-client/docs/index.html | 29 - packages/taiko-client/docs/swagger.json | 335 ------- packages/taiko-client/docs/swagger.yaml | 266 ----- .../driver/chain_syncer/beaconsync/syncer.go | 37 +- .../driver/chain_syncer/blob/soft_block.go | 298 ------ .../driver/chain_syncer/blob/syncer.go | 4 +- .../driver/chain_syncer/blob/syncer_test.go | 96 ++ .../driver/chain_syncer/chain_syncer.go | 68 +- packages/taiko-client/driver/config.go | 45 +- packages/taiko-client/driver/driver.go | 39 +- packages/taiko-client/driver/driver_test.go | 354 ------- .../taiko-client/driver/soft_blocks/api.go | 306 ------ .../taiko-client/driver/soft_blocks/server.go | 130 --- .../driver/soft_blocks/server_test.go | 36 - .../taiko-client/driver/state/l1_current.go | 13 +- .../driver/txlist_fetcher/blob.go | 22 +- .../driver/txlist_fetcher/calldata.go | 4 + .../integration_test/hive_test.go | 1 - .../internal/docker/nodes/docker-compose.yml | 2 +- .../taiko-client/internal/version/version.go | 2 +- packages/taiko-client/package.json | 2 +- .../chain_iterator/block_batch_iterator.go | 30 +- .../block_batch_iterator_test.go | 3 +- .../event_iterator/block_proposed_iterator.go | 63 +- packages/taiko-client/pkg/rpc/methods.go | 52 +- packages/taiko-client/proposer/proposer.go | 3 + pnpm-lock.yaml | 920 +++++++++++++----- 49 files changed, 1063 insertions(+), 2850 deletions(-) create mode 100644 packages/nfts/script/trailblazers-season-2/UpgradeRecruitmentsV2.s.sol delete mode 100644 packages/taiko-client/docs/docs.go delete mode 100644 packages/taiko-client/docs/index.html delete mode 100644 packages/taiko-client/docs/swagger.json delete mode 100644 packages/taiko-client/docs/swagger.yaml delete mode 100644 packages/taiko-client/driver/chain_syncer/blob/soft_block.go delete mode 100644 packages/taiko-client/driver/soft_blocks/api.go delete mode 100644 packages/taiko-client/driver/soft_blocks/server.go delete mode 100644 packages/taiko-client/driver/soft_blocks/server_test.go diff --git a/.release-please-manifest.json b/.release-please-manifest.json index f9eeba087e8..4e11edde4ed 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,6 +1,6 @@ { "packages/bridge-ui": "2.13.0", - "packages/docs-site": "1.21.2", + "packages/docs-site": "1.21.4", "packages/eventindexer": "0.13.0", "packages/fork-diff": "0.6.1", "packages/guardian-prover-health-check": "0.1.0", @@ -9,7 +9,7 @@ "packages/relayer": "0.12.0", "packages/snaefell-ui": "1.1.0", "packages/supplementary-contracts": "1.0.0", - "packages/taiko-client": "0.42.1", + "packages/taiko-client": "0.43.1", "packages/taikoon-ui": "1.3.0", "packages/ui-lib": "1.0.0" } diff --git a/go.mod b/go.mod index 5c4e824bc8e..11a09317fbf 100644 --- a/go.mod +++ b/go.mod @@ -11,7 +11,6 @@ require ( github.com/cyberhorsey/webutils v0.0.0-20230314183728-56890c6ddbe7 github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc github.com/decred/dcrd/dcrec/secp256k1/v4 v4.3.0 - github.com/dgraph-io/badger/v4 v4.2.0 github.com/ethereum-optimism/optimism v1.7.4 github.com/ethereum/go-ethereum v1.14.11 github.com/ethereum/hive v0.0.0-20240822135954-91829ccfb2c5 @@ -22,9 +21,7 @@ require ( github.com/gorilla/rpc v1.2.1 github.com/gorilla/websocket v1.5.3 github.com/joho/godotenv v1.5.1 - github.com/labstack/echo-jwt/v4 v4.3.0 github.com/labstack/echo-contrib v0.17.2 - github.com/labstack/echo-jwt/v4 v4.3.0 github.com/labstack/echo/v4 v4.13.3 github.com/labstack/gommon v0.4.2 github.com/modern-go/reflect2 v1.0.2 @@ -117,10 +114,8 @@ require ( github.com/gofrs/flock v0.8.1 // indirect github.com/gogo/protobuf v1.3.2 // indirect github.com/golang-jwt/jwt/v4 v4.5.1 // indirect - github.com/golang-jwt/jwt/v5 v5.2.1 // indirect github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da // indirect github.com/golang/snappy v0.0.5-0.20220116011046-fa5810519dcb // indirect - github.com/google/flatbuffers v1.12.1 // indirect github.com/google/go-cmp v0.6.0 // indirect github.com/google/gofuzz v1.2.1-0.20220503160820-4a35382e8fc8 // indirect github.com/gorilla/css v1.0.0 // indirect @@ -238,7 +233,7 @@ require ( sigs.k8s.io/yaml v1.3.0 // indirect ) -replace github.com/ethereum/go-ethereum v1.14.11 => github.com/taikoxyz/taiko-geth v1.11.2-0.20250107082544-a2cbf904eaae +replace github.com/ethereum/go-ethereum v1.14.11 => github.com/taikoxyz/taiko-geth v1.11.1 replace github.com/ethereum-optimism/optimism v1.7.4 => github.com/taikoxyz/optimism v0.0.0-20241003061504-cdf8af288f39 diff --git a/go.sum b/go.sum index 80587bed24e..edc048ccd66 100644 --- a/go.sum +++ b/go.sum @@ -146,7 +146,6 @@ github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.1/go.mod h1:hyedUtir6IdtD/7lIxGeC github.com/decred/dcrd/dcrec/secp256k1/v4 v4.3.0 h1:rpfIENRNNilwHwZeG5+P150SMrnNEcHYvcCuK6dPZSg= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.3.0/go.mod h1:v57UDF4pDQJcEfFUCRop3lJL149eHGSe9Jvczhzjo/0= github.com/decred/dcrd/lru v1.0.0/go.mod h1:mxKOwFd7lFjN2GZYsiz/ecgqR6kkYAl+0pz0tEMk218= -github.com/dgraph-io/badger/v4 v4.2.0/go.mod h1:qfCqhPoWDFJRx1gp5QwwyGo8xk1lbHUxvK9nK0OGAak= github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ= github.com/distribution/reference v0.6.0 h1:0IXCQ5g4/QMHHkarYzh5l+u8T3t73zM5QvfrDyIgxBk= github.com/distribution/reference v0.6.0/go.mod h1:BbU0aIcezP1/5jX/8MP0YiH4SdvB5Y4f/wlDRiLyi3E= @@ -248,8 +247,6 @@ github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69 github.com/golang-jwt/jwt/v4 v4.4.3/go.mod h1:m21LjoU+eqJr34lmDMbreY2eSTRJ1cv77w39/MY0Ch0= github.com/golang-jwt/jwt/v4 v4.5.1 h1:JdqV9zKUdtaa9gdPlywC3aeoEsR681PlKC+4F5gQgeo= github.com/golang-jwt/jwt/v4 v4.5.1/go.mod h1:m21LjoU+eqJr34lmDMbreY2eSTRJ1cv77w39/MY0Ch0= -github.com/golang-jwt/jwt/v5 v5.2.1 h1:OuVbFODueb089Lh128TAcimifWaLhJwVflnrgM17wHk= -github.com/golang-jwt/jwt/v5 v5.2.1/go.mod h1:pqrtFR0X4osieyHYxtmOUWsAWrfe1Q5UVIyoH402zdk= github.com/golang-sql/civil v0.0.0-20220223132316-b832511892a9 h1:au07oEsX2xN0ktxqI+Sida1w446QrXBRJ0nee3SNZlA= github.com/golang-sql/civil v0.0.0-20220223132316-b832511892a9/go.mod h1:8vg3r2VgvsThLBIFL93Qb5yWzgyZWhEmBwUJWevAkK0= github.com/golang-sql/sqlexp v0.1.0 h1:ZCD6MBpcuOVfGVqsEmY5/4FtYiKz6tSyUv9LPEDei6A= @@ -276,7 +273,6 @@ github.com/golang/snappy v0.0.5-0.20220116011046-fa5810519dcb h1:PBC98N2aIaM3XXi github.com/golang/snappy v0.0.5-0.20220116011046-fa5810519dcb/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= github.com/gomarkdown/markdown v0.0.0-20231222211730-1d6d20845b47 h1:k4Tw0nt6lwro3Uin8eqoET7MDA4JnT8YgbCjc/g5E3k= github.com/gomarkdown/markdown v0.0.0-20231222211730-1d6d20845b47/go.mod h1:JDGcbDT52eL4fju3sZ4TeHGsQwhG9nbDV21aMyhwPoA= -github.com/google/flatbuffers v1.12.1/go.mod h1:1AeVuKshWv4vARoZatz6mlQ0JxURH0Kv5+zNeJKJCa8= github.com/google/gnostic-models v0.6.8 h1:yo/ABAfM5IMRsS1VnXjTBvUb61tFIHozhlYvRgGre9I= github.com/google/gnostic-models v0.6.8/go.mod h1:5n7qKqH0f5wFt+aWF8CW6pZLLNOfYuF5OpfBSENuI8U= github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M= @@ -381,8 +377,6 @@ github.com/kylelemons/godebug v1.1.0 h1:RPNrshWIDI6G2gRW9EHilWtl7Z6Sb1BR0xunSBf0 github.com/kylelemons/godebug v1.1.0/go.mod h1:9/0rRGxNHcop5bhtWyNeEfOS8JIWk580+fNqagV/RAw= github.com/labstack/echo-contrib v0.17.2 h1:K1zivqmtcC70X9VdBFdLomjPDEVHlrcAObqmuFj1c6w= github.com/labstack/echo-contrib v0.17.2/go.mod h1:NeDh3PX7j/u+jR4iuDt1zHmWZSCz9c/p9mxXcDpyS8E= -github.com/labstack/echo-jwt/v4 v4.3.0 h1:8JcvVCrK9dRkPx/aWY3ZempZLO336Bebh4oAtBcxAv4= -github.com/labstack/echo-jwt/v4 v4.3.0/go.mod h1:OlWm3wqfnq3Ma8DLmmH7GiEAz2S7Bj23im2iPMEAR+Q= github.com/labstack/echo/v4 v4.0.0/go.mod h1:tZv7nai5buKSg5h/8E6zz4LsD/Dqh9/91Mvs7Z5Zyno= github.com/labstack/echo/v4 v4.1.15/go.mod h1:GWO5IBVzI371K8XJe50CSvHjQCafK6cw8R/moLhEU6o= github.com/labstack/echo/v4 v4.13.3 h1:pwhpCPrTl5qry5HRdM5FwdXnhXSLSY+WE+YQSeCaafY= @@ -607,8 +601,8 @@ github.com/taikoxyz/hive v0.0.0-20240827015317-405b241dd082 h1:ymZR+Y88LOnA8i3Ke github.com/taikoxyz/hive v0.0.0-20240827015317-405b241dd082/go.mod h1:RHnIu3EFehrWX3JhFAMQSXD5uz7l0xaNroTzXrap7EQ= github.com/taikoxyz/optimism v0.0.0-20241003061504-cdf8af288f39 h1:JssMxaDmORjQ9RPZNulVJhAD8zSPd6LZFq5wsr6Nwz8= github.com/taikoxyz/optimism v0.0.0-20241003061504-cdf8af288f39/go.mod h1:ym7scR7ZHvEmwx1DLGVDzFlAdR+uhP1+Z4XCiFuSD5s= -github.com/taikoxyz/taiko-geth v1.11.2-0.20250107082544-a2cbf904eaae h1:exc3MDRDbpNahMwIA+yGFLJb8Umtqs4JLOBpa8hh4Us= -github.com/taikoxyz/taiko-geth v1.11.2-0.20250107082544-a2cbf904eaae/go.mod h1:+l/fr42Mma+xBnhefL/+z11/hcmJ2egl+ScIVPjhc7E= +github.com/taikoxyz/taiko-geth v1.11.1 h1:pur1WP6YJkwKhLVeN3Zf7dOwbPq6tS88gYod6QKlJc4= +github.com/taikoxyz/taiko-geth v1.11.1/go.mod h1:+l/fr42Mma+xBnhefL/+z11/hcmJ2egl+ScIVPjhc7E= github.com/testcontainers/testcontainers-go v0.34.0 h1:5fbgF0vIN5u+nD3IWabQwRybuB4GY8G2HHgCkbMzMHo= github.com/testcontainers/testcontainers-go v0.34.0/go.mod h1:6P/kMkQe8yqPHfPWNulFGdFHTD8HB2vLq/231xY2iPQ= github.com/thomaso-mirodin/intmath v0.0.0-20160323211736-5dc6d854e46e h1:cR8/SYRgyQCt5cNCMniB/ZScMkhI9nk8U5C7SbISXjo= @@ -762,7 +756,6 @@ golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20220715151400-c0bba94af5f8/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220728004956-3c1f35247d10/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20221010170243-090e33056c14/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.1.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.5.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= diff --git a/packages/docs-site/CHANGELOG.md b/packages/docs-site/CHANGELOG.md index db1bac8ab3a..10c64e425c2 100644 --- a/packages/docs-site/CHANGELOG.md +++ b/packages/docs-site/CHANGELOG.md @@ -1,5 +1,27 @@ # Changelog +## [1.21.4](https://github.com/taikoxyz/taiko-mono/compare/docs-site-v1.21.3...docs-site-v1.21.4) (2025-01-21) + + +### Bug Fixes + +* **docs-site:** omitted L1 HTTP endpoint from taiko client flags ([#18798](https://github.com/taikoxyz/taiko-mono/issues/18798)) ([a3e08ff](https://github.com/taikoxyz/taiko-mono/commit/a3e08fffbb7c200a3671bff7b1b793ee31226595)) + + +### Chores + +* **docs-site:** update documentation for upcoming hekla upgrade ([#18810](https://github.com/taikoxyz/taiko-mono/issues/18810)) ([cc2010c](https://github.com/taikoxyz/taiko-mono/commit/cc2010cf356dce1b5b012cd3e7cc15e58c5ad126)) +* **docs-site:** update network config and add batch proof guide ([#18776](https://github.com/taikoxyz/taiko-mono/issues/18776)) ([8710cd8](https://github.com/taikoxyz/taiko-mono/commit/8710cd866d407bca4eb977142d5e38786de94672)) + +## [1.21.3](https://github.com/taikoxyz/taiko-mono/compare/docs-site-v1.21.2...docs-site-v1.21.3) (2025-01-13) + + +### Chores + +* **docs-site:** update mainnet config graphic ([#18758](https://github.com/taikoxyz/taiko-mono/issues/18758)) ([b36576a](https://github.com/taikoxyz/taiko-mono/commit/b36576a367fbf3084aed3a9334821f7893d9c270)) +* **docs-site:** update mainnet verifier addresses ([#18756](https://github.com/taikoxyz/taiko-mono/issues/18756)) ([eaa47bd](https://github.com/taikoxyz/taiko-mono/commit/eaa47bd2c82a4678e0e1b65c076693b4b3015c26)) +* **docs-site:** update verifier addresses ([#18749](https://github.com/taikoxyz/taiko-mono/issues/18749)) ([bd0cb95](https://github.com/taikoxyz/taiko-mono/commit/bd0cb95c054075b32bf571d7c89a4768d370cb59)) + ## [1.21.2](https://github.com/taikoxyz/taiko-mono/compare/docs-site-v1.21.1...docs-site-v1.21.2) (2025-01-07) diff --git a/packages/docs-site/package.json b/packages/docs-site/package.json index 511b09a51c3..453d648a5ff 100644 --- a/packages/docs-site/package.json +++ b/packages/docs-site/package.json @@ -1,7 +1,7 @@ { "name": "docs-site", "type": "module", - "version": "1.21.2", + "version": "1.21.4", "scripts": { "dev": "astro dev", "start": "astro dev", diff --git a/packages/docs-site/src/content/config.ts b/packages/docs-site/src/content/config.ts index 96cdce61ff5..3b3aa138f81 100644 --- a/packages/docs-site/src/content/config.ts +++ b/packages/docs-site/src/content/config.ts @@ -8,9 +8,9 @@ export const collections = { description: z .string() .max(160, { message: "Must be 160 characters or less." }).optional(), - // banner: z.object({ content: z.string() }).default({ - // content: '', - // }), + banner: z.object({ content: z.string() }).default({ + content: 'All Hekla Node Runners: Protocol upgrade on Feb 1st, upgrade needed. Please ensure your nodes are using the software tags listed in the announcement! Click here for more info', + }), }), }), }), diff --git a/packages/docs-site/src/content/docs/guides/node-operators/deploy-a-proverset.mdx b/packages/docs-site/src/content/docs/guides/node-operators/deploy-a-proverset.mdx index dabf6a58b97..768917022eb 100644 --- a/packages/docs-site/src/content/docs/guides/node-operators/deploy-a-proverset.mdx +++ b/packages/docs-site/src/content/docs/guides/node-operators/deploy-a-proverset.mdx @@ -25,7 +25,7 @@ This guide outlines how to achieve this with separate EOAs running prover and pr 1. **Clone the Taiko monorepo** - The [Taiko monorepo](https://github.com/taikoxyz/taiko-mono) contains the scripts for deploying your `ProverSet`. Checkout the latest stable release. (Use `protocol-v1.9.0` for Hekla!) + The [Taiko monorepo](https://github.com/taikoxyz/taiko-mono) contains the scripts for deploying your `ProverSet`. Checkout the latest stable release. (Use `taiko-alethia-protocol-v1.11.0` for Hekla!) @@ -56,10 +56,6 @@ This guide outlines how to achieve this with separate EOAs running prover and pr ROLLUP_ADDRESS_MANAGER={ADDRESS} PROVER_SET_ADMIN={ADDRESS} forge script --chain-id {CHAIN_ID} --rpc-url {YOUR_RPC_URL} --private-key {PRIVATE_KEY} --broadcast script/DeployProverSet.s.sol:DeployProverSet ``` - - The script should print your implementation and proxy address with the log: ``` @@ -93,7 +89,7 @@ This guide outlines how to achieve this with separate EOAs running prover and pr 5. **Configure the contract as necessary** - Manage the contract's allowance with [approveAllowance()](https://github.com/taikoxyz/taiko-mono/blob/protocol-v1.9.0/packages/protocol/contracts/layer1/provers/ProverSet.sol#L64). TaikoL1's contract allowance is by default set to `UINT256.MAX` in the init function. + Manage the contract's allowance with [approveAllowance()](https://github.com/taikoxyz/taiko-mono/blob/taiko-alethia-protocol-v1.11.0/packages/protocol/contracts/layer1/provers/ProverSet.sol#L68). TaikoL1's contract allowance is by default set to `UINT256.MAX` in the init function. 6. **Deposit your tokens and run your proposer + prover as usual!** @@ -106,7 +102,7 @@ This guide outlines how to achieve this with separate EOAs running prover and pr Ensure that you have set up the EOAs correctly to avoid problems. @@ -164,7 +160,7 @@ If you've already deployed a ProverSet but would like to upgrade it through the If you've managed to propose and prove some blocks, it's likely you're wondering where your tokens went after. - It's not missing, it's just been deposited as bond in the TaikoL1 contract; you can withdraw it to the ProverSet contract with [withdrawBond()](https://github.com/taikoxyz/taiko-mono/blob/protocol-v1.9.0/packages/protocol/contracts/layer1/provers/ProverSet.sol#L136) manually. + It's not missing, it's just been deposited as bond in the TaikoL1 contract; you can withdraw it to the ProverSet contract with [withdrawBond()](https://github.com/taikoxyz/taiko-mono/blob/taiko-alethia-protocol-v1.11.0/packages/protocol/contracts/layer1/provers/ProverSet.sol#L151) manually. ### How do I verify my ProverSet contract? diff --git a/packages/docs-site/src/content/docs/guides/node-operators/enable-a-prover.mdx b/packages/docs-site/src/content/docs/guides/node-operators/enable-a-prover.mdx index 1a5569f047d..c82e67b1950 100644 --- a/packages/docs-site/src/content/docs/guides/node-operators/enable-a-prover.mdx +++ b/packages/docs-site/src/content/docs/guides/node-operators/enable-a-prover.mdx @@ -34,12 +34,40 @@ These are the bare minimum required settings along with a functional Taiko node +Please find all relevant bond, cooldown, and proving window information [here](/network-reference/network-configuration/#cooldown-window-proving-window-and-bonds). + +## Enabling batch proving/proof aggregation (optional) + + + +Batch proving has been enabled in release 0.43.1 of [the taiko alethia client!](https://github.com/taikoxyz/taiko-mono/releases/tag/taiko-alethia-client-v0.43.1) + +Please use [simple-taiko-node release 1.9.0](https://github.com/taikoxyz/simple-taiko-node/releases/tag/v1.9.0) or above to enable this functionality. + +**This functionality can be enabled simply by setting `SGX_BATCH_SIZE` in your `.env` file to a number greater than 1.** + +If it is set to 1 or unset your prover will submit proofs upon assignment (standard function). +When enabled, your prover will submit a batch of proofs when x number of blocks are assigned, x being `SGX_BATCH_SIZE`. + +As provers are given a proof window for every assigned proof, it can become the case that while waiting for a batch size to be fulfilled the already assigned proofs exit their proof window and become unassigned. +To prevent this, we have introduced another flag `FORCE_BATCH_PROVING_INTERVAL`. This flag will only be functional if batch proving is enabled. + +This flag will force the prover to submit a batch of proofs every x minutes, regardless of the batch size being fulfilled. We don't recommend this value be set > 45 minutes, as the provingWindow is 60 minutes and any closer will put you at risk of having proof assignments expire. It is by default set to 30 minutes. + -Please find all relevant bond, cooldown, and proving window information [here](/network-reference/network-configuration/#cooldown-window-proving-window-and-bonds). - ### Approve TaikoL1 as TAIKO spender (mainnet) @@ -56,7 +84,7 @@ Please find all relevant bond, cooldown, and proving window information [here](/ Please verify [contract addresses](/network-reference/mainnet-addresses) are correct before moving forward. You can check the respective ENS domains on Etherscan. -4. Set the amount to at least the minimum bond amount of 125 TAIKO. +4. Set the amount to at least the minimum bond amount of 150 TAIKO. You will need 150 TAIKO for each bond you sign. After entering 150, you need to set the 18 decimals that the TAIKO contract takes, you can click the plus button and then select 10^18. diff --git a/packages/docs-site/src/content/docs/guides/node-operators/node-troubleshooting.mdx b/packages/docs-site/src/content/docs/guides/node-operators/node-troubleshooting.mdx index 6fca6e1e496..e5336482018 100644 --- a/packages/docs-site/src/content/docs/guides/node-operators/node-troubleshooting.mdx +++ b/packages/docs-site/src/content/docs/guides/node-operators/node-troubleshooting.mdx @@ -35,7 +35,7 @@ This error can occur if there are issues with your L1 node, such as it being out ### Block batch iterator callback error error="failed to decode tx list: beacon client not found" -Potential Solution #1: Set L1_BEACON_HTPP in .env file and restart your node. +Potential Solution #1: Set L1_BEACON_HTTP in .env file and restart your node. Potential Solution #2: It's possible that the endpoint either lacks WebSocket (ws) support or is malformed. To address this error, ensure the following: - Your L1 node is operating correctly. diff --git a/packages/docs-site/src/content/docs/guides/node-operators/run-a-taiko-node-with-docker.mdx b/packages/docs-site/src/content/docs/guides/node-operators/run-a-taiko-node-with-docker.mdx index 72ca9aa2120..5fb875ddd17 100644 --- a/packages/docs-site/src/content/docs/guides/node-operators/run-a-taiko-node-with-docker.mdx +++ b/packages/docs-site/src/content/docs/guides/node-operators/run-a-taiko-node-with-docker.mdx @@ -75,14 +75,13 @@ This guide will help you start up a Taiko RPC node using [simple-taiko-node](htt For Mainnet, the L1 Node will need to be an Ethereum node; for Testnet, the L1 Node will need to be an Etherem testnet (Holesky) node. - Next, you will set the L1 node endpoints. If you are running a local L1 node, you cannot reference the L1 endpoints as `http://127.0.0.1:8545`, `ws://127.0.0.1:8546` and `http://127.0.0.1:5052` because that is local to inside the simple-taiko-node Docker networking. Instead you can try: + Next, you will set the L1 node endpoints. If you are running a local L1 node, you cannot reference the L1 endpoints as `ws://127.0.0.1:8546` and `http://127.0.0.1:5052` because that is local to inside the simple-taiko-node Docker networking. Instead you can try: - Using `host.docker.internal` (see: [stack overflow](https://stackoverflow.com/questions/24319662)). - Using the private ip address of your machine (use something like `ip addr show` to get this ip address). After getting the address of the L1 node, set the following L1 node endpoints in your `.env` file. Here is an example: - - `L1_ENDPOINT_HTTP=http://192.168.1.15:8545` - `L1_ENDPOINT_WS=ws://192.168.1.15:8546` - `L1_BEACON_HTTP=http://192.168.1.15:5052` diff --git a/packages/docs-site/src/content/docs/network-reference/mainnet-addresses.md b/packages/docs-site/src/content/docs/network-reference/mainnet-addresses.md index e98c0898edd..3f36fa9ce28 100644 --- a/packages/docs-site/src/content/docs/network-reference/mainnet-addresses.md +++ b/packages/docs-site/src/content/docs/network-reference/mainnet-addresses.md @@ -29,6 +29,8 @@ description: Network reference page describing various important addresses on Ta | AssignmentHook | `0x537a2f0D3a5879b41BCb5A2afE2EA5c4961796F6` | N/A | | TierProvider | `0x4cffe56C947E26D07C14020499776DB3e9AE3a23` | N/A | | SgxVerifier | `0xb0f3186FC1963f774f52ff455DC86aEdD0b31F81` | N/A | +| Risc0Verifier | `0x55902b2D3DF2A65370A89C86Ae9dd71Ecd508edc` | N/A | +| SP1Verifier | `0x5c44f2239925b0d86d2BFEe539f19CD0A08Af452` | N/A | | AutomataDcapAttestation | `0x8d7C954960a36a7596d7eA4945dDf891967ca8A3` | N/A | | PemCertChainLib | `0x02772b7B3a5Bea0141C993Dbb8D0733C19F46169` | N/A | | P256Verifier | `0x11A9ebA17EbF92b40fcf9a640Ebbc47Db6fBeab0` | N/A | diff --git a/packages/docs-site/src/content/docs/network-reference/network-configuration.mdx b/packages/docs-site/src/content/docs/network-reference/network-configuration.mdx index e615b575524..230382748d4 100644 --- a/packages/docs-site/src/content/docs/network-reference/network-configuration.mdx +++ b/packages/docs-site/src/content/docs/network-reference/network-configuration.mdx @@ -13,7 +13,7 @@ The cooldown window describes how long after the proof has been provided that th The proving window describes how long a prover has to provide a proof for a block after they have been assigned the block (i.e. a block has been proposed with them as the assigned prover). -You can find all the corresponding values below in the [deployed TierProviderBase contract](https://etherscan.io/address/0x394E30d83d020469a1F8b16E89D7fD5FdB1935b0#code#F3#L1)! +You can find all the corresponding values below for Mainnet in the [deployed TierProviderBase contract](https://etherscan.io/address/0x394E30d83d020469a1F8b16E89D7fD5FdB1935b0#code#F3#L1)! | Tier | Cooldown Window | Proving Window | Bond | | ----------------- | --------------- | -------------- | --------- | @@ -24,6 +24,18 @@ You can find all the corresponding values below in the [deployed TierProviderBas | Guardian Minority | 240 minutes | 240 minutes | 225 TAIKO | | Guardian | 240 minutes | 240 minutes | 0 TAIKO | +You can find all the corresponding values below for Hekla in the [most recent protocol release](https://github.com/taikoxyz/taiko-mono/blob/taiko-alethia-protocol-v1.11.0/packages/protocol/contracts/layer1/tiers/TierProviderBase.sol) + +| Tier | Cooldown Window | Proving Window | Bond | +| ----------------- | --------------- | -------------- | --------- | +| Optimistic | 1440 minutes | 60 minutes | 75 TAIKO | +| SGX | 240 minutes | 60 minutes | 150 TAIKO | +| TDX | 240 minutes | 60 minutes | 150 TAIKO | +| ZK SP1 | 240 minutes | 120 minutes | 225 TAIKO | +| ZK R0 | 240 minutes | 120 minutes | 225 TAIKO | +| Guardian Minority | 240 minutes | 120 minutes | 300 TAIKO | +| Guardian | 480 minutes | 0 minutes | 0 TAIKO | + ## Tier configuration (Mainnet) You can view the full `MainnetTierRouter` tier configuration [here](https://etherscan.io/address/0x8a4c692F12d3a9750E744A4CE24a1d351bE52E66#code): diff --git a/packages/docs-site/src/content/docs/network-reference/testnet-addresses.md b/packages/docs-site/src/content/docs/network-reference/testnet-addresses.md index 6eaad487371..e0327129511 100644 --- a/packages/docs-site/src/content/docs/network-reference/testnet-addresses.md +++ b/packages/docs-site/src/content/docs/network-reference/testnet-addresses.md @@ -28,10 +28,10 @@ description: Network reference page describing various important addresses on Ta | TierProvider | `0x9AaBba3Ae6D4aC3F5487608Da81006454e7933d3` | | TierRouter | `0x98d4FaD098526c4582063FA588C5e96229270366` | | SgxVerifier | `0x532EFBf6D62720D0B2a2Bb9d11066E8588cAE6D9` | -| Groth16Verifier | `0x5fd84014c62D5ea28D4533D5B1B48Ca44e571057` | +| Groth16Verifier | `0x714FD0666B0cee87bFC29A029E2AE66f40F12cE5` | | Risc0Verifier | `0x4fEd801C5a876D4289e869cbEfA1E1A448b10714` | | SP1Verifier | `0xFbE49f777E0078b3Fa0bae6de4794c88d6EA6DDD` | -| PlonkVerifier | `0xfb2d02219D065eBF3Aa8d2D1a1C52b1868EE7384` | +| PlonkVerifier | `0x7110bd8909CFC4C31204BA8597882CBFa1F77dC9` | | AutomataDcapAttestation | `0xC6cD3878Fc56F2b2BaB0769C580fc230A95e1398` | | PemCertChainLib | `0x08d7865e7F534d743Aba5874A9AD04bcB223a92E` | | ProverSet | `0xD3f681bD6B49887A48cC9C9953720903967E9DC0` | diff --git a/packages/docs-site/src/content/docs/taiko-protocol/bridging.md b/packages/docs-site/src/content/docs/taiko-protocol/bridging.md index fe5926a6d67..e1229bdd854 100644 --- a/packages/docs-site/src/content/docs/taiko-protocol/bridging.md +++ b/packages/docs-site/src/content/docs/taiko-protocol/bridging.md @@ -22,10 +22,10 @@ Taiko deploys two smart contracts which store the hashes of the other chain: - TaikoL1 stores the L2 world state root on L1 (deployed on Ethereum) - TaikoL2 stores the L1 world state root on L2 (deployed on Taiko) -Every time an L2 block is created on Taiko, the world state root of the enclosing block on L1 is stored in the [TaikoL2](https://github.com/taikoxyz/taiko-mono/blob/protocol-v1.9.0/packages/protocol/contracts/layer2/based/TaikoL2.sol#L145) contract using the `anchor` transaction. To ensure validity, it is part of the (previously the zk circuits, now SGX and ZK) proof data submitted with each block, so no fake L1 world state root can be synchronized to L2." +Every time an L2 block is created on Taiko, the world state root of the enclosing block on L1 is stored in the [TaikoL2](https://github.com/taikoxyz/taiko-mono/blob/taiko-alethia-protocol-v1.11.0/packages/protocol/contracts/layer2/based/TaikoL2.sol#L155) contract using the `anchor` transaction. To ensure validity, it is part of the (previously the zk circuits, now SGX and ZK) proof data submitted with each block, so no fake L1 world state root can be synchronized to L2." The L2 world state root is stored in the TaikoL1 contract using the `syncChainData` function call in -[`LibVerifying`](https://github.com/taikoxyz/taiko-mono/blob/protocol-v1.9.0/packages/protocol/contracts/layer1/based/LibVerifying.sol#L179). +[`LibVerifying`](https://github.com/taikoxyz/taiko-mono/blob/taiko-alethia-protocol-v1.11.0/packages/protocol/contracts/layer1/based/LibVerifying.sol#L165). Taiko by default synchronizes the world state roots cross-chain with the above mechanism. diff --git a/packages/geth-rpc-gateway/main.go b/packages/geth-rpc-gateway/main.go index 3915d9ec7b9..7163f372974 100644 --- a/packages/geth-rpc-gateway/main.go +++ b/packages/geth-rpc-gateway/main.go @@ -164,7 +164,7 @@ func forwardRequest(w http.ResponseWriter, r *http.Request, targetURL *url.URL, // Copy headers from the original request, excluding Accept-Encoding for name, values := range r.Header { - log.Printf("proxy req name %s", name) + log.Printf("proxy req header name %s", name) if name == "Accept-Encoding" { continue } diff --git a/packages/nfts/script/trailblazers-season-2/Deploy.s.sol b/packages/nfts/script/trailblazers-season-2/Deploy.s.sol index 2775e877772..d92ce7dd670 100644 --- a/packages/nfts/script/trailblazers-season-2/Deploy.s.sol +++ b/packages/nfts/script/trailblazers-season-2/Deploy.s.sol @@ -22,11 +22,12 @@ contract DeployS2Script is Script { BadgeRecruitment recruitment; // Taiko Mainnet Values + /* //address owner = 0xf8ff2AF0DC1D5BA4811f22aCb02936A1529fd2Be; address claimMintSigner = 0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266; address recruitmentSigner = 0x9Fc8d56c7376f9b062FEe7E02BAdFA670d603248; string baseURI = - "https://taikonfts.4everland.link/ipfs/bafybeiatuzeeeznd3hi5qiulslxcjd22ebu45t4fra2jvi3smhocr2c66a"; + "https://taikonfts.4everland.link/ipfs/bafybeiatuzeeeznd3hi5qiulslxcjd22ebu45t4fra2jvi3smhocr2c66a"; IMinimalBlacklist blacklist = IMinimalBlacklist(0xfA5EA6f9A13532cd64e805996a941F101CCaAc9a); uint256 public MAX_INFLUENCES = 5; @@ -37,11 +38,10 @@ contract DeployS2Script is Script { uint256 public DEFAULT_CYCLE_DURATION = 7 days; uint256 public s1EndDate = 1_734_350_400; // Dec 16th 2024, noon UTC uint256 public S1_LOCK_DURATION = (s1EndDate - block.timestamp); - + */ // Hekla Testnet Values - /* string baseURI = - "https://taikonfts.4everland.link/ipfs/bafybeiatuzeeeznd3hi5qiulslxcjd22ebu45t4fra2jvi3smhocr2c66a"; + "https://taikonfts.4everland.link/ipfs/bafybeiatuzeeeznd3hi5qiulslxcjd22ebu45t4fra2jvi3smhocr2c66a"; IMinimalBlacklist blacklist = IMinimalBlacklist(0xe61E9034b5633977eC98E302b33e321e8140F105); address claimMintSigner = 0xf39Fd6e51aad88F6F4ce6aB8827279cffFb92266; @@ -54,7 +54,6 @@ contract DeployS2Script is Script { uint256 public MAX_INFLUENCES_DIVIDER = 100; uint256 public DEFAULT_CYCLE_DURATION = 7 days; uint256 public S1_LOCK_DURATION = 365 days; - */ address s1Contract = 0xa20a8856e00F5ad024a55A663F06DCc419FFc4d5; diff --git a/packages/nfts/script/trailblazers-season-2/UpgradeRecruitmentsV2.s.sol b/packages/nfts/script/trailblazers-season-2/UpgradeRecruitmentsV2.s.sol new file mode 100644 index 00000000000..0b9d9218d09 --- /dev/null +++ b/packages/nfts/script/trailblazers-season-2/UpgradeRecruitmentsV2.s.sol @@ -0,0 +1,38 @@ +// SPDX-License-Identifier: MIT +pragma solidity 0.8.24; + +import { UtilsScript } from "./Utils.s.sol"; +import { Script, console } from "forge-std/src/Script.sol"; +import { BadgeRecruitment } from "../../contracts/trailblazers-season-2/BadgeRecruitment.sol"; +import { BadgeRecruitmentV2 } from "../../contracts/trailblazers-season-2/BadgeRecruitmentV2.sol"; + +contract UpgradeRecruitmentsV2 is Script { + UtilsScript public utils; + string public jsonLocation; + uint256 public deployerPrivateKey; + + address recruitmentAddress = 0xa9Ceb04F3aF71fF123409d426A92BABb5124970C; + BadgeRecruitment public recruitmentV1; + BadgeRecruitmentV2 public recruitmentV2; + + function setUp() public { + utils = new UtilsScript(); + utils.setUp(); + + jsonLocation = utils.getContractJsonLocation(); + deployerPrivateKey = utils.getPrivateKey(); + } + + function run() public { + vm.startBroadcast(deployerPrivateKey); + recruitmentV1 = BadgeRecruitment(recruitmentAddress); + + recruitmentV1.upgradeToAndCall( + address(new BadgeRecruitmentV2()), abi.encodeCall(BadgeRecruitmentV2.version, ()) + ); + + recruitmentV2 = BadgeRecruitmentV2(address(recruitmentV1)); + + console.log("Upgraded BadgeRecruitmentV2 to:", address(recruitmentV2)); + } +} diff --git a/packages/protocol/script/layer1/DeployProtocolOnL1.s.sol b/packages/protocol/script/layer1/DeployProtocolOnL1.s.sol index 3f97218e85e..ca7145388cc 100644 --- a/packages/protocol/script/layer1/DeployProtocolOnL1.s.sol +++ b/packages/protocol/script/layer1/DeployProtocolOnL1.s.sol @@ -279,7 +279,7 @@ contract DeployProtocolOnL1 is DeployCapability { copyRegister(rollupAddressManager, _sharedAddressManager, "taiko_token"); copyRegister(rollupAddressManager, _sharedAddressManager, "bond_token"); copyRegister(rollupAddressManager, _sharedAddressManager, "signal_service"); - // copyRegister(rollupAddressManager, _sharedAddressManager, "bridge"); + copyRegister(rollupAddressManager, _sharedAddressManager, "bridge"); deployProxy({ name: "mainnet_taiko", diff --git a/packages/taiko-client/bindings/.githead b/packages/taiko-client/bindings/.githead index 98ef6c34a28..d91889261bc 100644 --- a/packages/taiko-client/bindings/.githead +++ b/packages/taiko-client/bindings/.githead @@ -1 +1 @@ -54d27a0c7ac9afb266a3a7deb19947d1ef0c78e7 +5f48e64192b753c2191d19044a7af350af30f8a6 diff --git a/packages/taiko-client/bindings/encoding/input.go b/packages/taiko-client/bindings/encoding/input.go index cf6aa6ab893..30bc4532e43 100644 --- a/packages/taiko-client/bindings/encoding/input.go +++ b/packages/taiko-client/bindings/encoding/input.go @@ -14,72 +14,6 @@ import ( // ABI arguments marshaling components. var ( - blockMetadataComponents = []abi.ArgumentMarshaling{ - { - Name: "l1Hash", - Type: "bytes32", - }, - { - Name: "difficulty", - Type: "bytes32", - }, - { - Name: "blobHash", - Type: "bytes32", - }, - { - Name: "extraData", - Type: "bytes32", - }, - { - Name: "depositsHash", - Type: "bytes32", - }, - { - Name: "coinbase", - Type: "address", - }, - { - Name: "id", - Type: "uint64", - }, - { - Name: "gasLimit", - Type: "uint32", - }, - { - Name: "timestamp", - Type: "uint64", - }, - { - Name: "l1Height", - Type: "uint64", - }, - { - Name: "minTier", - Type: "uint16", - }, - { - Name: "blobUsed", - Type: "bool", - }, - { - Name: "parentMetaHash", - Type: "bytes32", - }, - { - Name: "sender", - Type: "address", - }, - { - Name: "blobTxListOffset", - Type: "uint32", - }, - { - Name: "blobTxListLength", - Type: "uint32", - }, - } blockMetadataV2Components = []abi.ArgumentMarshaling{ { Name: "anchorBlockHash", @@ -212,62 +146,6 @@ var ( Type: "bytes", }, } - blockParamsComponents = []abi.ArgumentMarshaling{ - { - Name: "assignedProver", - Type: "address", - }, - { - Name: "coinbase", - Type: "address", - }, - { - Name: "extraData", - Type: "bytes32", - }, - { - Name: "parentMetaHash", - Type: "bytes32", - }, - { - Name: "hookCalls", - Type: "tuple[]", - Components: []abi.ArgumentMarshaling{ - { - Name: "hook", - Type: "address", - }, - { - Name: "data", - Type: "bytes", - }, - }, - }, - { - Name: "signature", - Type: "bytes", - }, - { - Name: "l1StateBlockNumber", - Type: "uint32", - }, - { - Name: "timestamp", - Type: "uint64", - }, - { - Name: "blobTxListOffset", - Type: "uint32", - }, - { - Name: "blobTxListLength", - Type: "uint32", - }, - { - Name: "blobIndex", - Type: "uint8", - }, - } blockParamsV2Components = []abi.ArgumentMarshaling{ { Name: "proposer", @@ -305,28 +183,17 @@ var ( ) var ( - blockParamsComponentsType, _ = abi.NewType("tuple", "TaikoData.BlockParams", blockParamsComponents) - blockParamsComponentsArgs = abi.Arguments{{Name: "TaikoData.BlockParams", Type: blockParamsComponentsType}} blockParamsV2ComponentsType, _ = abi.NewType("tuple", "TaikoData.BlockParamsV2", blockParamsV2Components) blockParamsV2ComponentsArgs = abi.Arguments{{Name: "TaikoData.BlockParamsV2", Type: blockParamsV2ComponentsType}} - blockMetadataComponentsType, _ = abi.NewType("tuple", "TaikoData.BlockMetadata", blockMetadataComponents) blockMetadataV2ComponentsType, _ = abi.NewType("tuple", "TaikoData.BlockMetadataV2", blockMetadataV2Components) transitionComponentsType, _ = abi.NewType("tuple", "TaikoData.Transition", transitionComponents) tierProofComponentsType, _ = abi.NewType("tuple", "TaikoData.TierProof", tierProofComponents) - proveBlockInputArgs = abi.Arguments{ - {Name: "TaikoData.BlockMetadata", Type: blockMetadataComponentsType}, - {Name: "TaikoData.Transition", Type: transitionComponentsType}, - {Name: "TaikoData.TierProof", Type: tierProofComponentsType}, - } - proveOntakeBlockInputArgs = abi.Arguments{ + proveOntakeBlockInputArgs = abi.Arguments{ {Name: "TaikoData.BlockMetadataV2", Type: blockMetadataV2ComponentsType}, {Name: "TaikoData.Transition", Type: transitionComponentsType}, {Name: "TaikoData.TierProof", Type: tierProofComponentsType}, } - stringType, _ = abi.NewType("string", "TAIKO_DIFFICULTY", nil) - uint64Type, _ = abi.NewType("uint64", "local.b.numBlocks", nil) - difficultyCalculationInputArgs = abi.Arguments{{Type: stringType}, {Type: uint64Type}} - proveBlocksInputArgs = abi.Arguments{ + proveBlocksInputArgs = abi.Arguments{ {Name: "TaikoData.BlockMetadata", Type: blockMetadataV2ComponentsType}, {Name: "TaikoData.Transition", Type: transitionComponentsType}, } @@ -413,15 +280,6 @@ func init() { } } -// EncodeBlockParams performs the solidity `abi.encode` for the given blockParams. -func EncodeBlockParams(params *BlockParams) ([]byte, error) { - b, err := blockParamsComponentsArgs.Pack(params) - if err != nil { - return nil, fmt.Errorf("failed to abi.encode block params, %w", err) - } - return b, nil -} - // EncodeBlockParamsOntake performs the solidity `abi.encode` for the given ontake blockParams. func EncodeBlockParamsOntake(params *BlockParamsV2) ([]byte, error) { b, err := blockParamsV2ComponentsArgs.Pack(params) @@ -441,37 +299,17 @@ func EncodeProveBlockInput( b []byte err error ) - if meta.IsOntakeBlock() { - if b, err = proveOntakeBlockInputArgs.Pack( - meta.(*metadata.TaikoDataBlockMetadataOntake).InnerMetadata(), - transition, - tierProof, - ); err != nil { - return nil, fmt.Errorf("failed to abi.encode TakoL1.proveBlock input after ontake fork, %w", err) - } - } else { - if b, err = proveBlockInputArgs.Pack( - meta.(*metadata.TaikoDataBlockMetadataLegacy).InnerMetadata(), - transition, - tierProof, - ); err != nil { - return nil, fmt.Errorf("failed to abi.encode TakoL1.proveBlock input, %w", err) - } + if b, err = proveOntakeBlockInputArgs.Pack( + meta.(*metadata.TaikoDataBlockMetadataOntake).InnerMetadata(), + transition, + tierProof, + ); err != nil { + return nil, fmt.Errorf("failed to abi.encode TakoL1.proveBlock input after ontake fork, %w", err) } return b, nil } -// EncodeDifficultCalcutionParams performs the solidity `abi.encode` for the -// `block.difficulty` hash payload. -func EncodeDifficultyCalcutionParams(numBlocks uint64) ([]byte, error) { - b, err := difficultyCalculationInputArgs.Pack("TAIKO_DIFFICULTY", numBlocks) - if err != nil { - return nil, fmt.Errorf("failed to abi.encode `block.difficulty` hash payload, %w", err) - } - return b, nil -} - // EncodeProveBlocksInput performs the solidity `abi.encode` for the given TaikoL1.proveBlocks input. func EncodeProveBlocksInput( metas []metadata.TaikoBlockMetaData, diff --git a/packages/taiko-client/bindings/encoding/struct.go b/packages/taiko-client/bindings/encoding/struct.go index 1997f2e3f84..0bb80b27d0f 100644 --- a/packages/taiko-client/bindings/encoding/struct.go +++ b/packages/taiko-client/bindings/encoding/struct.go @@ -30,17 +30,12 @@ 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 - L1StateBlockNumber uint32 - Timestamp uint64 - BlobTxListOffset uint32 - BlobTxListLength uint32 - BlobIndex uint8 + AssignedProver common.Address + Coinbase common.Address + ExtraData [32]byte + ParentMetaHash [32]byte + HookCalls []HookCall + Signature []byte } // BlockParamsV2 should be same with TaikoData.BlockParamsV2. diff --git a/packages/taiko-client/docs/docs.go b/packages/taiko-client/docs/docs.go deleted file mode 100644 index ca9a73974e5..00000000000 --- a/packages/taiko-client/docs/docs.go +++ /dev/null @@ -1,378 +0,0 @@ -// Package docs Code generated by swaggo/swag. DO NOT EDIT -package docs - -import "github.com/swaggo/swag" - -const docTemplate = `{ - "schemes": {{ marshal .Schemes }}, - "swagger": "2.0", - "info": { - "description": "{{escape .Description}}", - "title": "{{.Title}}", - "termsOfService": "http://swagger.io/terms/", - "contact": { - "name": "API Support", - "url": "https://community.taiko.xyz/", - "email": "info@taiko.xyz" - }, - "license": { - "name": "MIT", - "url": "https://github.com/taikoxyz/taiko-mono/blob/main/LICENSE.md" - }, - "version": "{{.Version}}" - }, - "host": "{{.Host}}", - "basePath": "{{.BasePath}}", - "paths": { - "/healthz": { - "get": { - "consumes": [ - "application/json" - ], - "produces": [ - "application/json" - ], - "summary": "Get current server health status", - "operationId": "health-check", - "responses": { - "200": { - "description": "OK", - "schema": { - "type": "string" - } - } - } - } - }, - "/softBlocks": { - "post": { - "description": "Insert a batch of transactions into a soft block for preconfirmation. If the batch is the\nfirst for a block, a new soft block will be created. Otherwise, the transactions will\nbe appended to the existing soft block. The API will fail if:\n1) the block is not soft\n2) block-level parameters are invalid or do not match the current soft block’s parameters\n3) the batch ID is not exactly 1 greater than the previous one\n4) the last batch of the block indicates no further transactions are allowed", - "consumes": [ - "application/json" - ], - "produces": [ - "application/json" - ], - "parameters": [ - { - "description": "soft block creation request body", - "name": "body", - "in": "body", - "required": true, - "schema": { - "$ref": "#/definitions/softblocks.BuildSoftBlockRequestBody" - } - } - ], - "responses": { - "200": { - "description": "OK", - "schema": { - "$ref": "#/definitions/softblocks.BuildSoftBlockResponseBody" - } - } - } - }, - "delete": { - "description": "Remove all soft blocks from the blockchain beyond the specified block height,\nensuring the latest block ID does not exceed the given height. This method will fail if\nthe block with an ID one greater than the specified height is not a soft block. If the\nspecified block height is greater than the latest soft block ID, the method will succeed\nwithout modifying the blockchain.", - "consumes": [ - "application/json" - ], - "produces": [ - "application/json" - ], - "parameters": [ - { - "description": "soft blocks removing request body", - "name": "body", - "in": "body", - "required": true, - "schema": { - "$ref": "#/definitions/softblocks.RemoveSoftBlocksRequestBody" - } - } - ], - "responses": { - "200": { - "description": "OK", - "schema": { - "$ref": "#/definitions/softblocks.RemoveSoftBlocksResponseBody" - } - } - } - } - } - }, - "definitions": { - "big.Int": { - "type": "object" - }, - "softblocks.BuildSoftBlockRequestBody": { - "type": "object", - "properties": { - "transactionBatch": { - "description": "@param transactionBatch TransactionBatch Transaction batch to be inserted into the soft block", - "allOf": [ - { - "$ref": "#/definitions/softblocks.TransactionBatch" - } - ] - } - } - }, - "softblocks.BuildSoftBlockResponseBody": { - "type": "object", - "properties": { - "blockHeader": { - "description": "@param blockHeader types.Header of the soft block", - "allOf": [ - { - "$ref": "#/definitions/types.Header" - } - ] - } - } - }, - "softblocks.RemoveSoftBlocksRequestBody": { - "type": "object", - "properties": { - "newLastBlockId": { - "description": "@param newLastBlockID uint64 New last block ID of the blockchain, it should\n@param not smaller than the canonical chain's highest block ID.", - "type": "integer" - } - } - }, - "softblocks.RemoveSoftBlocksResponseBody": { - "type": "object", - "properties": { - "headsRemoved": { - "description": "@param headsRemoved uint64 Number of soft heads removed", - "type": "integer" - }, - "lastBlockId": { - "description": "@param lastBlockID uint64 Current highest block ID of the blockchain (including soft blocks)", - "type": "integer" - }, - "lastProposedBlockID": { - "description": "@param lastProposedBlockID uint64 Highest block ID of the cnonical chain", - "type": "integer" - } - } - }, - "softblocks.SoftBlockParams": { - "type": "object", - "properties": { - "anchorBlockID": { - "description": "@param anchorBlockID uint64 ` + "`" + `_anchorBlockId` + "`" + ` parameter of the ` + "`" + `anchorV2` + "`" + ` transaction in soft block", - "type": "integer" - }, - "anchorStateRoot": { - "description": "@param anchorStateRoot string ` + "`" + `_anchorStateRoot` + "`" + ` parameter of the ` + "`" + `anchorV2` + "`" + ` transaction in soft block", - "type": "array", - "items": { - "type": "integer" - } - }, - "coinbase": { - "description": "@param coinbase string Coinbase of the soft block", - "type": "array", - "items": { - "type": "integer" - } - }, - "timestamp": { - "description": "@param timestamp uint64 Timestamp of the soft block", - "type": "integer" - } - } - }, - "softblocks.TransactionBatch": { - "type": "object", - "properties": { - "batchId": { - "description": "@param batchId uint64 ID of this transaction batch", - "type": "integer" - }, - "batchType": { - "description": "@param batchType TransactionBatchMarker Marker of the transaction batch,\n@param either ` + "`" + `end_of_block` + "`" + `, ` + "`" + `end_of_preconf` + "`" + ` or empty", - "allOf": [ - { - "$ref": "#/definitions/softblocks.TransactionBatchMarker" - } - ] - }, - "blockId": { - "description": "@param blockId uint64 Block ID of the soft block", - "type": "integer" - }, - "blockParams": { - "description": "@param blockParams SoftBlockParams Block parameters of the soft block", - "allOf": [ - { - "$ref": "#/definitions/softblocks.SoftBlockParams" - } - ] - }, - "signature": { - "description": "@param signature string Signature of this transaction batch", - "type": "string" - }, - "transactions": { - "description": "@param transactions string zlib compressed RLP encoded bytes of a transactions list", - "type": "array", - "items": { - "type": "integer" - } - } - } - }, - "softblocks.TransactionBatchMarker": { - "type": "string", - "enum": [ - "", - "endOfBlock", - "endOfPreconf" - ], - "x-enum-varnames": [ - "BatchMarkerEmpty", - "BatchMarkerEOB", - "BatchMarkerEOP" - ] - }, - "types.Header": { - "type": "object", - "properties": { - "baseFeePerGas": { - "description": "BaseFee was added by EIP-1559 and is ignored in legacy headers.", - "allOf": [ - { - "$ref": "#/definitions/big.Int" - } - ] - }, - "blobGasUsed": { - "description": "BlobGasUsed was added by EIP-4844 and is ignored in legacy headers.", - "type": "integer" - }, - "difficulty": { - "$ref": "#/definitions/big.Int" - }, - "excessBlobGas": { - "description": "ExcessBlobGas was added by EIP-4844 and is ignored in legacy headers.", - "type": "integer" - }, - "extraData": { - "type": "array", - "items": { - "type": "integer" - } - }, - "gasLimit": { - "type": "integer" - }, - "gasUsed": { - "type": "integer" - }, - "logsBloom": { - "type": "array", - "items": { - "type": "integer" - } - }, - "miner": { - "type": "array", - "items": { - "type": "integer" - } - }, - "mixHash": { - "type": "array", - "items": { - "type": "integer" - } - }, - "nonce": { - "type": "array", - "items": { - "type": "integer" - } - }, - "number": { - "$ref": "#/definitions/big.Int" - }, - "parentBeaconBlockRoot": { - "description": "ParentBeaconRoot was added by EIP-4788 and is ignored in legacy headers.", - "type": "array", - "items": { - "type": "integer" - } - }, - "parentHash": { - "type": "array", - "items": { - "type": "integer" - } - }, - "receiptsRoot": { - "type": "array", - "items": { - "type": "integer" - } - }, - "requestsRoot": { - "description": "RequestsHash was added by EIP-7685 and is ignored in legacy headers.", - "type": "array", - "items": { - "type": "integer" - } - }, - "sha3Uncles": { - "type": "array", - "items": { - "type": "integer" - } - }, - "stateRoot": { - "type": "array", - "items": { - "type": "integer" - } - }, - "timestamp": { - "type": "integer" - }, - "transactionsRoot": { - "type": "array", - "items": { - "type": "integer" - } - }, - "withdrawalsRoot": { - "description": "WithdrawalsHash was added by EIP-4895 and is ignored in legacy headers.", - "type": "array", - "items": { - "type": "integer" - } - } - } - } - } -}` - -// SwaggerInfo holds exported Swagger Info so clients can modify it -var SwaggerInfo = &swag.Spec{ - Version: "1.0", - Host: "", - BasePath: "", - Schemes: []string{}, - Title: "Taiko Soft Block Server API", - Description: "", - InfoInstanceName: "swagger", - SwaggerTemplate: docTemplate, - LeftDelim: "{{", - RightDelim: "}}", -} - -func init() { - swag.Register(SwaggerInfo.InstanceName(), SwaggerInfo) -} diff --git a/packages/taiko-client/docs/index.html b/packages/taiko-client/docs/index.html deleted file mode 100644 index fd6da6d8abf..00000000000 --- a/packages/taiko-client/docs/index.html +++ /dev/null @@ -1,29 +0,0 @@ - - - - - - Taiko Preconfirmation Server API - - -
- - - diff --git a/packages/taiko-client/docs/swagger.json b/packages/taiko-client/docs/swagger.json deleted file mode 100644 index 2e72737ed95..00000000000 --- a/packages/taiko-client/docs/swagger.json +++ /dev/null @@ -1,335 +0,0 @@ -{ - "swagger": "2.0", - "info": { - "title": "Taiko Soft Block Server API", - "termsOfService": "http://swagger.io/terms/", - "contact": { - "name": "API Support", - "url": "https://community.taiko.xyz/", - "email": "info@taiko.xyz" - }, - "license": { - "name": "MIT", - "url": "https://github.com/taikoxyz/taiko-mono/blob/main/LICENSE.md" - }, - "version": "1.0" - }, - "paths": { - "/healthz": { - "get": { - "consumes": ["application/json"], - "produces": ["application/json"], - "summary": "Get current server health status", - "operationId": "health-check", - "responses": { - "200": { - "description": "OK", - "schema": { - "type": "string" - } - } - } - } - }, - "/softBlocks": { - "post": { - "description": "Insert a batch of transactions into a soft block for preconfirmation. If the batch is the\nfirst for a block, a new soft block will be created. Otherwise, the transactions will\nbe appended to the existing soft block. The API will fail if:\n1) the block is not soft\n2) block-level parameters are invalid or do not match the current soft block’s parameters\n3) the batch ID is not exactly 1 greater than the previous one\n4) the last batch of the block indicates no further transactions are allowed", - "consumes": ["application/json"], - "produces": ["application/json"], - "parameters": [ - { - "description": "soft block creation request body", - "name": "body", - "in": "body", - "required": true, - "schema": { - "$ref": "#/definitions/softblocks.BuildSoftBlockRequestBody" - } - } - ], - "responses": { - "200": { - "description": "OK", - "schema": { - "$ref": "#/definitions/softblocks.BuildSoftBlockResponseBody" - } - } - } - }, - "delete": { - "description": "Remove all soft blocks from the blockchain beyond the specified block height,\nensuring the latest block ID does not exceed the given height. This method will fail if\nthe block with an ID one greater than the specified height is not a soft block. If the\nspecified block height is greater than the latest soft block ID, the method will succeed\nwithout modifying the blockchain.", - "consumes": ["application/json"], - "produces": ["application/json"], - "parameters": [ - { - "description": "soft blocks removing request body", - "name": "body", - "in": "body", - "required": true, - "schema": { - "$ref": "#/definitions/softblocks.RemoveSoftBlocksRequestBody" - } - } - ], - "responses": { - "200": { - "description": "OK", - "schema": { - "$ref": "#/definitions/softblocks.RemoveSoftBlocksResponseBody" - } - } - } - } - } - }, - "definitions": { - "big.Int": { - "type": "object" - }, - "softblocks.BuildSoftBlockRequestBody": { - "type": "object", - "properties": { - "transactionBatch": { - "description": "@param transactionBatch TransactionBatch Transaction batch to be inserted into the soft block", - "allOf": [ - { - "$ref": "#/definitions/softblocks.TransactionBatch" - } - ] - } - } - }, - "softblocks.BuildSoftBlockResponseBody": { - "type": "object", - "properties": { - "blockHeader": { - "description": "@param blockHeader types.Header of the soft block", - "allOf": [ - { - "$ref": "#/definitions/types.Header" - } - ] - } - } - }, - "softblocks.RemoveSoftBlocksRequestBody": { - "type": "object", - "properties": { - "newLastBlockId": { - "description": "@param newLastBlockID uint64 New last block ID of the blockchain, it should\n@param not smaller than the canonical chain's highest block ID.", - "type": "integer" - } - } - }, - "softblocks.RemoveSoftBlocksResponseBody": { - "type": "object", - "properties": { - "headsRemoved": { - "description": "@param headsRemoved uint64 Number of soft heads removed", - "type": "integer" - }, - "lastBlockId": { - "description": "@param lastBlockID uint64 Current highest block ID of the blockchain (including soft blocks)", - "type": "integer" - }, - "lastProposedBlockID": { - "description": "@param lastProposedBlockID uint64 Highest block ID of the cnonical chain", - "type": "integer" - } - } - }, - "softblocks.SoftBlockParams": { - "type": "object", - "properties": { - "anchorBlockID": { - "description": "@param anchorBlockID uint64 `_anchorBlockId` parameter of the `anchorV2` transaction in soft block", - "type": "integer" - }, - "anchorStateRoot": { - "description": "@param anchorStateRoot string `_anchorStateRoot` parameter of the `anchorV2` transaction in soft block", - "type": "array", - "items": { - "type": "integer" - } - }, - "coinbase": { - "description": "@param coinbase string Coinbase of the soft block", - "type": "array", - "items": { - "type": "integer" - } - }, - "timestamp": { - "description": "@param timestamp uint64 Timestamp of the soft block", - "type": "integer" - } - } - }, - "softblocks.TransactionBatch": { - "type": "object", - "properties": { - "batchId": { - "description": "@param batchId uint64 ID of this transaction batch", - "type": "integer" - }, - "batchType": { - "description": "@param batchType TransactionBatchMarker Marker of the transaction batch,\n@param either `end_of_block`, `end_of_preconf` or empty", - "allOf": [ - { - "$ref": "#/definitions/softblocks.TransactionBatchMarker" - } - ] - }, - "blockId": { - "description": "@param blockId uint64 Block ID of the soft block", - "type": "integer" - }, - "blockParams": { - "description": "@param blockParams SoftBlockParams Block parameters of the soft block", - "allOf": [ - { - "$ref": "#/definitions/softblocks.SoftBlockParams" - } - ] - }, - "signature": { - "description": "@param signature string Signature of this transaction batch", - "type": "string" - }, - "transactions": { - "description": "@param transactions string zlib compressed RLP encoded bytes of a transactions list", - "type": "array", - "items": { - "type": "integer" - } - } - } - }, - "softblocks.TransactionBatchMarker": { - "type": "string", - "enum": ["", "endOfBlock", "endOfPreconf"], - "x-enum-varnames": [ - "BatchMarkerEmpty", - "BatchMarkerEOB", - "BatchMarkerEOP" - ] - }, - "types.Header": { - "type": "object", - "properties": { - "baseFeePerGas": { - "description": "BaseFee was added by EIP-1559 and is ignored in legacy headers.", - "allOf": [ - { - "$ref": "#/definitions/big.Int" - } - ] - }, - "blobGasUsed": { - "description": "BlobGasUsed was added by EIP-4844 and is ignored in legacy headers.", - "type": "integer" - }, - "difficulty": { - "$ref": "#/definitions/big.Int" - }, - "excessBlobGas": { - "description": "ExcessBlobGas was added by EIP-4844 and is ignored in legacy headers.", - "type": "integer" - }, - "extraData": { - "type": "array", - "items": { - "type": "integer" - } - }, - "gasLimit": { - "type": "integer" - }, - "gasUsed": { - "type": "integer" - }, - "logsBloom": { - "type": "array", - "items": { - "type": "integer" - } - }, - "miner": { - "type": "array", - "items": { - "type": "integer" - } - }, - "mixHash": { - "type": "array", - "items": { - "type": "integer" - } - }, - "nonce": { - "type": "array", - "items": { - "type": "integer" - } - }, - "number": { - "$ref": "#/definitions/big.Int" - }, - "parentBeaconBlockRoot": { - "description": "ParentBeaconRoot was added by EIP-4788 and is ignored in legacy headers.", - "type": "array", - "items": { - "type": "integer" - } - }, - "parentHash": { - "type": "array", - "items": { - "type": "integer" - } - }, - "receiptsRoot": { - "type": "array", - "items": { - "type": "integer" - } - }, - "requestsRoot": { - "description": "RequestsHash was added by EIP-7685 and is ignored in legacy headers.", - "type": "array", - "items": { - "type": "integer" - } - }, - "sha3Uncles": { - "type": "array", - "items": { - "type": "integer" - } - }, - "stateRoot": { - "type": "array", - "items": { - "type": "integer" - } - }, - "timestamp": { - "type": "integer" - }, - "transactionsRoot": { - "type": "array", - "items": { - "type": "integer" - } - }, - "withdrawalsRoot": { - "description": "WithdrawalsHash was added by EIP-4895 and is ignored in legacy headers.", - "type": "array", - "items": { - "type": "integer" - } - } - } - } - } -} diff --git a/packages/taiko-client/docs/swagger.yaml b/packages/taiko-client/docs/swagger.yaml deleted file mode 100644 index 88bafda32e4..00000000000 --- a/packages/taiko-client/docs/swagger.yaml +++ /dev/null @@ -1,266 +0,0 @@ -definitions: - big.Int: - type: object - softblocks.BuildSoftBlockRequestBody: - properties: - transactionBatch: - allOf: - - $ref: "#/definitions/softblocks.TransactionBatch" - description: - "@param transactionBatch TransactionBatch Transaction batch to - be inserted into the soft block" - type: object - softblocks.BuildSoftBlockResponseBody: - properties: - blockHeader: - allOf: - - $ref: "#/definitions/types.Header" - description: "@param blockHeader types.Header of the soft block" - type: object - softblocks.RemoveSoftBlocksRequestBody: - properties: - newLastBlockId: - description: |- - @param newLastBlockID uint64 New last block ID of the blockchain, it should - @param not smaller than the canonical chain's highest block ID. - type: integer - type: object - softblocks.RemoveSoftBlocksResponseBody: - properties: - headsRemoved: - description: "@param headsRemoved uint64 Number of soft heads removed" - type: integer - lastBlockId: - description: - "@param lastBlockID uint64 Current highest block ID of the blockchain - (including soft blocks)" - type: integer - lastProposedBlockID: - description: - "@param lastProposedBlockID uint64 Highest block ID of the cnonical - chain" - type: integer - type: object - softblocks.SoftBlockParams: - properties: - anchorBlockID: - description: - "@param anchorBlockID uint64 `_anchorBlockId` parameter of the - `anchorV2` transaction in soft block" - type: integer - anchorStateRoot: - description: - "@param anchorStateRoot string `_anchorStateRoot` parameter of - the `anchorV2` transaction in soft block" - items: - type: integer - type: array - coinbase: - description: "@param coinbase string Coinbase of the soft block" - items: - type: integer - type: array - timestamp: - description: "@param timestamp uint64 Timestamp of the soft block" - type: integer - type: object - softblocks.TransactionBatch: - properties: - batchId: - description: "@param batchId uint64 ID of this transaction batch" - type: integer - batchType: - allOf: - - $ref: "#/definitions/softblocks.TransactionBatchMarker" - description: |- - @param batchType TransactionBatchMarker Marker of the transaction batch, - @param either `end_of_block`, `end_of_preconf` or empty - blockId: - description: "@param blockId uint64 Block ID of the soft block" - type: integer - blockParams: - allOf: - - $ref: "#/definitions/softblocks.SoftBlockParams" - description: - "@param blockParams SoftBlockParams Block parameters of the soft - block" - signature: - description: "@param signature string Signature of this transaction batch" - type: string - transactions: - description: - "@param transactions string zlib compressed RLP encoded bytes - of a transactions list" - items: - type: integer - type: array - type: object - softblocks.TransactionBatchMarker: - enum: - - "" - - endOfBlock - - endOfPreconf - type: string - x-enum-varnames: - - BatchMarkerEmpty - - BatchMarkerEOB - - BatchMarkerEOP - types.Header: - properties: - baseFeePerGas: - allOf: - - $ref: "#/definitions/big.Int" - description: BaseFee was added by EIP-1559 and is ignored in legacy headers. - blobGasUsed: - description: BlobGasUsed was added by EIP-4844 and is ignored in legacy headers. - type: integer - difficulty: - $ref: "#/definitions/big.Int" - excessBlobGas: - description: - ExcessBlobGas was added by EIP-4844 and is ignored in legacy - headers. - type: integer - extraData: - items: - type: integer - type: array - gasLimit: - type: integer - gasUsed: - type: integer - logsBloom: - items: - type: integer - type: array - miner: - items: - type: integer - type: array - mixHash: - items: - type: integer - type: array - nonce: - items: - type: integer - type: array - number: - $ref: "#/definitions/big.Int" - parentBeaconBlockRoot: - description: - ParentBeaconRoot was added by EIP-4788 and is ignored in legacy - headers. - items: - type: integer - type: array - parentHash: - items: - type: integer - type: array - receiptsRoot: - items: - type: integer - type: array - requestsRoot: - description: RequestsHash was added by EIP-7685 and is ignored in legacy headers. - items: - type: integer - type: array - sha3Uncles: - items: - type: integer - type: array - stateRoot: - items: - type: integer - type: array - timestamp: - type: integer - transactionsRoot: - items: - type: integer - type: array - withdrawalsRoot: - description: - WithdrawalsHash was added by EIP-4895 and is ignored in legacy - headers. - items: - type: integer - type: array - type: object -info: - contact: - email: info@taiko.xyz - name: API Support - url: https://community.taiko.xyz/ - license: - name: MIT - url: https://github.com/taikoxyz/taiko-mono/blob/main/LICENSE.md - termsOfService: http://swagger.io/terms/ - title: Taiko Soft Block Server API - version: "1.0" -paths: - /healthz: - get: - consumes: - - application/json - operationId: health-check - produces: - - application/json - responses: - "200": - description: OK - schema: - type: string - summary: Get current server health status - /softBlocks: - delete: - consumes: - - application/json - description: |- - Remove all soft blocks from the blockchain beyond the specified block height, - ensuring the latest block ID does not exceed the given height. This method will fail if - the block with an ID one greater than the specified height is not a soft block. If the - specified block height is greater than the latest soft block ID, the method will succeed - without modifying the blockchain. - parameters: - - description: soft blocks removing request body - in: body - name: body - required: true - schema: - $ref: "#/definitions/softblocks.RemoveSoftBlocksRequestBody" - produces: - - application/json - responses: - "200": - description: OK - schema: - $ref: "#/definitions/softblocks.RemoveSoftBlocksResponseBody" - post: - consumes: - - application/json - description: |- - Insert a batch of transactions into a soft block for preconfirmation. If the batch is the - first for a block, a new soft block will be created. Otherwise, the transactions will - be appended to the existing soft block. The API will fail if: - 1) the block is not soft - 2) block-level parameters are invalid or do not match the current soft block’s parameters - 3) the batch ID is not exactly 1 greater than the previous one - 4) the last batch of the block indicates no further transactions are allowed - parameters: - - description: soft block creation request body - in: body - name: body - required: true - schema: - $ref: "#/definitions/softblocks.BuildSoftBlockRequestBody" - produces: - - application/json - responses: - "200": - description: OK - schema: - $ref: "#/definitions/softblocks.BuildSoftBlockResponseBody" -swagger: "2.0" diff --git a/packages/taiko-client/driver/chain_syncer/beaconsync/syncer.go b/packages/taiko-client/driver/chain_syncer/beaconsync/syncer.go index 0860dc9d46e..1187e3789aa 100644 --- a/packages/taiko-client/driver/chain_syncer/beaconsync/syncer.go +++ b/packages/taiko-client/driver/chain_syncer/beaconsync/syncer.go @@ -6,11 +6,8 @@ import ( "math/big" "github.com/ethereum/go-ethereum/beacon/engine" - "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/eth/downloader" "github.com/ethereum/go-ethereum/log" - "github.com/taikoxyz/taiko-mono/packages/taiko-client/bindings" "github.com/taikoxyz/taiko-mono/packages/taiko-client/bindings/encoding" "github.com/taikoxyz/taiko-mono/packages/taiko-client/driver/state" "github.com/taikoxyz/taiko-mono/packages/taiko-client/pkg/rpc" @@ -22,7 +19,6 @@ type Syncer struct { ctx context.Context rpc *rpc.Client state *state.State - syncMode string progressTracker *SyncProgressTracker // Sync progress tracker } @@ -31,10 +27,9 @@ func NewSyncer( ctx context.Context, rpc *rpc.Client, state *state.State, - syncMode string, progressTracker *SyncProgressTracker, ) *Syncer { - return &Syncer{ctx, rpc, state, syncMode, progressTracker} + return &Syncer{ctx, rpc, state, progressTracker} } // TriggerBeaconSync triggers the L2 execution engine to start performing a beacon sync, if the @@ -101,36 +96,6 @@ func (s *Syncer) getBlockPayload(ctx context.Context, blockID uint64) (*engine.E return nil, err } - // If the sync mode is `full`, we need to verify the protocol verified block hash before syncing. - if s.syncMode == downloader.FullSync.String() { - blockNum := new(big.Int).SetUint64(blockID) - var blockInfo bindings.TaikoDataBlockV2 - if s.state.IsOnTake(blockNum) { - blockInfo, err = s.rpc.GetL2BlockInfoV2(ctx, blockNum) - } else { - blockInfo, err = s.rpc.GetL2BlockInfo(ctx, blockNum) - } - if err != nil { - return nil, err - } - ts, err := s.rpc.GetTransition( - ctx, - new(big.Int).SetUint64(blockInfo.BlockId), - - uint32(blockInfo.VerifiedTransitionId.Uint64()), - ) - if err != nil { - return nil, err - } - if header.Hash() != ts.BlockHash { - return nil, fmt.Errorf( - "latest verified block hash mismatch: %s != %s", - header.Hash(), - common.BytesToHash(ts.BlockHash[:]), - ) - } - } - log.Info("Block header to sync retrieved", "hash", header.Hash()) return encoding.ToExecutableData(header), nil diff --git a/packages/taiko-client/driver/chain_syncer/blob/soft_block.go b/packages/taiko-client/driver/chain_syncer/blob/soft_block.go deleted file mode 100644 index 4c4e6e5064a..00000000000 --- a/packages/taiko-client/driver/chain_syncer/blob/soft_block.go +++ /dev/null @@ -1,298 +0,0 @@ -package blob - -import ( - "context" - "errors" - "fmt" - "math/big" - - "github.com/ethereum/go-ethereum/accounts/abi/bind" - "github.com/ethereum/go-ethereum/beacon/engine" - "github.com/ethereum/go-ethereum/common" - consensus "github.com/ethereum/go-ethereum/consensus/taiko" - "github.com/ethereum/go-ethereum/core/rawdb" - "github.com/ethereum/go-ethereum/core/types" - "github.com/ethereum/go-ethereum/crypto" - "github.com/ethereum/go-ethereum/log" - "github.com/ethereum/go-ethereum/rlp" - - "github.com/taikoxyz/taiko-mono/packages/taiko-client/bindings/encoding" - softblocks "github.com/taikoxyz/taiko-mono/packages/taiko-client/driver/soft_blocks" - "github.com/taikoxyz/taiko-mono/packages/taiko-client/pkg/rpc" - "github.com/taikoxyz/taiko-mono/packages/taiko-client/pkg/utils" -) - -// InsertSoftBlockFromTransactionsBatch inserts a soft block into the L2 execution engine's blockchain -// from the given transactions batch. -func (s *Syncer) InsertSoftBlockFromTransactionsBatch( - ctx context.Context, - blockID uint64, - batchID uint64, - txListBytes []byte, - batchMarker softblocks.TransactionBatchMarker, - blockParams *softblocks.SoftBlockParams, -) (*types.Header, error) { - s.mutex.Lock() - defer s.mutex.Unlock() - - parent, err := s.rpc.L2.HeaderByNumber(ctx, new(big.Int).Sub(new(big.Int).SetUint64(blockID), common.Big1)) - if err != nil { - return nil, err - } - - if parent.Number.Uint64()+1 != blockID { - return nil, fmt.Errorf("parent block number (%d) is not equal to blockID - 1 (%d)", parent.Number.Uint64(), blockID) - } - - // Calculate the other block parameters - difficultyHashPaylaod, err := encoding.EncodeDifficultyCalcutionParams(blockID) - if err != nil { - return nil, fmt.Errorf("failed to encode `block.difficulty` calculation parameters: %w", err) - } - protocolConfigs, err := rpc.GetProtocolConfigs(s.rpc.TaikoL1, &bind.CallOpts{Context: ctx}) - if err != nil { - return nil, fmt.Errorf("failed to fetch protocol configs: %w", err) - } - - var ( - txList []*types.Transaction - fc = &engine.ForkchoiceStateV1{HeadBlockHash: parent.Hash()} - difficulty = crypto.Keccak256Hash(difficultyHashPaylaod) - extraData = encoding.EncodeBaseFeeConfig(&protocolConfigs.BaseFeeConfig) - ) - - if err := rlp.DecodeBytes(txListBytes, &txList); err != nil { - return nil, fmt.Errorf("failed to RLP decode txList bytes: %w", err) - } - - baseFee, err := s.rpc.CalculateBaseFee( - ctx, - parent, - new(big.Int).SetUint64(blockParams.AnchorBlockID), - true, - &protocolConfigs.BaseFeeConfig, - blockParams.Timestamp, - ) - if err != nil { - return nil, fmt.Errorf("failed to calculate base fee: %w", err) - } - - // Insert the anchor transaction at the head of the transactions list. - if batchID == 0 { - // Assemble a TaikoL2.anchorV2 transaction. - anchorTx, err := s.anchorConstructor.AssembleAnchorV2Tx( - ctx, - new(big.Int).SetUint64(blockParams.AnchorBlockID), - blockParams.AnchorStateRoot, - parent.GasUsed, - &protocolConfigs.BaseFeeConfig, - new(big.Int).SetUint64(blockID), - baseFee, - ) - if err != nil { - return nil, fmt.Errorf("failed to create TaikoL2.anchorV2 transaction: %w", err) - } - - txList = append([]*types.Transaction{anchorTx}, txList...) - } else { - prevSoftBlock, err := s.rpc.L2.BlockByNumber(ctx, new(big.Int).SetUint64(blockID)) - if err != nil { - return nil, fmt.Errorf("failed to fetch previous soft block (%d): %w", blockID, err) - } - - // Ensure the previous soft block is the current chain head. - blockNums, err := s.rpc.L2.BlockNumber(ctx) - if err != nil { - return nil, fmt.Errorf("failed to fetch the chain block number: %w", err) - } - - if prevSoftBlock.Number().Uint64() != blockNums { - return nil, fmt.Errorf( - "soft block (%d) to update is not the current chain head (%d)", - prevSoftBlock.Number().Uint64(), - blockNums, - ) - } - - // Check baseFee - if prevSoftBlock.BaseFee().Cmp(baseFee) != 0 { - return nil, fmt.Errorf( - "baseFee is not equal to the latest soft block's, expect: %s, actual: %s", - prevSoftBlock.BaseFee().String(), - baseFee.String(), - ) - } - - // Check the previous soft block status. - l1Origin, err := s.rpc.L2.L1OriginByID(ctx, prevSoftBlock.Number()) - if err != nil { - return nil, fmt.Errorf("failed to fetch L1 origin for block %d: %w", blockID, err) - } - if l1Origin.BatchID == nil { - return nil, fmt.Errorf("batch ID is nil for block %d", blockID) - } - if l1Origin.BatchID.Uint64()+1 != batchID { - return nil, fmt.Errorf("batch ID mismatch: expected %d, got %d", l1Origin.BatchID.Uint64()+1, batchID) - } - if l1Origin.EndOfBlock { - return nil, fmt.Errorf("soft block %d has already been marked as ended", blockID) - } - if l1Origin.EndOfPreconf { - return nil, fmt.Errorf("preconfirmation from %s has already been marked as ended", blockParams.Coinbase) - } - - txList = append(prevSoftBlock.Transactions(), txList...) - } - - if txListBytes, err = rlp.EncodeToBytes(txList); err != nil { - log.Error("Encode txList error", "blockID", blockID, "error", err) - return nil, err - } - - attributes := &engine.PayloadAttributes{ - Timestamp: blockParams.Timestamp, - Random: difficulty, - SuggestedFeeRecipient: blockParams.Coinbase, - Withdrawals: []*types.Withdrawal{}, - BlockMetadata: &engine.BlockMetadata{ - Beneficiary: blockParams.Coinbase, - GasLimit: uint64(protocolConfigs.BlockMaxGasLimit) + consensus.AnchorGasLimit, - Timestamp: blockParams.Timestamp, - TxList: txListBytes, - MixHash: difficulty, - ExtraData: extraData[:], - }, - BaseFeePerGas: baseFee, - L1Origin: &rawdb.L1Origin{ - BlockID: new(big.Int).SetUint64(blockID), - L2BlockHash: common.Hash{}, // Will be set by taiko-geth. - L1BlockHeight: nil, // No L1 block height for soft blocks. - L1BlockHash: common.Hash{}, // No L1 block hash for soft blocks. - BatchID: new(big.Int).SetUint64(batchID), - EndOfBlock: batchMarker == softblocks.BatchMarkerEOB, - EndOfPreconf: batchMarker == softblocks.BatchMarkerEOP, - Preconfer: blockParams.Coinbase, - }, - } - - log.Info( - "Soft block payloadAttributes", - "blockID", blockID, - "batchID", batchID, - "timestamp", attributes.Timestamp, - "random", attributes.Random, - "suggestedFeeRecipient", attributes.SuggestedFeeRecipient, - "withdrawals", len(attributes.Withdrawals), - "gasLimit", attributes.BlockMetadata.GasLimit, - "timestamp", attributes.BlockMetadata.Timestamp, - "mixHash", attributes.BlockMetadata.MixHash, - "baseFee", utils.WeiToGWei(attributes.BaseFeePerGas), - "extraData", common.Bytes2Hex(attributes.BlockMetadata.ExtraData), - "transactions", len(txList), - ) - - // Step 1, prepare a payload - fcRes, err := s.rpc.L2Engine.ForkchoiceUpdate(ctx, fc, attributes) - if err != nil { - return nil, fmt.Errorf("failed to update fork choice: %w", err) - } - if fcRes.PayloadStatus.Status != engine.VALID { - return nil, fmt.Errorf("unexpected ForkchoiceUpdate response status: %s", fcRes.PayloadStatus.Status) - } - if fcRes.PayloadID == nil { - return nil, errors.New("empty payload ID") - } - - // Step 2, get the payload - payload, err := s.rpc.L2Engine.GetPayload(ctx, fcRes.PayloadID) - if err != nil { - return nil, fmt.Errorf("failed to get payload: %w", err) - } - - log.Info( - "Soft block payload", - "blockID", blockID, - "batchID", batchID, - "baseFee", utils.WeiToGWei(payload.BaseFeePerGas), - "number", payload.Number, - "hash", payload.BlockHash, - "gasLimit", payload.GasLimit, - "gasUsed", payload.GasUsed, - "timestamp", payload.Timestamp, - "withdrawalsHash", payload.WithdrawalsHash, - ) - - // Step 3, execute the payload - execStatus, err := s.rpc.L2Engine.NewPayload(ctx, payload) - if err != nil { - return nil, fmt.Errorf("failed to create a new payload: %w", err) - } - if execStatus.Status != engine.VALID { - return nil, fmt.Errorf("unexpected NewPayload response status: %s", execStatus.Status) - } - - lastVerifiedBlockInfo, err := s.rpc.GetLastVerifiedBlock(ctx) - if err != nil { - return nil, fmt.Errorf("failed to fetch last verified block hash: %w", err) - } - - canonicalHead, err := s.rpc.L2.HeadL1Origin(ctx) - if err != nil { - return nil, fmt.Errorf("failed to fetch canonical head: %w", err) - } - - // Step 4, update the fork choice - fc = &engine.ForkchoiceStateV1{ - HeadBlockHash: payload.BlockHash, - SafeBlockHash: canonicalHead.L2BlockHash, - FinalizedBlockHash: lastVerifiedBlockInfo.BlockHash, - } - fcRes, err = s.rpc.L2Engine.ForkchoiceUpdate(ctx, fc, nil) - if err != nil { - return nil, err - } - if fcRes.PayloadStatus.Status != engine.VALID { - return nil, fmt.Errorf("unexpected ForkchoiceUpdate response status: %s", fcRes.PayloadStatus.Status) - } - - header, err := s.rpc.L2.HeaderByHash(ctx, payload.BlockHash) - if err != nil { - return nil, err - } - - log.Info( - "⏰ New soft L2 block inserted", - "blockID", blockID, - "batchID", batchID, - "hash", header.Hash(), - "transactions", len(payload.Transactions), - "baseFee", utils.WeiToGWei(header.BaseFee), - "withdrawals", len(payload.Withdrawals), - "endOfBlock", attributes.L1Origin.EndOfBlock, - "endOfPreconf", attributes.L1Origin.EndOfPreconf, - ) - - return header, nil -} - -// RemoveSoftBlocks removes soft blocks from the L2 execution engine's blockchain. -func (s *Syncer) RemoveSoftBlocks(ctx context.Context, newLastBlockID uint64) error { - s.mutex.Lock() - defer s.mutex.Unlock() - - newHead, err := s.rpc.L2.HeaderByNumber(ctx, new(big.Int).SetUint64(newLastBlockID)) - if err != nil { - return err - } - - fc := &engine.ForkchoiceStateV1{HeadBlockHash: newHead.Hash()} - fcRes, err := s.rpc.L2Engine.ForkchoiceUpdate(ctx, fc, nil) - if err != nil { - return err - } - if fcRes.PayloadStatus.Status != engine.VALID { - return fmt.Errorf("unexpected ForkchoiceUpdate response status: %s", fcRes.PayloadStatus.Status) - } - - return nil -} diff --git a/packages/taiko-client/driver/chain_syncer/blob/syncer.go b/packages/taiko-client/driver/chain_syncer/blob/syncer.go index 0182d98855e..a4a80ff2160 100644 --- a/packages/taiko-client/driver/chain_syncer/blob/syncer.go +++ b/packages/taiko-client/driver/chain_syncer/blob/syncer.go @@ -207,6 +207,7 @@ func (s *Syncer) onBlockProposed( } // Ignore those already inserted blocks. if s.lastInsertedBlockID != nil && meta.GetBlockID().Cmp(s.lastInsertedBlockID) <= 0 { + log.Debug("Skip already inserted block", "blockID", meta.GetBlockID(), "lastInsertedBlockID", s.lastInsertedBlockID) return nil } @@ -233,6 +234,7 @@ func (s *Syncer) onBlockProposed( if s.progressTracker.Triggered() { // Already synced through beacon sync, just skip this event. if meta.GetBlockID().Cmp(s.progressTracker.LastSyncedBlockID()) <= 0 { + log.Debug("Skip already beacon synced block", "blockID", meta.GetBlockID()) return nil } @@ -424,7 +426,7 @@ func (s *Syncer) insertNewHead( fc := &engine.ForkchoiceStateV1{ HeadBlockHash: payload.BlockHash, - SafeBlockHash: payload.BlockHash, + SafeBlockHash: lastVerifiedBlockHash, FinalizedBlockHash: lastVerifiedBlockHash, } diff --git a/packages/taiko-client/driver/chain_syncer/blob/syncer_test.go b/packages/taiko-client/driver/chain_syncer/blob/syncer_test.go index 062247a61ef..23755a2d0e4 100644 --- a/packages/taiko-client/driver/chain_syncer/blob/syncer_test.go +++ b/packages/taiko-client/driver/chain_syncer/blob/syncer_test.go @@ -11,10 +11,13 @@ import ( "golang.org/x/exp/slog" "github.com/ethereum-optimism/optimism/op-service/txmgr" + "github.com/ethereum/go-ethereum/beacon/engine" "github.com/ethereum/go-ethereum/common" + "github.com/ethereum/go-ethereum/consensus/taiko" "github.com/ethereum/go-ethereum/core/rawdb" "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/crypto" + "github.com/ethereum/go-ethereum/rlp" "github.com/stretchr/testify/suite" "github.com/taikoxyz/taiko-mono/packages/taiko-client/bindings" @@ -59,6 +62,99 @@ func (s *BlobSyncerTestSuite) SetupTest() { s.initProposer() } +func (s *BlobSyncerTestSuite) TestBlobSyncRobustness() { + ctx := context.Background() + + meta := s.ProposeAndInsertValidBlock(s.p, s.s) + + block, err := s.RPCClient.L2.BlockByNumber(ctx, meta.GetBlockID()) + s.Nil(err) + + lastVerifiedBlockInfo, err := s.s.rpc.GetLastVerifiedBlock(ctx) + s.Nil(err) + + txListBytes, err := rlp.EncodeToBytes(block.Transactions()) + s.Nil(err) + + parent, err := s.RPCClient.L2ParentByBlockID(context.Background(), meta.GetBlockID()) + s.Nil(err) + + // Reset l2 chain. + s.Nil(rpc.SetHead(ctx, s.RPCClient.L2, common.Big0)) + + attributes := &engine.PayloadAttributes{ + Timestamp: meta.GetTimestamp(), + Random: meta.GetDifficulty(), + SuggestedFeeRecipient: meta.GetCoinbase(), + Withdrawals: make([]*types.Withdrawal, 0), + BlockMetadata: &engine.BlockMetadata{ + Beneficiary: meta.GetCoinbase(), + GasLimit: uint64(meta.GetGasLimit()) + taiko.AnchorGasLimit, + Timestamp: meta.GetTimestamp(), + TxList: txListBytes, + MixHash: meta.GetDifficulty(), + ExtraData: meta.GetExtraData(), + }, + BaseFeePerGas: block.BaseFee(), + L1Origin: &rawdb.L1Origin{ + BlockID: meta.GetBlockID(), + L2BlockHash: common.Hash{}, // Will be set by taiko-geth. + L1BlockHeight: meta.GetRawBlockHeight(), + L1BlockHash: meta.GetRawBlockHash(), + }, + } + + step0 := func() *engine.ForkChoiceResponse { + fcRes, err := s.RPCClient.L2Engine.ForkchoiceUpdate( + ctx, + &engine.ForkchoiceStateV1{HeadBlockHash: parent.Hash()}, + attributes, + ) + s.Nil(err) + s.Equal(engine.VALID, fcRes.PayloadStatus.Status) + s.True(true, fcRes.PayloadID != nil) + return fcRes + } + + step1 := func(fcRes *engine.ForkChoiceResponse) *engine.ExecutableData { + payload, err := s.RPCClient.L2Engine.GetPayload(ctx, fcRes.PayloadID) + s.Nil(err) + return payload + } + + step2 := func(payload *engine.ExecutableData) *engine.ExecutableData { + execStatus, err := s.RPCClient.L2Engine.NewPayload(ctx, payload) + s.Nil(err) + s.Equal(engine.VALID, execStatus.Status) + return payload + } + + step3 := func(payload *engine.ExecutableData) { + fcRes, err := s.RPCClient.L2Engine.ForkchoiceUpdate(ctx, &engine.ForkchoiceStateV1{ + HeadBlockHash: payload.BlockHash, + SafeBlockHash: lastVerifiedBlockInfo.BlockHash, + FinalizedBlockHash: lastVerifiedBlockInfo.BlockHash, + }, nil) + s.Nil(err) + s.Equal(engine.VALID, fcRes.PayloadStatus.Status) + } + + loopSize := 10 + for i := 0; i < loopSize; i++ { + step0() + } + + for i := 0; i < loopSize; i++ { + step1(step0()) + } + + for i := 0; i < loopSize; i++ { + step2(step1(step0())) + } + + step3(step2(step1(step0()))) +} + func (s *BlobSyncerTestSuite) TestProcessL1Blocks() { s.Nil(s.s.ProcessL1Blocks(context.Background())) } diff --git a/packages/taiko-client/driver/chain_syncer/chain_syncer.go b/packages/taiko-client/driver/chain_syncer/chain_syncer.go index 5402b5766f6..b7e834a4f05 100644 --- a/packages/taiko-client/driver/chain_syncer/chain_syncer.go +++ b/packages/taiko-client/driver/chain_syncer/chain_syncer.go @@ -6,8 +6,6 @@ import ( "net/url" "time" - "github.com/ethereum/go-ethereum/accounts/abi/bind" - "github.com/ethereum/go-ethereum/eth/downloader" "github.com/ethereum/go-ethereum/log" "github.com/taikoxyz/taiko-mono/packages/taiko-client/driver/chain_syncer/beaconsync" @@ -30,9 +28,6 @@ type L2ChainSyncer struct { // Monitors progressTracker *beaconsync.SyncProgressTracker - // Sync mode - syncMode string - // If this flag is activated, will try P2P beacon sync if current node is behind of the protocol's // the latest verified block head p2pSync bool @@ -52,11 +47,7 @@ func New( tracker := beaconsync.NewSyncProgressTracker(rpc.L2, p2pSyncTimeout) go tracker.Track(ctx) - syncMode, err := rpc.L2.GetSyncMode(ctx) - if err != nil { - return nil, err - } - beaconSyncer := beaconsync.NewSyncer(ctx, rpc, state, syncMode, tracker) + beaconSyncer := beaconsync.NewSyncer(ctx, rpc, state, tracker) blobSyncer, err := blob.NewSyncer( ctx, rpc, @@ -77,7 +68,6 @@ func New( beaconSyncer: beaconSyncer, blobSyncer: blobSyncer, progressTracker: tracker, - syncMode: syncMode, p2pSync: p2pSync, }, nil } @@ -88,6 +78,7 @@ func (s *L2ChainSyncer) Sync() error { if err != nil { return err } + // If current L2 execution engine's chain is behind of the block head to sync, and the // `P2PSync` flag is set, try triggering a beacon sync in L2 execution engine to catch up the // head. @@ -99,6 +90,10 @@ func (s *L2ChainSyncer) Sync() error { return nil } + // Mark the beacon sync progress as finished, To make sure that + // we will only check and trigger P2P sync progress once right after the driver starts + s.progressTracker.MarkFinished() + // We have triggered at least a beacon sync in L2 execution engine, we should reset the L1Current // cursor at first, before start inserting pending L2 blocks one by one. if s.progressTracker.Triggered() { @@ -108,26 +103,23 @@ func (s *L2ChainSyncer) Sync() error { "p2pOutOfSync", s.progressTracker.OutOfSync(), ) - // Mark the beacon sync progress as finished. - s.progressTracker.MarkFinished() - // Get the execution engine's chain head. l2Head, err := s.rpc.L2.HeaderByNumber(s.ctx, nil) if err != nil { - return err + return fmt.Errorf("failed to get L2 chain head: %w", err) } log.Info( "L2 head information", "number", l2Head.Number, "hash", l2Head.Hash(), - "lastSyncedVerifiedBlockID", s.progressTracker.LastSyncedBlockID(), - "lastSyncedVerifiedBlockHash", s.progressTracker.LastSyncedBlockHash(), + "lastSyncedBlockID", s.progressTracker.LastSyncedBlockID(), + "lastSyncedBlockHash", s.progressTracker.LastSyncedBlockHash(), ) // Reset the L1Current cursor. if err := s.state.ResetL1Current(s.ctx, l2Head.Number); err != nil { - return err + return fmt.Errorf("failed to reset L1 current cursor: %w", err) } // Reset to the latest L2 execution engine's chain status. @@ -140,7 +132,7 @@ func (s *L2ChainSyncer) Sync() error { // AheadOfHeadToSync checks whether the L2 chain is ahead of the head to sync in protocol. func (s *L2ChainSyncer) AheadOfHeadToSync(heightToSync uint64) bool { - log.Debug( + log.Info( "Checking whether the execution engine is ahead of the head to sync", "heightToSync", heightToSync, "executionEngineHead", s.state.GetL2Head().Number, @@ -156,12 +148,23 @@ func (s *L2ChainSyncer) AheadOfHeadToSync(heightToSync uint64) bool { // If the L2 execution engine's chain is behind of the block head to sync, // we should keep the beacon sync. if s.state.GetL2Head().Number.Uint64() < heightToSync { + log.Info( + "L2 execution engine is behind of the head to sync", + "heightToSync", heightToSync, + "executionEngineHead", s.state.GetL2Head().Number, + ) return false } // If the L2 execution engine's chain is ahead of the block head to sync, // we can mark the beacon sync progress as finished. if s.progressTracker.LastSyncedBlockID() != nil { + log.Info( + "L2 execution engine is ahead of the head to sync", + "heightToSync", heightToSync, + "executionEngineHead", s.state.GetL2Head().Number, + "lastSyncedBlockID", s.progressTracker.LastSyncedBlockID(), + ) return s.state.GetL2Head().Number.Uint64() >= s.progressTracker.LastSyncedBlockID().Uint64() } @@ -170,9 +173,9 @@ func (s *L2ChainSyncer) AheadOfHeadToSync(heightToSync uint64) bool { // needNewBeaconSyncTriggered checks whether the current L2 execution engine needs to trigger // another new beacon sync, the following conditions should be met: -// 1. The `P2PSync` flag is set. -// 2. The protocol's latest verified block head is not zero. -// 3. The L2 execution engine's chain is behind of the protocol's latest verified block head. +// 1. The `--p2p.sync` flag is set. +// 2. The protocol's (last verified) block head is not zero. +// 3. The L2 execution engine's chain is behind of the protocol's (latest verified) block head. // 4. The L2 execution engine's chain has met a sync timeout issue. func (s *L2ChainSyncer) needNewBeaconSyncTriggered() (uint64, bool, error) { // If the flag is not set or there was a finished beacon sync, we simply return false. @@ -180,24 +183,9 @@ func (s *L2ChainSyncer) needNewBeaconSyncTriggered() (uint64, bool, error) { return 0, false, nil } - // For full sync mode, we will use the verified block head, - // and for snap sync mode, we will use the latest block head. - var blockID uint64 - switch s.syncMode { - case downloader.SnapSync.String(): - headL1Origin, err := s.rpc.L2CheckPoint.HeadL1Origin(s.ctx) - if err != nil { - return 0, false, err - } - blockID = headL1Origin.BlockID.Uint64() - case downloader.FullSync.String(): - stateVars, err := s.rpc.GetProtocolStateVariables(&bind.CallOpts{Context: s.ctx}) - if err != nil { - return 0, false, err - } - blockID = stateVars.B.LastVerifiedBlockId - default: - return 0, false, fmt.Errorf("invalid sync mode: %s", s.syncMode) + blockID, err := s.rpc.L2CheckPoint.BlockNumber(s.ctx) + if err != nil { + return 0, false, err } // If the protocol's block head is zero, we simply return false. diff --git a/packages/taiko-client/driver/config.go b/packages/taiko-client/driver/config.go index ea8019f044f..60a11340e5a 100644 --- a/packages/taiko-client/driver/config.go +++ b/packages/taiko-client/driver/config.go @@ -17,17 +17,13 @@ import ( // Config contains the configurations to initialize a Taiko driver. type Config struct { *rpc.ClientConfig - P2PSync bool - P2PSyncTimeout time.Duration - RetryInterval time.Duration - MaxExponent uint64 - BlobServerEndpoint *url.URL - SocialScanEndpoint *url.URL - RPCWriteTimeout time.Duration - SoftBlockServerPort uint64 - SoftBlockServerJWTSecret []byte - SoftBlockServerCORSOrigins string - SoftBlockServerCheckSig bool + P2PSync bool + P2PSyncTimeout time.Duration + RetryInterval time.Duration + MaxExponent uint64 + BlobServerEndpoint *url.URL + SocialScanEndpoint *url.URL + RPCWriteTimeout time.Duration } // NewConfigFromCliContext creates a new config instance from @@ -74,15 +70,6 @@ func NewConfigFromCliContext(c *cli.Context) (*Config, error) { return nil, errors.New("empty L1 beacon endpoint, blob server and Social Scan endpoint") } - var softBlockServerJWTSecret []byte - if c.String(flags.SoftBlockServerJWTSecret.Name) != "" { - if softBlockServerJWTSecret, err = jwt.ParseSecretFromFile( - c.String(flags.SoftBlockServerJWTSecret.Name), - ); err != nil { - return nil, fmt.Errorf("invalid JWT secret file: %w", err) - } - } - var timeout = c.Duration(flags.RPCTimeout.Name) var rpcWriteTimeout = c.Duration(flags.RPCWriteTimeout.Name) return &Config{ @@ -97,16 +84,12 @@ func NewConfigFromCliContext(c *cli.Context) (*Config, error) { JwtSecret: string(jwtSecret), Timeout: timeout, }, - RetryInterval: c.Duration(flags.BackOffRetryInterval.Name), - P2PSync: p2pSync, - P2PSyncTimeout: c.Duration(flags.P2PSyncTimeout.Name), - MaxExponent: c.Uint64(flags.MaxExponent.Name), - BlobServerEndpoint: blobServerEndpoint, - SocialScanEndpoint: socialScanEndpoint, - RPCWriteTimeout: rpcWriteTimeout, - SoftBlockServerPort: c.Uint64(flags.SoftBlockServerPort.Name), - SoftBlockServerJWTSecret: softBlockServerJWTSecret, - SoftBlockServerCORSOrigins: c.String(flags.SoftBlockServerCORSOrigins.Name), - SoftBlockServerCheckSig: c.Bool(flags.SoftBlockServerCheckSig.Name), + RetryInterval: c.Duration(flags.BackOffRetryInterval.Name), + P2PSync: p2pSync, + P2PSyncTimeout: c.Duration(flags.P2PSyncTimeout.Name), + MaxExponent: c.Uint64(flags.MaxExponent.Name), + BlobServerEndpoint: blobServerEndpoint, + SocialScanEndpoint: socialScanEndpoint, + RPCWriteTimeout: rpcWriteTimeout, }, nil } diff --git a/packages/taiko-client/driver/driver.go b/packages/taiko-client/driver/driver.go index 33f142bb9fc..60fae5dd6df 100644 --- a/packages/taiko-client/driver/driver.go +++ b/packages/taiko-client/driver/driver.go @@ -22,8 +22,8 @@ import ( "github.com/urfave/cli/v2" chainSyncer "github.com/taikoxyz/taiko-mono/packages/taiko-client/driver/chain_syncer" - softblocks "github.com/taikoxyz/taiko-mono/packages/taiko-client/driver/soft_blocks" "github.com/taikoxyz/taiko-mono/packages/taiko-client/driver/state" + "github.com/taikoxyz/taiko-mono/packages/taiko-client/internal/version" "github.com/taikoxyz/taiko-mono/packages/taiko-client/pkg/rpc" ) @@ -36,10 +36,9 @@ const ( // contract. type Driver struct { *Config - rpc *rpc.Client - l2ChainSyncer *chainSyncer.L2ChainSyncer - softblockServer *softblocks.SoftBlockAPIServer - state *state.State + rpc *rpc.Client + l2ChainSyncer *chainSyncer.L2ChainSyncer + state *state.State l1HeadCh chan *types.Header l1HeadSub event.Subscription @@ -60,6 +59,8 @@ func (d *Driver) InitFromCli(ctx context.Context, c *cli.Context) error { // InitFromConfig initializes the driver instance based on the given configurations. func (d *Driver) InitFromConfig(ctx context.Context, cfg *Config) (err error) { + log.Info("Initializing driver", "version", version.CommitVersion()) + d.l1HeadCh = make(chan *types.Header, 1024) d.ctx = ctx d.Config = cfg @@ -98,18 +99,6 @@ func (d *Driver) InitFromConfig(ctx context.Context, cfg *Config) (err error) { d.l1HeadSub = d.state.SubL1HeadsFeed(d.l1HeadCh) - if d.SoftBlockServerPort > 0 { - if d.softblockServer, err = softblocks.New( - d.SoftBlockServerCORSOrigins, - d.SoftBlockServerJWTSecret, - d.l2ChainSyncer.BlobSyncer(), - d.rpc, - d.Config.SoftBlockServerCheckSig, - ); err != nil { - return err - } - } - return nil } @@ -120,16 +109,6 @@ func (d *Driver) Start() error { go d.reportProtocolStatus() go d.exchangeTransitionConfigLoop() - // Start the soft block server if it is enabled. - if d.softblockServer != nil { - log.Info("Starting soft block server", "port", d.SoftBlockServerPort) - go func() { - if err := d.softblockServer.Start(d.SoftBlockServerPort); err != nil { - log.Crit("Failed to start soft block server", "error", err) - } - }() - } - return nil } @@ -137,12 +116,6 @@ func (d *Driver) Start() error { func (d *Driver) Close(_ context.Context) { d.l1HeadSub.Unsubscribe() d.state.Close() - // Close the soft block server if it is enabled. - if d.softblockServer != nil { - if err := d.softblockServer.Shutdown(d.ctx); err != nil { - log.Error("Failed to shutdown soft block server", "error", err) - } - } d.wg.Wait() } diff --git a/packages/taiko-client/driver/driver_test.go b/packages/taiko-client/driver/driver_test.go index cbcac077581..88d3b5c5520 100644 --- a/packages/taiko-client/driver/driver_test.go +++ b/packages/taiko-client/driver/driver_test.go @@ -1,28 +1,18 @@ package driver import ( - "bytes" - "compress/zlib" "context" - "fmt" "math/big" - "net/url" "os" "testing" "time" "github.com/ethereum-optimism/optimism/op-service/txmgr" "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/core/types" "github.com/ethereum/go-ethereum/crypto" - "github.com/ethereum/go-ethereum/log" - "github.com/ethereum/go-ethereum/params" - "github.com/ethereum/go-ethereum/rlp" - "github.com/go-resty/resty/v2" "github.com/stretchr/testify/suite" "github.com/taikoxyz/taiko-mono/packages/taiko-client/bindings/encoding" - softblocks "github.com/taikoxyz/taiko-mono/packages/taiko-client/driver/soft_blocks" "github.com/taikoxyz/taiko-mono/packages/taiko-client/internal/testutils" "github.com/taikoxyz/taiko-mono/packages/taiko-client/pkg/jwt" "github.com/taikoxyz/taiko-mono/packages/taiko-client/pkg/rpc" @@ -355,350 +345,6 @@ func (s *DriverTestSuite) InitProposer() { s.p = p } -func (s *DriverTestSuite) TestInsertSoftBlocks() { - var ( - port = uint64(testutils.RandomPort()) - err error - ) - s.d.softblockServer, err = softblocks.New("*", nil, s.d.ChainSyncer().BlobSyncer(), s.RPCClient, true) - s.Nil(err) - go func() { s.NotNil(s.d.softblockServer.Start(port)) }() - defer func() { s.Nil(s.d.softblockServer.Shutdown(s.d.ctx)) }() - - url, err := url.Parse(fmt.Sprintf("http://localhost:%v", port)) - s.Nil(err) - - l2Head1, err := s.d.rpc.L2.HeaderByNumber(context.Background(), nil) - s.Nil(err) - - s.Nil(s.d.ChainSyncer().BlobSyncer().ProcessL1Blocks(context.Background())) - - // Propose a valid L2 block - s.ProposeAndInsertValidBlock(s.p, s.d.ChainSyncer().BlobSyncer()) - - l2Head2, err := s.d.rpc.L2.HeaderByNumber(context.Background(), nil) - s.Nil(err) - - l1Head1, err := s.d.rpc.L1.HeaderByNumber(context.Background(), nil) - s.Nil(err) - - s.Greater(l2Head2.Number.Uint64(), l2Head1.Number.Uint64()) - - res, err := resty.New().R().Get(url.String() + "/healthz") - s.Nil(err) - s.True(res.IsSuccess()) - - // Try to insert a soft block with batch ID 0 - s.True(s.insertSoftBlock(url, l1Head1, l2Head2.Number.Uint64()+1, 0, false, false).IsSuccess()) - l2Head3, err := s.d.rpc.L2.BlockByNumber(context.Background(), nil) - s.Nil(err) - - s.Equal(2, len(l2Head3.Transactions())) - - l1Origin, err := s.RPCClient.L2.L1OriginByID(context.Background(), new(big.Int).Add(l2Head2.Number, common.Big1)) - s.Nil(err) - s.Equal(l2Head3.Number().Uint64(), l1Origin.BlockID.Uint64()) - s.Equal(l2Head3.Hash(), l1Origin.L2BlockHash) - s.Equal(uint64(0), l1Origin.L1BlockHeight.Uint64()) - s.Equal(common.Hash{}, l1Origin.L1BlockHash) - s.Equal(false, l1Origin.EndOfBlock) - s.Equal(false, l1Origin.EndOfPreconf) - s.Equal(uint64(0), l1Origin.BatchID.Uint64()) - s.True(l1Origin.IsSoftBlock()) - - // Try to patch a soft block with batch ID 1 - s.True(s.insertSoftBlock(url, l1Head1, l2Head2.Number.Uint64()+1, 1, true, false).IsSuccess()) - l2Head4, err := s.d.rpc.L2.BlockByNumber(context.Background(), nil) - s.Nil(err) - s.Equal(3, len(l2Head4.Transactions())) - s.Equal(l2Head3.Number().Uint64(), l2Head4.Number().Uint64()) - s.NotEqual(l2Head3.Hash(), l2Head4.Hash()) - - l1Origin2, err := s.RPCClient.L2.L1OriginByID(context.Background(), new(big.Int).Add(l2Head2.Number, common.Big1)) - s.Nil(err) - s.Equal(l2Head4.Number().Uint64(), l1Origin2.BlockID.Uint64()) - s.Equal(l2Head4.Hash(), l1Origin2.L2BlockHash) - s.Equal(uint64(0), l1Origin2.L1BlockHeight.Uint64()) - s.Equal(common.Hash{}, l1Origin2.L1BlockHash) - s.Equal(true, l1Origin2.EndOfBlock) - s.Equal(false, l1Origin2.EndOfPreconf) - s.Equal(uint64(1), l1Origin2.BatchID.Uint64()) - s.True(l1Origin2.IsSoftBlock()) - - canonicalL1Origin, err := s.RPCClient.L2.HeadL1Origin(context.Background()) - s.Nil(err) - s.Equal(l2Head2.Number.Uint64(), canonicalL1Origin.BlockID.Uint64()) - - // Try to patch an ended soft block - s.False(s.insertSoftBlock(url, l1Head1, l2Head2.Number.Uint64()+1, 1, true, false).IsSuccess()) - - // Try to insert a new soft block with batch ID 0 - s.True(s.insertSoftBlock(url, l1Head1, l2Head2.Number.Uint64()+2, 0, false, false).IsSuccess()) - l2Head5, err := s.d.rpc.L2.BlockByNumber(context.Background(), nil) - s.Nil(err) - s.Equal(2, len(l2Head5.Transactions())) - - // Propose 3 valid L2 blocks - s.ProposeAndInsertEmptyBlocks(s.p, s.d.ChainSyncer().BlobSyncer()) - - l2Head6, err := s.d.rpc.L2.BlockByNumber(context.Background(), l2Head3.Number()) - s.Nil(err) - s.Equal(l2Head3.Number().Uint64(), l2Head6.Number().Uint64()) - s.Equal(1, len(l2Head6.Transactions())) - - l1Origin3, err := s.RPCClient.L2.L1OriginByID(context.Background(), l2Head6.Number()) - s.Nil(err) - s.Equal(l2Head3.Number().Uint64(), l1Origin3.BlockID.Uint64()) - s.Equal(l2Head6.Hash(), l1Origin3.L2BlockHash) - s.NotZero(l1Origin3.L1BlockHeight.Uint64()) - s.NotEmpty(l1Origin3.L1BlockHash) - s.Equal(false, l1Origin3.EndOfBlock) - s.Equal(false, l1Origin3.EndOfPreconf) - s.Nil(l1Origin3.BatchID) - s.False(l1Origin3.IsSoftBlock()) -} - -func (s *DriverTestSuite) TestInsertSoftBlocksAfterEOB() { - var ( - port = uint64(testutils.RandomPort()) - epochs = testutils.RandomHash().Big().Uint64()%10 + 5 - err error - ) - s.d.softblockServer, err = softblocks.New("*", nil, s.d.ChainSyncer().BlobSyncer(), s.RPCClient, true) - s.Nil(err) - go func() { s.NotNil(s.d.softblockServer.Start(port)) }() - defer func() { s.Nil(s.d.softblockServer.Shutdown(s.d.ctx)) }() - - url, err := url.Parse(fmt.Sprintf("http://localhost:%v", port)) - s.Nil(err) - - headL1Origin, err := s.RPCClient.L2.HeadL1Origin(context.Background()) - s.Nil(err) - - for range headL1Origin.BlockID.Uint64() + epochs + 1 { - s.ProposeAndInsertEmptyBlocks(s.p, s.d.ChainSyncer().BlobSyncer()) - } - - l1Head, err := s.d.rpc.L1.HeaderByNumber(context.Background(), nil) - s.Nil(err) - - l2Head, err := s.d.rpc.L2.HeaderByNumber(context.Background(), nil) - s.Nil(err) - - for i := range epochs { - s.True(s.insertSoftBlock(url, l1Head, l2Head.Number.Uint64()+1+i, 0, false, false).IsSuccess()) - s.True(s.insertSoftBlock(url, l1Head, l2Head.Number.Uint64()+1+i, 1, true, false).IsSuccess()) - s.False(s.insertSoftBlock(url, l1Head, l2Head.Number.Uint64()+1+i, 0, true, false).IsSuccess()) - } - s.True(s.insertSoftBlock(url, l1Head, l2Head.Number.Uint64()+1+epochs, 0, true, false).IsSuccess()) - s.False(s.insertSoftBlock(url, l1Head, l2Head.Number.Uint64()+1+epochs, 1, false, false).IsSuccess()) - s.True(s.insertSoftBlock(url, l1Head, l2Head.Number.Uint64()+2+epochs, 0, false, true).IsSuccess()) - s.False(s.insertSoftBlock(url, l1Head, l2Head.Number.Uint64()+2+epochs, 1, true, false).IsSuccess()) - - l2Head2, err := s.d.rpc.L2.HeaderByNumber(context.Background(), nil) - s.Nil(err) - - s.Equal(l2Head.Number.Uint64()+2+epochs, l2Head2.Number.Uint64()) - - l1Origin, err := s.RPCClient.L2.L1OriginByID(context.Background(), l2Head2.Number) - s.Nil(err) - - s.Equal(l2Head2.Number.Uint64(), l1Origin.BlockID.Uint64()) - s.Equal(false, l1Origin.EndOfBlock) - s.Equal(true, l1Origin.EndOfPreconf) - s.True(l1Origin.IsSoftBlock()) - - headL1Origin, err = s.RPCClient.L2.HeadL1Origin(context.Background()) - s.Nil(err) - s.Equal(l2Head.Number.Uint64(), headL1Origin.BlockID.Uint64()) - s.False(headL1Origin.IsSoftBlock()) - - s.ProposeAndInsertEmptyBlocks(s.p, s.d.ChainSyncer().BlobSyncer()) - - l2Head3, err := s.d.rpc.L2.HeaderByNumber(context.Background(), nil) - s.Nil(err) - - s.Less(l2Head3.Number.Uint64(), l2Head2.Number.Uint64()) - headL1Origin, err = s.RPCClient.L2.HeadL1Origin(context.Background()) - s.Nil(err) - s.Equal(l2Head3.Number.Uint64(), headL1Origin.BlockID.Uint64()) - s.False(headL1Origin.IsSoftBlock()) -} - -func (s *DriverTestSuite) TestInsertSoftBlocksAfterEOP() { - var ( - port = uint64(testutils.RandomPort()) - epochs = testutils.RandomHash().Big().Uint64() % 5 - err error - ) - s.d.softblockServer, err = softblocks.New("*", nil, s.d.ChainSyncer().BlobSyncer(), s.RPCClient, true) - s.Nil(err) - go func() { s.NotNil(s.d.softblockServer.Start(port)) }() - defer func() { s.Nil(s.d.softblockServer.Shutdown(s.d.ctx)) }() - - url, err := url.Parse(fmt.Sprintf("http://localhost:%v", port)) - s.Nil(err) - - headL1Origin, err := s.RPCClient.L2.HeadL1Origin(context.Background()) - s.Nil(err) - - for range headL1Origin.BlockID.Uint64() + epochs + 1 { - s.ProposeAndInsertEmptyBlocks(s.p, s.d.ChainSyncer().BlobSyncer()) - } - - l1Head, err := s.d.rpc.L1.HeaderByNumber(context.Background(), nil) - s.Nil(err) - - l2Head, err := s.d.rpc.L2.HeaderByNumber(context.Background(), nil) - s.Nil(err) - - for i := range epochs { - s.True(s.insertSoftBlock(url, l1Head, l2Head.Number.Uint64()+1, i, false, false).IsSuccess()) - - latestSafeBlock, err := s.RPCClient.L2.HeaderByNumber(context.Background(), big.NewInt(-4)) - s.Nil(err) - s.Equal(l2Head.Number.Uint64(), latestSafeBlock.Number.Uint64()) - - latestFinalizedBlock, err := s.RPCClient.L2.HeaderByNumber(context.Background(), big.NewInt(-3)) - s.Nil(err) - s.Equal(uint64(0), latestFinalizedBlock.Number.Uint64()) - } - s.True(s.insertSoftBlock(url, l1Head, l2Head.Number.Uint64()+1, epochs, false, true).IsSuccess()) - s.False(s.insertSoftBlock(url, l1Head, l2Head.Number.Uint64()+1, epochs+1, false, false).IsSuccess()) - - latestSafeBlock, err := s.RPCClient.L2.HeaderByNumber(context.Background(), big.NewInt(-4)) - s.Nil(err) - s.Equal(l2Head.Number.Uint64(), latestSafeBlock.Number.Uint64()) - - l2Head2, err := s.d.rpc.L2.HeaderByNumber(context.Background(), nil) - s.Nil(err) - - // Remove soft blocks - res, err := resty.New(). - R(). - SetBody(&softblocks.RemoveSoftBlocksRequestBody{ - NewLastBlockID: l2Head2.Number.Uint64() - 1, - }). - Delete(url.String() + "/softBlocks") - s.Nil(err) - s.True(res.IsSuccess()) - - l2Head3, err := s.d.rpc.L2.HeaderByNumber(context.Background(), nil) - s.Nil(err) - s.Equal(l2Head2.Number.Uint64()-1, l2Head3.Number.Uint64()) - - latestFinalizedBlock, err := s.RPCClient.L2.HeaderByNumber(context.Background(), big.NewInt(-3)) - s.Nil(err) - s.Equal(uint64(0), latestFinalizedBlock.Number.Uint64()) -} - func TestDriverTestSuite(t *testing.T) { suite.Run(t, new(DriverTestSuite)) } - -// insertSoftBlock inserts a soft block with the given parameters. -func (s *DriverTestSuite) insertSoftBlock( - url *url.URL, - anchoredL1Block *types.Header, - l2BlockID uint64, - batchID uint64, - endOfBlock bool, - endOfPreconf bool, -) *resty.Response { - preconferPrivKey, err := crypto.ToECDSA(common.FromHex(os.Getenv("L1_PROPOSER_PRIVATE_KEY"))) - s.Nil(err) - - preconferAddress := crypto.PubkeyToAddress(preconferPrivKey.PublicKey) - - nonce, err := s.RPCClient.L2.NonceAt(context.Background(), s.TestAddr, nil) - s.Nil(err) - - tx := types.NewTransaction( - nonce, - common.BytesToAddress(testutils.RandomBytes(32)), - common.Big0, - 100_000, - new(big.Int).SetUint64(uint64(10*params.GWei)), - []byte{}, - ) - signedTx, err := types.SignTx(tx, types.LatestSignerForChainID(s.RPCClient.L2.ChainID), s.TestAddrPrivKey) - s.Nil(err) - - // If the transaction is underpriced, we just ingore it. - err = s.RPCClient.L2.SendTransaction(context.Background(), signedTx) - if err != nil { - s.Equal("replacement transaction underpriced", err.Error()) - } - - b, err := encodeAndCompressTxList([]*types.Transaction{signedTx}) - s.Nil(err) - - var marker softblocks.TransactionBatchMarker - if endOfBlock { - marker = softblocks.BatchMarkerEOB - } else if endOfPreconf { - marker = softblocks.BatchMarkerEOP - } else { - marker = softblocks.BatchMarkerEmpty - } - - txBatch := &softblocks.TransactionBatch{ - BlockID: l2BlockID, - ID: batchID, - TransactionsList: b, - BatchMarker: marker, - Signature: "", - BlockParams: &softblocks.SoftBlockParams{ - AnchorBlockID: anchoredL1Block.Number.Uint64(), - AnchorStateRoot: anchoredL1Block.Root, - Timestamp: anchoredL1Block.Time + 12, - Coinbase: preconferAddress, - }, - } - - payload, err := rlp.EncodeToBytes(txBatch) - s.Nil(err) - s.NotEmpty(payload) - - sig, err := crypto.Sign(crypto.Keccak256(payload), preconferPrivKey) - s.Nil(err) - txBatch.Signature = common.Bytes2Hex(sig) - - // Try to propose a soft block with batch ID 0 - res, err := resty.New(). - R(). - SetBody(&softblocks.BuildSoftBlockRequestBody{ - TransactionBatch: txBatch, - }). - Post(url.String() + "/softBlocks") - s.Nil(err) - log.Info("Soft block response", "body", res.String()) - return res -} - -// compress compresses the given txList bytes using zlib. -func compress(txListBytes []byte) ([]byte, error) { - var b bytes.Buffer - w := zlib.NewWriter(&b) - defer w.Close() - - if _, err := w.Write(txListBytes); err != nil { - return nil, err - } - - if err := w.Flush(); err != nil { - return nil, err - } - - return b.Bytes(), nil -} - -// encodeAndCompressTxList encodes and compresses the given transactions list. -func encodeAndCompressTxList(txs types.Transactions) ([]byte, error) { - b, err := rlp.EncodeToBytes(txs) - if err != nil { - return nil, err - } - - return compress(b) -} diff --git a/packages/taiko-client/driver/soft_blocks/api.go b/packages/taiko-client/driver/soft_blocks/api.go deleted file mode 100644 index a51bcd7b0bc..00000000000 --- a/packages/taiko-client/driver/soft_blocks/api.go +++ /dev/null @@ -1,306 +0,0 @@ -package softblocks - -import ( - "errors" - "math/big" - "net/http" - - "github.com/ethereum/go-ethereum" - "github.com/ethereum/go-ethereum/common" - "github.com/ethereum/go-ethereum/core/types" - "github.com/ethereum/go-ethereum/crypto" - "github.com/ethereum/go-ethereum/log" - "github.com/ethereum/go-ethereum/rlp" - "github.com/labstack/echo/v4" -) - -// TransactionBatchMarker represents the status of a soft block transactions group. -type TransactionBatchMarker string - -// BatchMarker valid values. -const ( - BatchMarkerEmpty TransactionBatchMarker = "" - BatchMarkerEOB TransactionBatchMarker = "endOfBlock" - BatchMarkerEOP TransactionBatchMarker = "endOfPreconf" -) - -// SoftBlockParams represents the parameters for building a soft block. -type SoftBlockParams struct { - // @param timestamp uint64 Timestamp of the soft block - Timestamp uint64 `json:"timestamp"` - // @param coinbase string Coinbase of the soft block - Coinbase common.Address `json:"coinbase"` - - // @param anchorBlockID uint64 `_anchorBlockId` parameter of the `anchorV2` transaction in soft block - AnchorBlockID uint64 `json:"anchorBlockID"` - // @param anchorStateRoot string `_anchorStateRoot` parameter of the `anchorV2` transaction in soft block - AnchorStateRoot common.Hash `json:"anchorStateRoot"` -} - -// TransactionBatch represents a soft block group. -type TransactionBatch struct { - // @param blockId uint64 Block ID of the soft block - BlockID uint64 `json:"blockId"` - // @param batchId uint64 ID of this transaction batch - ID uint64 `json:"batchId"` - // @param transactions string zlib compressed RLP encoded bytes of a transactions list - TransactionsList []byte `json:"transactions"` - // @param batchType TransactionBatchMarker Marker of the transaction batch, - // @param either `end_of_block`, `end_of_preconf` or empty - BatchMarker TransactionBatchMarker `json:"batchType"` - // @param signature string Signature of this transaction batch - Signature string `json:"signature" rlp:"-"` - // @param blockParams SoftBlockParams Block parameters of the soft block - BlockParams *SoftBlockParams `json:"blockParams"` -} - -// ValidateSignature validates the signature of the transaction batch. -func (b *TransactionBatch) ValidateSignature() (bool, error) { - payload, err := rlp.EncodeToBytes(b) - if err != nil { - return false, err - } - - pubKey, err := crypto.SigToPub(crypto.Keccak256(payload), common.FromHex(b.Signature)) - if err != nil { - return false, err - } - - return crypto.PubkeyToAddress(*pubKey).Hex() == b.BlockParams.Coinbase.Hex(), nil -} - -// BuildSoftBlockRequestBody represents a request body when handling -// soft blocks creation requests. -type BuildSoftBlockRequestBody struct { - // @param transactionBatch TransactionBatch Transaction batch to be inserted into the soft block - TransactionBatch *TransactionBatch `json:"transactionBatch"` -} - -// CreateOrUpdateBlocksFromBatchResponseBody represents a response body when handling soft -// blocks creation requests. -type BuildSoftBlockResponseBody struct { - // @param blockHeader types.Header of the soft block - BlockHeader *types.Header `json:"blockHeader"` -} - -// BuildSoftBlock handles a soft block creation request, -// if the soft block transactions batch in request are valid, it will insert or reorg the correspoinding the soft -// block to the backend L2 execution engine and return a success response. -// -// @Summary Insert a soft block with a batch of given transactions for preconfirmation. -// @Description Insert a batch of transactions into a soft block for preconfirmation. If the batch is the -// @Description first for a block, a new soft block will be created. Otherwise, the transactions will -// @Description be appended to the existing soft block. The API will fail if: -// @Description 1) the block is not soft -// @Description 2) block-level parameters are invalid or do not match the current soft block’s parameters -// @Description 3) the batch ID is not exactly 1 greater than the previous one -// @Description 4) the last batch of the block indicates no further transactions are allowed -// @Param body body BuildSoftBlockRequestBody true "soft block creation request body" -// @Accept json -// @Produce json -// @Success 200 {object} BuildSoftBlockResponseBody -// @Router /softBlocks [post] -func (s *SoftBlockAPIServer) BuildSoftBlock(c echo.Context) error { - // Parse the request body. - reqBody := new(BuildSoftBlockRequestBody) - if err := c.Bind(reqBody); err != nil { - return s.returnError(c, http.StatusUnprocessableEntity, err) - } - if reqBody.TransactionBatch == nil { - return s.returnError(c, http.StatusBadRequest, errors.New("transactionBatch is required")) - } - - log.Info( - "New soft block building request", - "blockID", reqBody.TransactionBatch.BlockID, - "batchID", reqBody.TransactionBatch.ID, - "batchMarker", reqBody.TransactionBatch.BatchMarker, - "transactionsListBytes", len(reqBody.TransactionBatch.TransactionsList), - "signature", reqBody.TransactionBatch.Signature, - "timestamp", reqBody.TransactionBatch.BlockParams.Timestamp, - "coinbase", reqBody.TransactionBatch.BlockParams.Coinbase, - "anchorBlockID", reqBody.TransactionBatch.BlockParams.AnchorBlockID, - "anchorStateRoot", reqBody.TransactionBatch.BlockParams.AnchorStateRoot, - ) - - // Request body validation. - if reqBody.TransactionBatch.BlockParams == nil { - return s.returnError(c, http.StatusBadRequest, errors.New("blockParams is required")) - } - if reqBody.TransactionBatch.BlockParams.AnchorBlockID == 0 { - return s.returnError(c, http.StatusBadRequest, errors.New("non-zero anchorBlockID is required")) - } - if reqBody.TransactionBatch.BlockParams.AnchorStateRoot == (common.Hash{}) { - return s.returnError(c, http.StatusBadRequest, errors.New("empty anchorStateRoot")) - } - if reqBody.TransactionBatch.BlockParams.Timestamp == 0 { - return s.returnError(c, http.StatusBadRequest, errors.New("non-zero timestamp is required")) - } - if reqBody.TransactionBatch.BlockParams.Coinbase == (common.Address{}) { - return s.returnError(c, http.StatusBadRequest, errors.New("empty coinbase")) - } - - // If the `--softBlock.signatureCheck` flag is enabled, validate the signature. - if s.checkSig { - ok, err := reqBody.TransactionBatch.ValidateSignature() - if err != nil { - return c.JSON(http.StatusInternalServerError, map[string]string{"error": err.Error()}) - } - if !ok { - log.Warn( - "Invalid signature", - "signature", reqBody.TransactionBatch.Signature, - "coinbase", reqBody.TransactionBatch.BlockParams.Coinbase.Hex(), - ) - return s.returnError(c, http.StatusBadRequest, errors.New("invalid signature")) - } - } - - // Check if the L2 execution engine is syncing from L1. - progress, err := s.rpc.L2ExecutionEngineSyncProgress(c.Request().Context()) - if err != nil { - return c.JSON(http.StatusInternalServerError, map[string]string{"error": err.Error()}) - } - if progress.IsSyncing() { - return s.returnError(c, http.StatusBadRequest, errors.New("L2 execution engine is syncing")) - } - - // Check if the softblock batch or the current preconf process is ended. - l1Origin, err := s.rpc.L2.L1OriginByID( - c.Request().Context(), - new(big.Int).SetUint64(reqBody.TransactionBatch.BlockID), - ) - if err != nil && err.Error() != ethereum.NotFound.Error() { - return s.returnError(c, http.StatusInternalServerError, err) - } - if l1Origin != nil { - if l1Origin.EndOfBlock { - return s.returnError(c, http.StatusBadRequest, errors.New("soft block has already been marked as ended")) - } - if l1Origin.EndOfPreconf { - return s.returnError( - c, - http.StatusBadRequest, - errors.New("preconfirmation has already been marked as ended"), - ) - } - } - - // Insert the soft block. - header, err := s.chainSyncer.InsertSoftBlockFromTransactionsBatch( - c.Request().Context(), - reqBody.TransactionBatch.BlockID, - reqBody.TransactionBatch.ID, - s.txListDecompressor.TryDecompress( - s.rpc.L2.ChainID, - new(big.Int).SetUint64(reqBody.TransactionBatch.BlockID), - reqBody.TransactionBatch.TransactionsList, - true, - ), - reqBody.TransactionBatch.BatchMarker, - reqBody.TransactionBatch.BlockParams, - ) - if err != nil { - return s.returnError(c, http.StatusInternalServerError, err) - } - - return c.JSON(http.StatusOK, BuildSoftBlockResponseBody{BlockHeader: header}) -} - -// RemoveSoftBlocksRequestBody represents a request body when resetting the backend -// L2 execution engine soft head. -type RemoveSoftBlocksRequestBody struct { - // @param newLastBlockID uint64 New last block ID of the blockchain, it should - // @param not smaller than the canonical chain's highest block ID. - NewLastBlockID uint64 `json:"newLastBlockId"` -} - -// RemoveSoftBlocksResponseBody represents a response body when resetting the backend -// L2 execution engine soft head. -type RemoveSoftBlocksResponseBody struct { - // @param lastBlockID uint64 Current highest block ID of the blockchain (including soft blocks) - LastBlockID uint64 `json:"lastBlockId"` - // @param lastProposedBlockID uint64 Highest block ID of the cnonical chain - LastProposedBlockID uint64 `json:"lastProposedBlockID"` - // @param headsRemoved uint64 Number of soft heads removed - HeadsRemoved uint64 `json:"headsRemoved"` -} - -// RemoveSoftBlocks removes the backend L2 execution engine soft head. -// -// @Summary Remove the soft blocks beyond the specified block height. -// @Description Remove all soft blocks from the blockchain beyond the specified block height, -// @Description ensuring the latest block ID does not exceed the given height. This method will fail if -// @Description the block with an ID one greater than the specified height is not a soft block. If the -// @Description specified block height is greater than the latest soft block ID, the method will succeed -// @Description without modifying the blockchain. -// @Param body body RemoveSoftBlocksRequestBody true "soft blocks removing request body" -// @Accept json -// @Produce json -// @Success 200 {object} RemoveSoftBlocksResponseBody -// @Router /softBlocks [delete] -func (s *SoftBlockAPIServer) RemoveSoftBlocks(c echo.Context) error { - // Parse the request body. - reqBody := new(RemoveSoftBlocksRequestBody) - if err := c.Bind(reqBody); err != nil { - return s.returnError(c, http.StatusUnprocessableEntity, err) - } - - // Request body validation. - canonicalHeadL1Origin, err := s.rpc.L2.HeadL1Origin(c.Request().Context()) - if err != nil { - return s.returnError(c, http.StatusInternalServerError, err) - } - - currentHead, err := s.rpc.L2.HeaderByNumber(c.Request().Context(), nil) - if err != nil { - return s.returnError(c, http.StatusInternalServerError, err) - } - - log.Info( - "New soft block removing request", - "newLastBlockId", reqBody.NewLastBlockID, - "canonicalHead", canonicalHeadL1Origin.BlockID.Uint64(), - "currentHead", currentHead.Number.Uint64(), - ) - - if reqBody.NewLastBlockID < canonicalHeadL1Origin.BlockID.Uint64() { - return s.returnError( - c, - http.StatusBadRequest, - errors.New("newLastBlockId must not be smaller than the canonical chain's highest block ID"), - ) - } - - if err := s.chainSyncer.RemoveSoftBlocks(c.Request().Context(), reqBody.NewLastBlockID); err != nil { - return s.returnError(c, http.StatusBadRequest, err) - } - - newHead, err := s.rpc.L2.HeaderByNumber(c.Request().Context(), nil) - if err != nil { - return s.returnError(c, http.StatusInternalServerError, err) - } - - return c.JSON(http.StatusOK, RemoveSoftBlocksResponseBody{ - LastBlockID: newHead.Number.Uint64(), - LastProposedBlockID: canonicalHeadL1Origin.BlockID.Uint64(), - HeadsRemoved: currentHead.Number.Uint64() - newHead.Number.Uint64(), - }) -} - -// HealthCheck is the endpoints for probes. -// -// @Summary Get current server health status -// @ID health-check -// @Accept json -// @Produce json -// @Success 200 {object} string -// @Router /healthz [get] -func (s *SoftBlockAPIServer) HealthCheck(c echo.Context) error { - return c.NoContent(http.StatusOK) -} - -// returnError is a helper function to return an error response. -func (s *SoftBlockAPIServer) returnError(c echo.Context, statusCode int, err error) error { - return c.JSON(statusCode, map[string]string{"error": err.Error()}) -} diff --git a/packages/taiko-client/driver/soft_blocks/server.go b/packages/taiko-client/driver/soft_blocks/server.go deleted file mode 100644 index e27cac912fd..00000000000 --- a/packages/taiko-client/driver/soft_blocks/server.go +++ /dev/null @@ -1,130 +0,0 @@ -package softblocks - -import ( - "context" - "fmt" - "os" - - "github.com/ethereum/go-ethereum/core/types" - echojwt "github.com/labstack/echo-jwt/v4" - "github.com/labstack/echo/v4" - "github.com/labstack/echo/v4/middleware" - - txListDecompressor "github.com/taikoxyz/taiko-mono/packages/taiko-client/driver/txlist_decompressor" - "github.com/taikoxyz/taiko-mono/packages/taiko-client/pkg/rpc" -) - -// softBlockChainSyncer is an interface for soft block chain syncer. -type softBlockChainSyncer interface { - InsertSoftBlockFromTransactionsBatch( - ctx context.Context, - blockID uint64, - batchID uint64, - txListBytes []byte, - batchMarker TransactionBatchMarker, - softBlockParams *SoftBlockParams, - ) (*types.Header, error) - RemoveSoftBlocks(ctx context.Context, newLastBlockID uint64) error -} - -// @title Taiko Soft Block Server API -// @version 1.0 -// @termsOfService http://swagger.io/terms/ - -// @contact.name API Support -// @contact.url https://community.taiko.xyz/ -// @contact.email info@taiko.xyz - -// @license.name MIT -// @license.url https://github.com/taikoxyz/taiko-mono/blob/main/LICENSE.md -// SoftBlockAPIServer represents a soft blcok server instance. -type SoftBlockAPIServer struct { - echo *echo.Echo - chainSyncer softBlockChainSyncer - rpc *rpc.Client - txListDecompressor *txListDecompressor.TxListDecompressor - checkSig bool -} - -// New creates a new soft blcok server instance, and starts the server. -func New( - cors string, - jwtSecret []byte, - chainSyncer softBlockChainSyncer, - cli *rpc.Client, - checkSig bool, -) (*SoftBlockAPIServer, error) { - protocolConfigs, err := rpc.GetProtocolConfigs(cli.TaikoL1, nil) - if err != nil { - return nil, fmt.Errorf("failed to fetch protocol configs: %w", err) - } - - server := &SoftBlockAPIServer{ - echo: echo.New(), - chainSyncer: chainSyncer, - txListDecompressor: txListDecompressor.NewTxListDecompressor( - uint64(protocolConfigs.BlockMaxGasLimit), - rpc.BlockMaxTxListBytes, - cli.L2.ChainID, - ), - rpc: cli, - checkSig: checkSig, - } - - server.echo.HideBanner = true - server.configureMiddleware([]string{cors}) - server.configureRoutes() - if jwtSecret != nil { - server.echo.Use(echojwt.JWT(jwtSecret)) - } - - return server, nil -} - -// LogSkipper implements the `middleware.Skipper` interface. -func LogSkipper(c echo.Context) bool { - switch c.Request().URL.Path { - case "/healthz": - return true - default: - return true - } -} - -// configureMiddleware configures the server middlewares. -func (s *SoftBlockAPIServer) configureMiddleware(corsOrigins []string) { - s.echo.Use(middleware.RequestID()) - - s.echo.Use(middleware.LoggerWithConfig(middleware.LoggerConfig{ - Skipper: LogSkipper, - Format: `{"time":"${time_rfc3339_nano}","level":"INFO","message":{"id":"${id}","remote_ip":"${remote_ip}",` + - `"host":"${host}","method":"${method}","uri":"${uri}","user_agent":"${user_agent}",` + - `"response_status":${status},"error":"${error}","latency":${latency},"latency_human":"${latency_human}",` + - `"bytes_in":${bytes_in},"bytes_out":${bytes_out}}}` + "\n", - Output: os.Stdout, - })) - - // Add CORS middleware - s.echo.Use(middleware.CORSWithConfig(middleware.CORSConfig{ - AllowOrigins: corsOrigins, - AllowCredentials: true, - })) -} - -// Start starts the HTTP server. -func (s *SoftBlockAPIServer) Start(port uint64) error { - return s.echo.Start(fmt.Sprintf(":%v", port)) -} - -// Shutdown shuts down the HTTP server. -func (s *SoftBlockAPIServer) Shutdown(ctx context.Context) error { - return s.echo.Shutdown(ctx) -} - -// configureRoutes contains all routes which will be used by prover server. -func (s *SoftBlockAPIServer) configureRoutes() { - s.echo.GET("/", s.HealthCheck) - s.echo.GET("/healthz", s.HealthCheck) - s.echo.POST("/softBlocks", s.BuildSoftBlock) - s.echo.DELETE("/softBlocks", s.RemoveSoftBlocks) -} diff --git a/packages/taiko-client/driver/soft_blocks/server_test.go b/packages/taiko-client/driver/soft_blocks/server_test.go deleted file mode 100644 index c1aa66d1777..00000000000 --- a/packages/taiko-client/driver/soft_blocks/server_test.go +++ /dev/null @@ -1,36 +0,0 @@ -package softblocks - -import ( - "context" - "testing" - - "github.com/ethereum/go-ethereum/log" - "github.com/stretchr/testify/suite" - - "github.com/taikoxyz/taiko-mono/packages/taiko-client/internal/testutils" -) - -type SoftBlockAPIServerTestSuite struct { - testutils.ClientTestSuite - s *SoftBlockAPIServer -} - -func (s *SoftBlockAPIServerTestSuite) SetupTest() { - s.ClientTestSuite.SetupTest() - server, err := New("*", nil, nil, s.RPCClient, true) - s.Nil(err) - s.s = server - go func() { - s.NotPanics(func() { - log.Error("Start test soft block server", "error", s.s.Start(uint64(testutils.RandomPort()))) - }) - }() -} - -func (s *SoftBlockAPIServerTestSuite) TestShutdown() { - s.Nil(s.s.Shutdown(context.Background())) -} - -func TestSoftBlockAPIServerTestSuite(t *testing.T) { - suite.Run(t, new(SoftBlockAPIServerTestSuite)) -} diff --git a/packages/taiko-client/driver/state/l1_current.go b/packages/taiko-client/driver/state/l1_current.go index 01f038387d4..597635b9710 100644 --- a/packages/taiko-client/driver/state/l1_current.go +++ b/packages/taiko-client/driver/state/l1_current.go @@ -3,6 +3,7 @@ package state import ( "context" "errors" + "fmt" "math/big" "github.com/taikoxyz/taiko-mono/packages/taiko-client/bindings" @@ -38,6 +39,7 @@ func (s *State) ResetL1Current(ctx context.Context, blockID *big.Int) error { // If blockID is zero, reset to genesis L1 height. if blockID.Cmp(common.Big0) == 0 { + log.Info("Reset L1 current cursor to genesis L1 height", "blockID", blockID) l1Current, err := s.rpc.L1.HeaderByNumber(ctx, s.GenesisL1Height) if err != nil { return err @@ -51,17 +53,12 @@ func (s *State) ResetL1Current(ctx context.Context, blockID *big.Int) error { blockInfo bindings.TaikoDataBlockV2 err error ) - if s.IsOnTake(blockID) { - blockInfo, err = s.rpc.GetL2BlockInfoV2(ctx, blockID) - } else { - blockInfo, err = s.rpc.GetL2BlockInfo(ctx, blockID) - } - if err != nil { - return err + if blockInfo, err = s.rpc.GetL2BlockInfoV2(ctx, blockID); err != nil { + return fmt.Errorf("failed to get L2 block (%d) info from TaikoL1 contract: %w", blockID, err) } l1Current, err := s.rpc.L1.HeaderByNumber(ctx, new(big.Int).SetUint64(blockInfo.ProposedIn)) if err != nil { - return err + return fmt.Errorf("failed to fetch L1 header by number (%d): %w", blockID, err) } s.SetL1Current(l1Current) diff --git a/packages/taiko-client/driver/txlist_fetcher/blob.go b/packages/taiko-client/driver/txlist_fetcher/blob.go index 922e1975b86..ed45db6e653 100644 --- a/packages/taiko-client/driver/txlist_fetcher/blob.go +++ b/packages/taiko-client/driver/txlist_fetcher/blob.go @@ -3,6 +3,8 @@ package txlistdecoder import ( "context" "crypto/sha256" + "fmt" + "math/big" "github.com/ethereum-optimism/optimism/op-service/eth" "github.com/ethereum/go-ethereum/common" @@ -62,11 +64,27 @@ func (d *BlobFetcher) Fetch( } if meta.GetBlobTxListLength() == 0 { - return bytes[meta.GetBlobTxListOffset():], nil + return bytes, nil } - return bytes[meta.GetBlobTxListOffset() : meta.GetBlobTxListOffset()+meta.GetBlobTxListLength()], nil + + b, err := sliceTxList(meta.GetBlockID(), bytes, meta.GetBlobTxListOffset(), meta.GetBlobTxListLength()) + if err != nil { + log.Warn("Invalid txlist offset and size in metadata", "blockID", meta.GetBlockID(), "err", err) + return []byte{}, nil + } + return b, nil } } return nil, pkg.ErrSidecarNotFound } + +// sliceTxList returns the sliced txList bytes from the given offset and length. +func sliceTxList(id *big.Int, b []byte, offset, length uint32) ([]byte, error) { + if offset+length > uint32(len(b)) { + return nil, fmt.Errorf( + "invalid txlist offset and size in metadata (%d): offset=%d, size=%d, blobSize=%d", id, offset, length, len(b), + ) + } + return b[offset : offset+length], nil +} diff --git a/packages/taiko-client/driver/txlist_fetcher/calldata.go b/packages/taiko-client/driver/txlist_fetcher/calldata.go index 7beee95e99b..9f8de41548e 100644 --- a/packages/taiko-client/driver/txlist_fetcher/calldata.go +++ b/packages/taiko-client/driver/txlist_fetcher/calldata.go @@ -52,5 +52,9 @@ func (d *CalldataFetcher) Fetch( return iter.Event.TxList, nil } + if iter.Error() != nil { + return nil, fmt.Errorf("failed to fetch calldata for block %d: %w", meta.GetBlockID(), iter.Error()) + } + return nil, fmt.Errorf("calldata for block %d not found", meta.GetBlockID()) } diff --git a/packages/taiko-client/integration_test/hive_test.go b/packages/taiko-client/integration_test/hive_test.go index 8e6a3a07cc0..24400119a7d 100644 --- a/packages/taiko-client/integration_test/hive_test.go +++ b/packages/taiko-client/integration_test/hive_test.go @@ -80,7 +80,6 @@ func testBlobAPI(t *testing.T, pattern string, clients []string) { handler, err := hivesim.NewHiveFramework(&hivesim.HiveConfig{ BuildOutput: false, ContainerOutput: true, - DockerPull: false, BaseDir: os.Getenv("HIVE_DIR"), SimPattern: "taiko", SimTestPattern: pattern, diff --git a/packages/taiko-client/internal/docker/nodes/docker-compose.yml b/packages/taiko-client/internal/docker/nodes/docker-compose.yml index 3da01faf1c4..944f857cad5 100644 --- a/packages/taiko-client/internal/docker/nodes/docker-compose.yml +++ b/packages/taiko-client/internal/docker/nodes/docker-compose.yml @@ -16,7 +16,7 @@ services: l2_geth: container_name: l2_geth - image: us-docker.pkg.dev/evmchain/images/taiko-geth:softblock + image: us-docker.pkg.dev/evmchain/images/taiko-geth:taiko restart: unless-stopped pull_policy: always volumes: diff --git a/packages/taiko-client/internal/version/version.go b/packages/taiko-client/internal/version/version.go index d3fffe26dd0..d13d664a0d1 100644 --- a/packages/taiko-client/internal/version/version.go +++ b/packages/taiko-client/internal/version/version.go @@ -1,7 +1,7 @@ package version // Version info. -const Version = "0.42.1" // x-release-please-version +const Version = "0.43.1" // x-release-please-version var meta = "dev" diff --git a/packages/taiko-client/package.json b/packages/taiko-client/package.json index 6d992d5a88d..93566392883 100644 --- a/packages/taiko-client/package.json +++ b/packages/taiko-client/package.json @@ -1,5 +1,5 @@ { "name": "taiko-client", - "version": "0.42.1", + "version": "0.43.1", "private": true } diff --git a/packages/taiko-client/pkg/chain_iterator/block_batch_iterator.go b/packages/taiko-client/pkg/chain_iterator/block_batch_iterator.go index 56242c39d2b..c531cb77fc7 100644 --- a/packages/taiko-client/pkg/chain_iterator/block_batch_iterator.go +++ b/packages/taiko-client/pkg/chain_iterator/block_batch_iterator.go @@ -4,7 +4,6 @@ import ( "context" "errors" "fmt" - "io" "math/big" "time" @@ -20,9 +19,11 @@ const ( DefaultBlocksReadPerEpoch = 1000 DefaultRetryInterval = 12 * time.Second DefaultBlockConfirmations = 0 + BackOffMaxRetries = 5 ) var ( + errEOF = errors.New("end of blockBatchIterator batch") errContinue = errors.New("continue") ) @@ -143,10 +144,17 @@ func (i *BlockBatchIterator) Iter() error { break } if err := i.iter(); err != nil { - if errors.Is(err, io.EOF) { + if errors.Is(err, errEOF) { + log.Debug( + "Block batch iterator finished", + "start", i.startHeight, + "end", i.endHeight, + "current", i.current.Number, + ) break } if errors.Is(err, errContinue) { + log.Debug("Block batch iterator continues", "current", i.current.Number) continue } log.Error("Block batch iterator callback error", "error", err) @@ -156,7 +164,13 @@ func (i *BlockBatchIterator) Iter() error { return nil } - if err := backoff.Retry(iterOp, backoff.WithContext(backoff.NewConstantBackOff(i.retryInterval), i.ctx)); err != nil { + if err := backoff.Retry( + iterOp, + backoff.WithMaxRetries( + backoff.WithContext(backoff.NewConstantBackOff(i.retryInterval), i.ctx), + BackOffMaxRetries, + ), + ); err != nil { return err } @@ -198,7 +212,7 @@ func (i *BlockBatchIterator) iter() (err error) { } if i.current.Number.Uint64() >= destHeight { - return io.EOF + return errEOF } endHeight = i.current.Number.Uint64() + i.blocksReadPerEpoch @@ -212,12 +226,14 @@ func (i *BlockBatchIterator) iter() (err error) { return err } + log.Debug("Iterating blocks", "start", i.current.Number, "end", endHeader.Number) + if err := i.onBlocks(i.ctx, i.current, endHeader, i.updateCurrent, i.end); err != nil { return err } if i.isEnd { - return io.EOF + return errEOF } i.current = endHeader @@ -226,7 +242,7 @@ func (i *BlockBatchIterator) iter() (err error) { return errContinue } - return io.EOF + return errEOF } // updateCurrent updates the iterator's current cursor. @@ -287,6 +303,8 @@ func (i *BlockBatchIterator) rewindOnReorgDetected() error { return err } + log.Debug("Rewind on reorg detected", "oldCurrent", i.current.Number, "newCurrent", current.Number) + i.current = current return nil } diff --git a/packages/taiko-client/pkg/chain_iterator/block_batch_iterator_test.go b/packages/taiko-client/pkg/chain_iterator/block_batch_iterator_test.go index 429505c4bd1..5886dab291e 100644 --- a/packages/taiko-client/pkg/chain_iterator/block_batch_iterator_test.go +++ b/packages/taiko-client/pkg/chain_iterator/block_batch_iterator_test.go @@ -2,7 +2,6 @@ package chainiterator import ( "context" - "io" "math/big" "testing" "time" @@ -110,7 +109,7 @@ func (s *BlockBatchIteratorTestSuite) TestIterWithLessThanConfirmations() { }) s.Nil(err) - s.Equal(io.EOF, iter.iter()) + s.Equal(errEOF, iter.iter()) s.Equal(headHeight, lastEnd) } diff --git a/packages/taiko-client/pkg/chain_iterator/event_iterator/block_proposed_iterator.go b/packages/taiko-client/pkg/chain_iterator/event_iterator/block_proposed_iterator.go index 67fc0fea23d..4d051780fc8 100644 --- a/packages/taiko-client/pkg/chain_iterator/event_iterator/block_proposed_iterator.go +++ b/packages/taiko-client/pkg/chain_iterator/event_iterator/block_proposed_iterator.go @@ -3,10 +3,12 @@ package eventiterator import ( "context" "errors" + "fmt" "math/big" "github.com/ethereum/go-ethereum/accounts/abi/bind" "github.com/ethereum/go-ethereum/core/types" + "github.com/ethereum/go-ethereum/log" "github.com/taikoxyz/taiko-mono/packages/taiko-client/bindings" "github.com/taikoxyz/taiko-mono/packages/taiko-client/bindings/metadata" @@ -109,17 +111,12 @@ func assembleBlockProposedIteratorCallback( updateCurrentFunc chainIterator.UpdateCurrentFunc, endFunc chainIterator.EndIterFunc, ) error { - endHeight := end.Number.Uint64() - - iter, err := taikoL1.FilterBlockProposed( - &bind.FilterOpts{Start: start.Number.Uint64(), End: &endHeight, Context: ctx}, - filterQuery, - nil, + var ( + endHeight = end.Number.Uint64() + lastBlockID uint64 ) - if err != nil { - return err - } - defer iter.Close() + + log.Debug("Iterating BlockProposed events", "start", start.Number, "end", endHeight) iterOntake, err := taikoL1.FilterBlockProposedV2( &bind.FilterOpts{Start: start.Number.Uint64(), End: &endHeight, Context: ctx}, @@ -130,34 +127,31 @@ func assembleBlockProposedIteratorCallback( } defer iterOntake.Close() - for iter.Next() { - event := iter.Event - - if err := callback(ctx, metadata.NewTaikoDataBlockMetadataLegacy(event), eventIter.end); err != nil { - return err - } - - if eventIter.isEnd { - endFunc() - return nil - } - - current, err := client.HeaderByHash(ctx, event.Raw.BlockHash) - if err != nil { - return err - } - - updateCurrentFunc(current) - } - for iterOntake.Next() { event := iterOntake.Event + log.Debug("Processing BlockProposedV2 event", "block", event.BlockId, "l1BlockHeight", event.Raw.BlockNumber) + + if lastBlockID != 0 && event.BlockId.Uint64() != lastBlockID+1 { + log.Warn( + "BlockProposedV2 event is not continuous, rescan the L1 chain", + "fromL1Block", start.Number, + "toL1Block", endHeight, + "lastScannedBlockID", lastBlockID, + "currentScannedBlockID", event.BlockId.Uint64(), + ) + return fmt.Errorf( + "BlockProposedV2 event is not continuous, lastScannedBlockID: %d, currentScannedBlockID: %d", + lastBlockID, event.BlockId.Uint64(), + ) + } if err := callback(ctx, metadata.NewTaikoDataBlockMetadataOntake(event), eventIter.end); err != nil { + log.Warn("Error while processing BlockProposedV2 events, keep retrying", "error", err) return err } if eventIter.isEnd { + log.Debug("BlockProposedIterator is ended", "start", start.Number, "end", endHeight) endFunc() return nil } @@ -167,9 +161,18 @@ func assembleBlockProposedIteratorCallback( return err } + log.Debug("Updating current block cursor for processing BlockProposedV2 events", "block", current.Number) + + lastBlockID = event.BlockId.Uint64() + updateCurrentFunc(current) } + if err := iterOntake.Error(); err != nil { + log.Error("Error while iterating BlockProposedV2 events", "error", err) + return err + } + return nil } } diff --git a/packages/taiko-client/pkg/rpc/methods.go b/packages/taiko-client/pkg/rpc/methods.go index 93e04c70bf4..2c139a88461 100644 --- a/packages/taiko-client/pkg/rpc/methods.go +++ b/packages/taiko-client/pkg/rpc/methods.go @@ -76,6 +76,9 @@ func (c *Client) ensureGenesisMatched(ctx context.Context) error { if iter.Next() { l2GenesisHash = iter.Event.BlockHash } + if iter.Error() != nil { + return iter.Error() + } } else { // Fetch the genesis `BlockVerified` event. iter, err := c.TaikoL1.FilterBlockVerified(filterOpts, []*big.Int{common.Big0}, nil) @@ -86,6 +89,9 @@ func (c *Client) ensureGenesisMatched(ctx context.Context) error { if iter.Next() { l2GenesisHash = iter.Event.BlockHash } + if iter.Error() != nil { + return iter.Error() + } } log.Debug("Genesis hash", "node", nodeGenesis.Hash(), "TaikoL1", common.BytesToHash(l2GenesisHash[:])) @@ -334,50 +340,23 @@ func (c *Client) GetPoolContent( ctxWithTimeout, cancel := CtxWithTimeoutOrDefault(ctx, defaultTimeout) defer cancel() - // Get the latest L2 block header at first. - l2Head, err := c.L2.HeaderByNumber(ctx, nil) + l1Head, err := c.L1.HeaderByNumber(ctx, nil) if err != nil { return nil, err } - l1Origin, err := c.L2.L1OriginByID(ctx, l2Head.Number) - if err != nil && err.Error() != ethereum.NotFound.Error() { - return nil, err - } - - var ( - L1HeadNum *big.Int - L2HeadNum *big.Int - timestamp = uint64(time.Now().Unix()) - ) - - if l1Origin != nil && l1Origin.IsSoftBlock() && !l1Origin.EndOfPreconf && !l1Origin.EndOfBlock { - // Check if this is an unfinished soft block, if not, we will use the latest L1 / L2 block number from the L1Origin. - // Otherwise, we will use the L1 / L2 block number in L1Origin. - L1HeadNum = l1Origin.L1BlockHeight - L2HeadNum = new(big.Int).Sub(l1Origin.BlockID, common.Big1) - } - - l1Head, err := c.L1.HeaderByNumber(ctx, L1HeadNum) + l2Head, err := c.L2.HeaderByNumber(ctx, nil) if err != nil { return nil, err } - if L2HeadNum != nil { - timestamp = l2Head.Time - l2Head, err = c.L2.HeaderByNumber(ctx, L2HeadNum) - if err != nil { - return nil, err - } - } - baseFee, err := c.CalculateBaseFee( ctx, l2Head, l1Head.Number, - true, + chainConfig.IsOntake(new(big.Int).Add(l2Head.Number, common.Big1)), &chainConfig.ProtocolConfigs.BaseFeeConfig, - timestamp, + uint64(time.Now().Unix()), ) if err != nil { return nil, err @@ -674,10 +653,12 @@ func (c *Client) checkSyncedL1SnippetFromAnchor( log.Debug("Check synced L1 snippet from anchor", "blockID", blockID, "l1Height", l1Height) block, err := c.L2.BlockByNumber(ctx, blockID) if err != nil { + log.Error("Failed to fetch L2 block", "blockID", blockID, "error", err) return false, err } parent, err := c.L2.BlockByHash(ctx, block.ParentHash()) if err != nil { + log.Error("Failed to fetch L2 parent block", "blockID", blockID, "parentHash", block.ParentHash(), "error", err) return false, err } @@ -685,6 +666,7 @@ func (c *Client) checkSyncedL1SnippetFromAnchor( block.Transactions()[0], ) if err != nil { + log.Error("Failed to parse L1 snippet from anchor transaction", "blockID", blockID, "error", err) return false, err } @@ -700,6 +682,7 @@ func (c *Client) checkSyncedL1SnippetFromAnchor( l1Header, err := c.L1.HeaderByNumber(ctx, new(big.Int).SetUint64(l1HeightInAnchor)) if err != nil { + log.Error("Failed to fetch L1 header", "blockID", blockID, "error", err) return false, err } @@ -727,7 +710,7 @@ func (c *Client) getSyncedL1SnippetFromAnchor( ) { method, err := encoding.TaikoL2ABI.MethodById(tx.Data()) if err != nil { - return common.Hash{}, 0, 0, err + return common.Hash{}, 0, 0, fmt.Errorf("failed to get TaikoL2.Anchor method by ID: %w", err) } var ok bool @@ -736,7 +719,7 @@ func (c *Client) getSyncedL1SnippetFromAnchor( args := map[string]interface{}{} if err := method.Inputs.UnpackIntoMap(args, tx.Data()[4:]); err != nil { - return common.Hash{}, 0, 0, err + return common.Hash{}, 0, 0, fmt.Errorf("failed to unpack anchor transaction calldata: %w", err) } l1StateRoot, ok = args["_l1StateRoot"].([32]byte) @@ -861,6 +844,9 @@ func (c *Client) GetTaikoDataSlotBByNumber(ctx context.Context, number uint64) ( for iter.Next() { return &iter.Event.SlotB, nil } + if iter.Error() != nil { + return nil, fmt.Errorf("failed to get state variables by block number %d: %w", number, iter.Error()) + } return nil, fmt.Errorf("failed to get state variables by block number %d", number) } diff --git a/packages/taiko-client/proposer/proposer.go b/packages/taiko-client/proposer/proposer.go index 7c147e52250..20aaf9d2270 100644 --- a/packages/taiko-client/proposer/proposer.go +++ b/packages/taiko-client/proposer/proposer.go @@ -25,6 +25,7 @@ import ( "github.com/taikoxyz/taiko-mono/packages/taiko-client/bindings" "github.com/taikoxyz/taiko-mono/packages/taiko-client/bindings/encoding" "github.com/taikoxyz/taiko-mono/packages/taiko-client/internal/metrics" + "github.com/taikoxyz/taiko-mono/packages/taiko-client/internal/version" "github.com/taikoxyz/taiko-mono/packages/taiko-client/pkg/config" "github.com/taikoxyz/taiko-mono/packages/taiko-client/pkg/rpc" "github.com/taikoxyz/taiko-mono/packages/taiko-client/pkg/utils" @@ -77,6 +78,8 @@ func (p *Proposer) InitFromConfig( txMgr *txmgr.SimpleTxManager, privateTxMgr *txmgr.SimpleTxManager, ) (err error) { + log.Info("Initializing proposer", "version", version.CommitVersion()) + p.proposerAddress = crypto.PubkeyToAddress(cfg.L1ProposerPrivKey.PublicKey) p.ctx = ctx p.Config = cfg diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index aa4a7afd155..8fa78e5b4b0 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -443,14 +443,14 @@ importers: specifier: github:taikoxyz/p256-verifier#v0.1.0 version: p256-verifier#v0.1.0@https://codeload.github.com/taikoxyz/p256-verifier/tar.gz/6ef45b117642786b08a37b4c37c6a6ce151166da risc0-ethereum: - specifier: github:risc0/risc0-ethereum#v1.1.2 - version: risc0-ethereum#v1.1.2@https://codeload.github.com/risc0/risc0-ethereum/tar.gz/b8a14213d92fff07dacda993804e7edb7946ca58 + specifier: github:risc0/risc0-ethereum#v1.2.0 + version: risc0-ethereum#v1.2.0@https://codeload.github.com/risc0/risc0-ethereum/tar.gz/3c1fd2a859e40ea009a580aac294191196968c60 solady: specifier: github:Vectorized/solady#v0.0.231 version: https://codeload.github.com/Vectorized/solady/tar.gz/a12a2575c899a328c1bafdada632dabbff27cf6b sp1-contracts: - specifier: github:succinctlabs/sp1-contracts#v3.0.0 - version: sp1-contracts#v3.0.0@https://codeload.github.com/succinctlabs/sp1-contracts/tar.gz/1c4acaeab86789995ae5c6baced66f81e4a57f4d + specifier: github:succinctlabs/sp1-contracts#v4.0.0-rc.3 + version: sp1-contracts#v4.0.0-rc.3@https://codeload.github.com/succinctlabs/sp1-contracts/tar.gz/0885c34b525708ed5f7e87a3d7b20c42564b4c00 devDependencies: '@types/node': specifier: ^20.11.30 @@ -1277,8 +1277,8 @@ packages: resolution: {integrity: sha512-BaDeOonYvhdKw+JoMVkAixAAJzG2jVPIwWoKBPdYuY9b452e2rPuI9QPYh3KpofZ3pW2akOmwZLOiOsHMiqRAg==} engines: {node: '>=6.9.0'} - '@babel/helper-builder-binary-assignment-operator-visitor@7.24.7': - resolution: {integrity: sha512-xZeCVVdwb4MsDBkkyZ64tReWYrLRHlMN72vP7Bdm3OUOuyFZExhsHUUnuWnm2/XOlAJzR0LfPpB56WXZn0X/lA==} + '@babel/helper-annotate-as-pure@7.24.7': + resolution: {integrity: sha512-BaDeOonYvhdKw+JoMVkAixAAJzG2jVPIwWoKBPdYuY9b452e2rPuI9QPYh3KpofZ3pW2akOmwZLOiOsHMiqRAg==} engines: {node: '>=6.9.0'} '@babel/helper-compilation-targets@7.25.2': @@ -1376,8 +1376,8 @@ packages: resolution: {integrity: sha512-Y4OZ+ytlatR8AI+8KZfKuL5urKp7qey08ha31L8b3BwewJAoJamTzyvxPR/5D+KkdJCGPq/+8TukHBlY10FX9A==} engines: {node: '>=6.9.0'} - '@babel/helper-validator-identifier@7.24.7': - resolution: {integrity: sha512-rR+PBcQ1SMQDDyF6X0wxtG8QyLCgUB0eRAGguqRLfkCA87l7yAP7ehq8SNj96OOGTO8OBV70KhuFYcIkHXOg0w==} + '@babel/helper-string-parser@7.24.8': + resolution: {integrity: sha512-pO9KhhRcuUyGnJWwyEgnRJTSIZHiT+vMD0kPeD+so0l7mxkMT19g3pjY9GTnHySck/hDzq+dtW/4VgnMkippsQ==} engines: {node: '>=6.9.0'} '@babel/helper-validator-identifier@7.24.7': @@ -1400,8 +1400,8 @@ packages: resolution: {integrity: sha512-acGdbYSfp2WheJoJm/EBBBLh/ID8KDc64ISZ9DYtBmC8/Q204PZJLHyzeB5qMzJ5trcOkybd78M4x2KWsUq++A==} engines: {node: '>=6.9.0'} - '@babel/highlight@7.24.7': - resolution: {integrity: sha512-EStJpq4OuY8xYfhGVXngigBJRWxftKX9ksiGDnmlY3o7B/V7KIAc9X4oiK87uPJSc/vs5L869bem5fhZa8caZw==} + '@babel/helper-validator-option@7.24.8': + resolution: {integrity: sha512-xb8t9tD1MHLungh/AIoWYN+gVHaB9kwlu8gffXGSt3FFEIT7RjS+xWbc2vUD1UTZdIpKj/ab3rdqJ7ufngyi2Q==} engines: {node: '>=6.9.0'} '@babel/highlight@7.24.7': @@ -3081,6 +3081,10 @@ packages: resolution: {integrity: sha512-6EwiSjwWYP7pTckG6I5eyFANjPhmPjUX9JRLUSfNPC7FX7zK9gyZAfUEaECL6ALTpGX5AjnBq3C9XmVWPitNpw==} deprecated: Use @eslint/object-schema instead + '@humanwhocodes/object-schema@2.0.2': + resolution: {integrity: sha512-6EwiSjwWYP7pTckG6I5eyFANjPhmPjUX9JRLUSfNPC7FX7zK9gyZAfUEaECL6ALTpGX5AjnBq3C9XmVWPitNpw==} + deprecated: Use @eslint/object-schema instead + '@img/sharp-darwin-arm64@0.33.4': resolution: {integrity: sha512-p0suNqXufJs9t3RqLBO6vvrgr5OhgbWp76s5gTRvdmxmuv9E1rcaqGUsl3l4mKVmXPkTkTErXediAui4x+8PSA==} engines: {glibc: '>=2.26', node: ^18.17.0 || ^20.3.0 || >=21.0.0, npm: '>=9.6.5', pnpm: '>=7.1.0', yarn: '>=3.2.0'} @@ -3581,8 +3585,8 @@ packages: resolution: {integrity: sha512-doST0+aB7/3dGK9+U5y3mtF3jq85KGbke1QiH0KE1F5mGQ9y56mFebTeu2D9FNOm+OT6UHb8Ss8vbSnpGjeLNw==} engines: {node: '>=16.0.0', npm: '>=7.0.0'} - '@multiformats/multiaddr@12.3.0': - resolution: {integrity: sha512-JQ8Gc/jgucqqvEaDTFN/AvxlYDHEE7lgEWLMYW7hKZkWggER+GvG/tVxUgUxIP8M0vFpvEHKKHE0lKzyMsgi8Q==} + '@multiformats/multiaddr@12.2.1': + resolution: {integrity: sha512-UwjoArBbv64FlaetV4DDwh+PUMfzXUBltxQwdh+uTYnGFzVa8ZfJsn1vt1RJlJ6+Xtrm3RMekF/B+K338i2L5Q==} '@noble/curves@1.2.0': resolution: {integrity: sha512-oYclrNgRaM9SsBUBVbb8M6DTV7ZHRTKugureoYEncY5c65HOmRzvSiTE3y5CYaPYJA/GVkrhXEoF0M3Ya9PMnw==} @@ -3596,6 +3600,9 @@ packages: '@noble/curves@1.4.0': resolution: {integrity: sha512-p+4cb332SFCrReJkCYe8Xzm0OWi4Jji5jVdIZRL/PmacmDkFNw6MrrV+gGpiPxLHbV+zKFRywUWbaseT+tZRXg==} + '@noble/curves@1.4.0': + resolution: {integrity: sha512-p+4cb332SFCrReJkCYe8Xzm0OWi4Jji5jVdIZRL/PmacmDkFNw6MrrV+gGpiPxLHbV+zKFRywUWbaseT+tZRXg==} + '@noble/hashes@1.2.0': resolution: {integrity: sha512-FZfhjEDbT5GRswV3C6uvLPHMiVD6lQBmpoX5+eSiPaMTXte/IKqI5dykDxzZB/WBeK/CDuQRBWarPdi3FNY2zQ==} @@ -4076,8 +4083,8 @@ packages: cpu: [arm] os: [android] - '@rollup/rollup-android-arm-eabi@4.18.0': - resolution: {integrity: sha512-Tya6xypR10giZV1XzxmH5wr25VcZSncG0pZIjfePT0OVBvqNEurzValetGNarVrGiq66EBVAFn15iYX4w6FKgQ==} + '@rollup/rollup-android-arm-eabi@4.12.0': + resolution: {integrity: sha512-+ac02NL/2TCKRrJu2wffk1kZ+RyqxVUlbjSagNgPm94frxtr+XDL12E5Ll1enWskLrtrZ2r8L3wED1orIibV/w==} cpu: [arm] os: [android] @@ -4330,6 +4337,9 @@ packages: '@scure/bip32@1.4.0': resolution: {integrity: sha512-sVUpc0Vq3tXCkDGYVWGIZTRfnvu8LoTDaev7vbwh0omSvVORONr960MQWdKqJDCReIEmTj3PAr73O3aoxz7OPg==} + '@scure/bip32@1.4.0': + resolution: {integrity: sha512-sVUpc0Vq3tXCkDGYVWGIZTRfnvu8LoTDaev7vbwh0omSvVORONr960MQWdKqJDCReIEmTj3PAr73O3aoxz7OPg==} + '@scure/bip39@1.1.1': resolution: {integrity: sha512-t+wDck2rVkh65Hmv280fYdVdY25J9YeEUIgn2LG1WM6gxFkGzcksoDiUkWVpVp3Oex9xGC68JU2dSbUfwZ2jPg==} @@ -4958,6 +4968,9 @@ packages: '@types/bn.js@4.11.6': resolution: {integrity: sha512-pqr857jrp2kPuO9uRjZ3PwnJTjoQy+fcdxvBTvHm6dkmEL9q+hDD/2j/0ELOBPtPnS8LjCX0gI9nbl8lVkadpg==} + '@types/bn.js@4.11.6': + resolution: {integrity: sha512-pqr857jrp2kPuO9uRjZ3PwnJTjoQy+fcdxvBTvHm6dkmEL9q+hDD/2j/0ELOBPtPnS8LjCX0gI9nbl8lVkadpg==} + '@types/bn.js@5.1.5': resolution: {integrity: sha512-V46N0zwKRF5Q00AZ6hWtN0T8gGmDUaUzLWQvHFo5yThtVwK/VCenFY3wXVbOvNfajEpsTfQM4IN9k/d6gUVX3A==} @@ -5648,8 +5661,8 @@ packages: '@web3modal/common@5.1.8': resolution: {integrity: sha512-W3tvTQ5FPauFjDSRIx3H6SurzzDHPeN3q7cMaxuOZb3Scf76vMkz9Af970Q44Jmlz1PGDKZzhEsmOzw6LJF+CA==} - '@web3modal/polyfills@4.2.3': - resolution: {integrity: sha512-RiGxh2hMLSD1s2aTjoejNK/UL377CJhGf5tzmdF1m5xsYHpil+Dnulpio8Yojnm27cOqQD+QiaYUKnHOxErLjQ==} + '@web3modal/common@5.1.8': + resolution: {integrity: sha512-W3tvTQ5FPauFjDSRIx3H6SurzzDHPeN3q7cMaxuOZb3Scf76vMkz9Af970Q44Jmlz1PGDKZzhEsmOzw6LJF+CA==} '@web3modal/core@4.2.3': resolution: {integrity: sha512-UykKZTELBpb6ey+IV6fkHWsLkjrIdILmRYzhlznyTPbm9qX5pOR9tH0Z3QGUo7YPFmUqMRH1tC9Irsr3SgIbbw==} @@ -5814,6 +5827,28 @@ packages: zod: optional: true + abitype@1.0.5: + resolution: {integrity: sha512-YzDhti7cjlfaBhHutMaboYB21Ha3rXR9QTkNJFzYC4kC8YclaiwPBBBJY8ejFdu2wnJeZCVZSMlQJ7fi8S6hsw==} + peerDependencies: + typescript: '>=5.0.4' + zod: ^3 >=3.22.0 + peerDependenciesMeta: + typescript: + optional: true + zod: + optional: true + + abitype@1.0.6: + resolution: {integrity: sha512-MMSqYh4+C/aVqI2RQaWqbvI4Kxo5cQV40WQ4QFtDnNzCkqChm8MuENhElmynZlO0qUy/ObkEUaXtKqYnx1Kp3A==} + peerDependencies: + typescript: '>=5.0.4' + zod: ^3 >=3.22.0 + peerDependenciesMeta: + typescript: + optional: true + zod: + optional: true + abort-controller@3.0.0: resolution: {integrity: sha512-h8lQ8tacZYnR3vNQTgibj+tODHI5/+l06Au2Pcriv/Gmet0eaj4TwWH41sO9wnHDiQsEj19q0drzdWdeAHtweg==} engines: {node: '>=6.5'} @@ -5862,6 +5897,14 @@ packages: resolution: {integrity: sha512-o/zjMZRhJxny7OyEF+Op8X+efiELC7k7yOjMzgfzVqOzXqkBkWI79YoTdOtsuWd5BWhAGAuOY/Xa6xpiaWXiNg==} engines: {node: '>= 14'} + agent-base@6.0.2: + resolution: {integrity: sha512-RZNwNclF7+MS/8bDg70amg32dyeZGZxiDuQmZxKLAlQjr3jGyLx+4Kkk58UO7D2QdgFIQCovuSuZESne6RG6XQ==} + engines: {node: '>= 6.0.0'} + + agent-base@7.1.0: + resolution: {integrity: sha512-o/zjMZRhJxny7OyEF+Op8X+efiELC7k7yOjMzgfzVqOzXqkBkWI79YoTdOtsuWd5BWhAGAuOY/Xa6xpiaWXiNg==} + engines: {node: '>= 14'} + ajv-draft-04@1.0.0: resolution: {integrity: sha512-mv00Te6nmYbRp5DCwclxtt7yV/joXJPGS7nM+97GdxvuttCOfgI3K4U25zboyeX0O+myI8ERluxQe5wljMmVIw==} peerDependencies: @@ -6194,6 +6237,9 @@ packages: bluebird@3.7.2: resolution: {integrity: sha512-XpNj6GDQzdfW+r2Wnn7xiSAd7TM3jzkxGXBGTtWKuSXv1xUV+azxAm8jdWZN06QTQk+2N2XB9jRDkvbmQmcRtg==} + bluebird@3.7.2: + resolution: {integrity: sha512-XpNj6GDQzdfW+r2Wnn7xiSAd7TM3jzkxGXBGTtWKuSXv1xUV+azxAm8jdWZN06QTQk+2N2XB9jRDkvbmQmcRtg==} + bn.js@4.11.6: resolution: {integrity: sha512-XWwnNNFCuuSQ0m3r3C4LE3EiORltHd9M05pq6FOlVeiophzRbMo50Sbz1ehl8K3Z+jw9+vmgnXefY1hz8X+2wA==} @@ -6239,6 +6285,10 @@ packages: resolution: {integrity: sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==} engines: {node: '>=8'} + braces@3.0.3: + resolution: {integrity: sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==} + engines: {node: '>=8'} + brorand@1.1.0: resolution: {integrity: sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w==} @@ -6454,6 +6504,9 @@ packages: change-case@5.4.4: resolution: {integrity: sha512-HRQyTk2/YPEkt9TnUPbOpr64Uw3KOicFWPVBb+xiHvd6eBx/qPr9xqfBFDT8P2vWsvvz4jbEkfDe71W3VyNu2w==} + change-case@5.4.4: + resolution: {integrity: sha512-HRQyTk2/YPEkt9TnUPbOpr64Uw3KOicFWPVBb+xiHvd6eBx/qPr9xqfBFDT8P2vWsvvz4jbEkfDe71W3VyNu2w==} + character-entities-html4@2.1.0: resolution: {integrity: sha512-1v7fgQRj6hnSwFpq1Eu0ynr/CDEw0rXo2B61qXrLNdHZmPKgb7fqS1a2JwF0rISo9q77jDI8VMEHoApn8qDoZA==} @@ -6727,6 +6780,9 @@ packages: convert-source-map@1.9.0: resolution: {integrity: sha512-ASFBup0Mz1uyiIjANan1jzLQami9z1PoYSZCiiYW2FczPbenXc45FZdBZLzOT+r6+iciuEModtmCti+hjaAk0A==} + convert-source-map@1.9.0: + resolution: {integrity: sha512-ASFBup0Mz1uyiIjANan1jzLQami9z1PoYSZCiiYW2FczPbenXc45FZdBZLzOT+r6+iciuEModtmCti+hjaAk0A==} + convert-source-map@2.0.0: resolution: {integrity: sha512-Kvp459HrV2FEJ1CAsi1Ku+MY3kasH19TFykTz2xWmMeq6bk2NU3XXvfJ+Q61m0xktWwt+1HSYf3JZsTms3aRJg==} @@ -6906,6 +6962,15 @@ packages: supports-color: optional: true + debug@4.3.7: + resolution: {integrity: sha512-Er2nc/H7RrMXZBFCEim6TCmMk02Z8vLC2Rbi1KEBggpo0fS6l0S1nnapwmIi3yW/+GOJap1Krg4w0Hg80oCqgQ==} + engines: {node: '>=6.0'} + peerDependencies: + supports-color: '*' + peerDependenciesMeta: + supports-color: + optional: true + decamelize@1.2.0: resolution: {integrity: sha512-z2S+W9X73hAUUki+N+9Za2lBlun89zigOyGrsax+KUQ6wKW4ZoWpEYBkGhQjwAjjDCkWxhY0VKEhk8wzY7F5cA==} engines: {node: '>=0.10.0'} @@ -7629,6 +7694,13 @@ packages: ethereumjs-util@6.2.1: resolution: {integrity: sha512-W2Ktez4L01Vexijrm5EB6w7dg4n/TgpoYU4avuT5T3Vmnw/eCRtiBrJfQYS/DCSvDIOLn2k57GcHdeBcgVxAqw==} + ethereumjs-abi@0.6.8: + resolution: {integrity: sha512-Tx0r/iXI6r+lRsdvkFDlut0N08jWMnKRZ6Gkq+Nmw75lZe4e6o3EkSnkaBP5NF6+m5PTGAr9JP43N3LyeoglsA==} + deprecated: This library has been deprecated and usage is discouraged. + + ethereumjs-util@6.2.1: + resolution: {integrity: sha512-W2Ktez4L01Vexijrm5EB6w7dg4n/TgpoYU4avuT5T3Vmnw/eCRtiBrJfQYS/DCSvDIOLn2k57GcHdeBcgVxAqw==} + ethereumjs-util@7.1.5: resolution: {integrity: sha512-SDl5kKrQAudFBUe5OJM9Ac6WmMyYmXX/6sTmLZ3ffG2eY6ZIGBes3pEDxNN6V72WyOw4CPD5RomKdsa8DAAwLg==} engines: {node: '>=10.0.0'} @@ -7800,6 +7872,10 @@ packages: resolution: {integrity: sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==} engines: {node: '>=8'} + fill-range@7.1.1: + resolution: {integrity: sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==} + engines: {node: '>=8'} + filter-obj@1.1.0: resolution: {integrity: sha512-8rXg1ZnX7xzy2NGDVkBVaAy+lSlPNwad13BtgSlLuxfIslyt5Vg64U7tFcCt4WS1R0hvtnQybT/IyCkGZ3DpXQ==} engines: {node: '>=0.10.0'} @@ -8579,9 +8655,8 @@ packages: resolution: {integrity: sha512-1BC0BVFhS/p0qtw6enp8e+8OD0UrK0oFLztSjNzhcKA3WDuJxxAPXzPuPtKkjEY9UUoEWlX/8fgKeu2S8i9JTA==} engines: {node: '>= 0.4'} - is-core-module@2.14.0: - resolution: {integrity: sha512-a5dFJih5ZLYlRtDc0dZWP7RiKr6xIKzmn/oAYCDvdLThadVgyJwlaoQPmRtMSpz+rk0OGAgIu+TcM9HUF0fk1A==} - engines: {node: '>= 0.4'} + is-core-module@2.13.1: + resolution: {integrity: sha512-hHrIjvZsftOsvKSn2TRYl63zvxsgE0K+0mYMoH6gD4omR5IWB2KynivBQczo3+wF1cCkjzvptnI9Q0sPU66ilw==} is-date-object@1.0.5: resolution: {integrity: sha512-9YQaSxsAiSwcvS33MBk3wTCVnWK+HhF8VZR2jRxehM16QcVOdHqPn4VPHmRK4lSr38n9JriurInLcP90xsYNfQ==} @@ -9628,6 +9703,10 @@ packages: resolution: {integrity: sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==} engines: {node: '>=8.6'} + micromatch@4.0.8: + resolution: {integrity: sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==} + engines: {node: '>=8.6'} + mime-db@1.52.0: resolution: {integrity: sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==} engines: {node: '>= 0.6'} @@ -9898,9 +9977,6 @@ packages: nlcst-to-string@4.0.0: resolution: {integrity: sha512-YKLBCcUYKAg0FNlOBT6aI91qFmSiFKiluk655WzPF+DDMA02qIyy8uiRqI8QXtcFpEvll12LpL5MXqEmAZ+dcA==} - nlcst-to-string@4.0.0: - resolution: {integrity: sha512-YKLBCcUYKAg0FNlOBT6aI91qFmSiFKiluk655WzPF+DDMA02qIyy8uiRqI8QXtcFpEvll12LpL5MXqEmAZ+dcA==} - no-case@3.0.4: resolution: {integrity: sha512-fgAN3jGAh+RoxUGZHTSOLJIqUc2wmoBwGR4tbpNAKmmovFoWq0OdRkb0VkldReO2a2iBT/OEulG9XSUc10r3zg==} @@ -10029,9 +10105,8 @@ packages: resolution: {integrity: sha512-RSn9F68PjH9HqtltsSnqYC1XXoWe9Bju5+213R98cNGttag9q9yAOTzdbsqvIa7aNm5WffBZFpWYr2aWrklWAw==} engines: {node: '>= 6'} - object-inspect@1.13.2: - resolution: {integrity: sha512-IRZSRuzJiynemAXPYtPe5BoI/RESNYR7TYm50MC5Mqbd3Jmw5y790sErYw3V6SryFJD64b74qQQs9wn5Bg/k3g==} - engines: {node: '>= 0.4'} + object-inspect@1.13.1: + resolution: {integrity: sha512-5qoj1RUiKOMsCCNLV1CBiPYE10sziTsnmNxkAI/rZhiD63CF7IqdFGC/XzjWjpSgLf0LxXX3bDFIh0E18f6UhQ==} object-keys@1.1.1: resolution: {integrity: sha512-NuAESUOUMrlIXOfHKzD6bpPu3tYt3xvjNdRIQ+FeT0lNb4K8WR70CaDxhuNguS2XG+GjkyMwOzsN5ZktImfhLA==} @@ -10261,6 +10336,9 @@ packages: pako@1.0.11: resolution: {integrity: sha512-4hLB8Py4zZce5s4yd9XzopqwVv/yGNhV1Bl8NTmCq1763HeK2+EwVTv+leGeL13Dnh2wfbqowVPXCIO0z4taYw==} + param-case@3.0.4: + resolution: {integrity: sha512-RXlj7zCYokReqWpOPH9oYivUzLYZ5vAPIfEmCTNViosC78F8F0H9y7T7gG2M39ymgutxF5gcFEsyZQSph9Bp3A==} + parent-module@1.0.1: resolution: {integrity: sha512-GQ2EWRpQV8/o+Aw8YqtfZZPfNRWZYkbidE9k5rpl/hC3vtHHBfGm2Ifi6qWV+coDGkrUKZAxE3Lot5kcsRlh+g==} engines: {node: '>=6'} @@ -10285,9 +10363,6 @@ packages: parse-latin@7.0.0: resolution: {integrity: sha512-mhHgobPPua5kZ98EF4HWiH167JWBfl4pvAIXXdbaVohtK7a6YBOy56kvhCqduqyo/f3yrHFWmqmiMg/BkBkYYQ==} - parse-latin@7.0.0: - resolution: {integrity: sha512-mhHgobPPua5kZ98EF4HWiH167JWBfl4pvAIXXdbaVohtK7a6YBOy56kvhCqduqyo/f3yrHFWmqmiMg/BkBkYYQ==} - parse5@7.1.2: resolution: {integrity: sha512-Czj1WaSVpaoj0wbhMzLmWD69anp2WH7FXMB9n1Sy8/ZFF9jolSQVMu1Ij5WIyGmcBmhk7EOndpO4mIpihVqAXw==} @@ -10372,6 +10447,9 @@ packages: picocolors@1.1.0: resolution: {integrity: sha512-TQ92mBOW0l3LeMeyLV6mzy/kWr8lkd/hp3mTg7wYK7zJhuBStmGMBG0BdeDZS/dZx1IukaX6Bk11zcln25o1Aw==} + picocolors@1.1.0: + resolution: {integrity: sha512-TQ92mBOW0l3LeMeyLV6mzy/kWr8lkd/hp3mTg7wYK7zJhuBStmGMBG0BdeDZS/dZx1IukaX6Bk11zcln25o1Aw==} + picomatch@2.3.1: resolution: {integrity: sha512-JU3teHTNjmE2VCGFzuY8EXzCDVwEqB2a8fsIvwaStHhAWJEeVd1o1QD80CU6+ZdEXXSLbSsuLwJjkCBWqRQUVA==} engines: {node: '>=8.6'} @@ -10957,10 +11035,6 @@ packages: resolution: {integrity: sha512-ILTWeOriIluwEvPjv67v7Blgrcx+LZOkAUVtKI3putuhlZm84FnqDORNXPPm+HY3NdZOMhyDwZ1E+eZB/Df5dA==} engines: {node: '>=16.0.0'} - remark-smartypants@3.0.1: - resolution: {integrity: sha512-qyshfCl2eLO0i0558e79ZJsfojC5wjnYLByjt0FmjJQN6aYwcRxpoj784LZJSoWCdnA2ubh5rLNGb8Uur/wDng==} - engines: {node: '>=16.0.0'} - remark-stringify@11.0.0: resolution: {integrity: sha512-1OSmLd3awB/t8qdoEOMazZkNsfVTeY4fTsgzcQFdXNq8ToTN4ZGwrMnlda4K6smTFKD+GRV6O48i6Z4iKgPPpw==} @@ -11049,9 +11123,6 @@ packages: retext@9.0.0: resolution: {integrity: sha512-sbMDcpHCNjvlheSgMfEcVrZko3cDzdbe1x/e7G66dFp0Ff7Mldvi2uv6JkJQzdRcvLYE8CA8Oe8siQx8ZOgTcA==} - retext@9.0.0: - resolution: {integrity: sha512-sbMDcpHCNjvlheSgMfEcVrZko3cDzdbe1x/e7G66dFp0Ff7Mldvi2uv6JkJQzdRcvLYE8CA8Oe8siQx8ZOgTcA==} - retimer@3.0.0: resolution: {integrity: sha512-WKE0j11Pa0ZJI5YIk0nflGI7SQsfl2ljihVy7ogh7DeQSeYAUi0ubZ/yEueGtDfUPk6GH5LRw1hBdLq4IwUBWA==} @@ -11089,8 +11160,8 @@ packages: ripemd160@2.0.2: resolution: {integrity: sha512-ii4iagi25WusVoiC4B4lq7pbXfAp3D9v5CwfkY33vffw2+pkDjY1D8GaN7spsxvCSx8dkPqOZCEZyfxcmJG2IA==} - risc0-ethereum#v1.1.2@https://codeload.github.com/risc0/risc0-ethereum/tar.gz/b8a14213d92fff07dacda993804e7edb7946ca58: - resolution: {tarball: https://codeload.github.com/risc0/risc0-ethereum/tar.gz/b8a14213d92fff07dacda993804e7edb7946ca58} + risc0-ethereum#v1.2.0@https://codeload.github.com/risc0/risc0-ethereum/tar.gz/3c1fd2a859e40ea009a580aac294191196968c60: + resolution: {tarball: https://codeload.github.com/risc0/risc0-ethereum/tar.gz/3c1fd2a859e40ea009a580aac294191196968c60} version: 0.0.0 rlp@2.2.7: @@ -11219,6 +11290,10 @@ packages: resolution: {integrity: sha512-dW41u5VfLXu8SJh5bwRmyYUbAoSB3c9uQh6L8h/KtsFREPWpbX1lrljJo186Jc4nmci/sGUZ9a0a0J2zgfq2hw==} engines: {node: '>= 0.8.0'} + send@0.19.0: + resolution: {integrity: sha512-dW41u5VfLXu8SJh5bwRmyYUbAoSB3c9uQh6L8h/KtsFREPWpbX1lrljJo186Jc4nmci/sGUZ9a0a0J2zgfq2hw==} + engines: {node: '>= 0.8.0'} + serialize-error@2.1.0: resolution: {integrity: sha512-ghgmKt5o4Tly5yEG/UJp8qTd0AN7Xalw4XBtDEKP655B699qMEtra1WlXeE6WIvdEG481JvRxULKsInq/iNysw==} engines: {node: '>=0.10.0'} @@ -11431,8 +11506,8 @@ packages: resolution: {integrity: sha512-l3BikUxvPOcn5E74dZiq5BGsTb5yEwhaTSzccU6t4sDOH8NWJCstKO5QT2CvtFoK6F0saL7p9xHAqHOlCPJygA==} engines: {node: '>= 8'} - sp1-contracts#v3.0.0@https://codeload.github.com/succinctlabs/sp1-contracts/tar.gz/1c4acaeab86789995ae5c6baced66f81e4a57f4d: - resolution: {tarball: https://codeload.github.com/succinctlabs/sp1-contracts/tar.gz/1c4acaeab86789995ae5c6baced66f81e4a57f4d} + sp1-contracts#v4.0.0-rc.3@https://codeload.github.com/succinctlabs/sp1-contracts/tar.gz/0885c34b525708ed5f7e87a3d7b20c42564b4c00: + resolution: {tarball: https://codeload.github.com/succinctlabs/sp1-contracts/tar.gz/0885c34b525708ed5f7e87a3d7b20c42564b4c00} version: 0.0.0 space-separated-tokens@2.0.2: @@ -11635,6 +11710,7 @@ packages: sudo-prompt@9.2.1: resolution: {integrity: sha512-Mu7R0g4ig9TUuGSxJavny5Rv0egCEtpZRNMrZaYS1vxkiIxGiGUwoezU3LazIQ+KE04hTrTfNPgxU5gzi7F5Pw==} + deprecated: Package no longer supported. Contact Support at https://www.npmjs.com/support for more info. superstruct@1.0.3: resolution: {integrity: sha512-8iTn3oSS8nRGn+C2pgXSKPI3jmpm6FExNazNpjvqS6ZUJQCej3PUXEKM8NjHBOs54ExM+LPW/FBRhymrdcCiSg==} @@ -12084,8 +12160,8 @@ packages: engines: {node: '>=14.17'} hasBin: true - typescript@5.5.3: - resolution: {integrity: sha512-/hreyEujaB0w76zKo6717l3L0o/qEUtRgdvUBvlkhoWeOVMjMuHNHk0BRBzikzuGDqNmPQbg5ifMEqsHLiIUcQ==} + typescript@5.4.3: + resolution: {integrity: sha512-KrPd3PKaCLr78MalgiwJnA25Nm8HAmdwN3mYUYZgG/wizIo9EainNVQI9/yDavtVFRN2h3k8uf3GLHuhDMgEHg==} engines: {node: '>=14.17'} hasBin: true @@ -12118,6 +12194,9 @@ packages: ultron@1.1.1: resolution: {integrity: sha512-UIEXBNeYmKptWH6z8ZnqTeS8fV74zG0/eRU9VGkpzz+LIJNs8W/zM/L+7ctCkRrgbNnnR0xxw4bKOr0cW0N0Og==} + ultron@1.1.1: + resolution: {integrity: sha512-UIEXBNeYmKptWH6z8ZnqTeS8fV74zG0/eRU9VGkpzz+LIJNs8W/zM/L+7ctCkRrgbNnnR0xxw4bKOr0cW0N0Og==} + unbox-primitive@1.0.2: resolution: {integrity: sha512-61pPlCD9h51VoreyJ0BReideM3MDKMKnh6+V9L08331ipq6Q8OFXZYiqP6n/tbHx4s5I9uRhcye6BrbkizkBDw==} @@ -12165,9 +12244,6 @@ packages: unist-util-modify-children@4.0.0: resolution: {integrity: sha512-+tdN5fGNddvsQdIzUF3Xx82CU9sMM+fA0dLgR9vOmT0oPT2jH+P1nd5lSqfCfXAw+93NhcXNY2qqvTUtE4cQkw==} - unist-util-modify-children@4.0.0: - resolution: {integrity: sha512-+tdN5fGNddvsQdIzUF3Xx82CU9sMM+fA0dLgR9vOmT0oPT2jH+P1nd5lSqfCfXAw+93NhcXNY2qqvTUtE4cQkw==} - unist-util-position-from-estree@2.0.0: resolution: {integrity: sha512-KaFVRjoqLyF6YXCbVLNad/eS4+OfPQQn2yOd7zF/h5T/CSL2v8NpN6a5TPvtbXthAGw5nG+PuTtq+DdIZr+cRQ==} @@ -12275,6 +12351,12 @@ packages: peerDependencies: browserslist: '>= 4.21.0' + update-browserslist-db@1.1.0: + resolution: {integrity: sha512-EdRAaAyk2cUE1wOf2DkEhzxqOQvFOoRJFNS6NeyJ01Gp2beMRpBAINjM2iDXE3KCuKhwnvHIQCJm6ThL2Z+HzQ==} + hasBin: true + peerDependencies: + browserslist: '>= 4.21.0' + uqr@0.1.2: resolution: {integrity: sha512-MJu7ypHq6QasgF5YRTjqscSzQp/W11zoUk6kvmlH+fmWEs63Y0Eib13hYFwAzagRJcVY8WVnlV+eBDUGMJ5IbA==} @@ -12678,6 +12760,9 @@ packages: vscode-css-languageservice@6.3.1: resolution: {integrity: sha512-1BzTBuJfwMc3A0uX4JBdJgoxp74cjj4q2mDJdp49yD/GuAq4X0k5WtK6fNcMYr+FfJ9nqgR6lpfCSZDkARJ5qQ==} + vscode-css-languageservice@6.3.1: + resolution: {integrity: sha512-1BzTBuJfwMc3A0uX4JBdJgoxp74cjj4q2mDJdp49yD/GuAq4X0k5WtK6fNcMYr+FfJ9nqgR6lpfCSZDkARJ5qQ==} + vscode-html-languageservice@5.3.0: resolution: {integrity: sha512-C4Z3KsP5Ih+fjHpiBc5jxmvCl+4iEwvXegIrzu2F5pktbWvQaBT3YkVPk8N+QlSSMk8oCG6PKtZ/Sq2YHb5e8g==} @@ -12692,6 +12777,17 @@ packages: resolution: {integrity: sha512-wnJA4BnEjOSyFMvjZdpiOwhSq9uDoK8e/kpRJDTaMYzwlkrhG1fwDIZI94CLsLzlCK5cIbMMtFlJlfR57Lavmg==} engines: {node: '>=8.0.0 || >=10.0.0'} + vscode-html-languageservice@5.3.1: + resolution: {integrity: sha512-ysUh4hFeW/WOWz/TO9gm08xigiSsV/FOAZ+DolgJfeLftna54YdmZ4A+lIn46RbdO3/Qv5QHTn1ZGqmrXQhZyA==} + + vscode-json-languageservice@4.1.8: + resolution: {integrity: sha512-0vSpg6Xd9hfV+eZAaYN63xVVMOTmJ4GgHxXnkLCh+9RsQBkWKIghzLhW2B9ebfG+LQQg8uLtsQ2aUKjTgE+QOg==} + engines: {npm: '>=7.0.0'} + + vscode-jsonrpc@6.0.0: + resolution: {integrity: sha512-wnJA4BnEjOSyFMvjZdpiOwhSq9uDoK8e/kpRJDTaMYzwlkrhG1fwDIZI94CLsLzlCK5cIbMMtFlJlfR57Lavmg==} + engines: {node: '>=8.0.0 || >=10.0.0'} + vscode-jsonrpc@8.2.0: resolution: {integrity: sha512-C+r0eKJUIfiDIfwJhria30+TYWPtuHJXHtI7J0YlOmKAo7ogxP20T0zxB7HZQIFhIyvoBPwWskjxrvAtfjyZfA==} engines: {node: '>=14.0.0'} @@ -13383,6 +13479,12 @@ snapshots: '@aws-sdk/types': 3.577.0 tslib: 1.14.1 + '@aws-crypto/sha256-js@1.2.2': + dependencies: + '@aws-crypto/util': 1.2.2 + '@aws-sdk/types': 3.577.0 + tslib: 1.14.1 + '@aws-crypto/sha256-js@3.0.0': dependencies: '@aws-crypto/util': 3.0.0 @@ -13399,6 +13501,12 @@ snapshots: '@aws-sdk/util-utf8-browser': 3.259.0 tslib: 1.14.1 + '@aws-crypto/util@1.2.2': + dependencies: + '@aws-sdk/types': 3.577.0 + '@aws-sdk/util-utf8-browser': 3.259.0 + tslib: 1.14.1 + '@aws-crypto/util@3.0.0': dependencies: '@aws-sdk/types': 3.577.0 @@ -13872,6 +13980,11 @@ snapshots: '@babel/highlight': 7.23.4 chalk: 2.4.2 + '@babel/code-frame@7.23.5': + dependencies: + '@babel/highlight': 7.23.4 + chalk: 2.4.2 + '@babel/code-frame@7.24.2': dependencies: '@babel/highlight': 7.24.5 @@ -14041,6 +14154,80 @@ snapshots: '@babel/helper-validator-option@7.24.8': {} + '@babel/helper-wrap-function@7.22.20': + dependencies: + '@babel/helper-function-name': 7.23.0 + '@babel/template': 7.25.0 + '@babel/types': 7.25.6 + + '@babel/helpers@7.25.6': + dependencies: + '@babel/template': 7.25.0 + '@babel/types': 7.25.6 + + '@babel/highlight@7.23.4': + dependencies: + '@babel/helper-validator-identifier': 7.22.20 + chalk: 2.4.2 + js-tokens: 4.0.0 + + '@babel/helper-module-transforms@7.25.2(@babel/core@7.25.2)': + dependencies: + '@babel/core': 7.25.2 + '@babel/helper-module-imports': 7.24.7 + '@babel/helper-simple-access': 7.24.7 + '@babel/helper-validator-identifier': 7.24.7 + '@babel/traverse': 7.25.6 + transitivePeerDependencies: + - supports-color + + '@babel/helper-optimise-call-expression@7.22.5': + dependencies: + '@babel/types': 7.25.6 + + '@babel/helper-plugin-utils@7.24.8': {} + + '@babel/helper-remap-async-to-generator@7.22.20(@babel/core@7.25.2)': + dependencies: + '@babel/core': 7.25.2 + '@babel/helper-annotate-as-pure': 7.24.7 + '@babel/helper-environment-visitor': 7.22.20 + '@babel/helper-wrap-function': 7.22.20 + + '@babel/helper-replace-supers@7.22.20(@babel/core@7.25.2)': + dependencies: + '@babel/core': 7.25.2 + '@babel/helper-environment-visitor': 7.22.20 + '@babel/helper-member-expression-to-functions': 7.23.0 + '@babel/helper-optimise-call-expression': 7.22.5 + + '@babel/helper-simple-access@7.24.7': + dependencies: + '@babel/traverse': 7.25.6 + '@babel/types': 7.25.6 + transitivePeerDependencies: + - supports-color + + '@babel/helper-skip-transparent-expression-wrappers@7.22.5': + dependencies: + '@babel/types': 7.25.6 + + '@babel/helper-split-export-declaration@7.24.5': + dependencies: + '@babel/types': 7.25.6 + + '@babel/helper-string-parser@7.23.4': {} + + '@babel/helper-string-parser@7.24.8': {} + + '@babel/helper-validator-identifier@7.22.20': {} + + '@babel/helper-validator-identifier@7.24.5': {} + + '@babel/helper-validator-identifier@7.24.7': {} + + '@babel/helper-validator-option@7.24.8': {} + '@babel/helper-wrap-function@7.22.20': dependencies: '@babel/helper-function-name': 7.23.0 @@ -14152,6 +14339,13 @@ snapshots: js-tokens: 4.0.0 picocolors: 1.0.0 + '@babel/highlight@7.24.7': + dependencies: + '@babel/helper-validator-identifier': 7.24.7 + chalk: 2.4.2 + js-tokens: 4.0.0 + picocolors: 1.0.0 + '@babel/parser@7.23.9': dependencies: '@babel/types': 7.23.9 @@ -15549,6 +15743,11 @@ snapshots: eslint: 8.56.0 eslint-visitor-keys: 3.4.3 + '@eslint-community/eslint-utils@4.4.0(eslint@8.56.0)': + dependencies: + eslint: 8.56.0 + eslint-visitor-keys: 3.4.3 + '@eslint-community/regexpp@4.11.0': {} '@eslint/eslintrc@1.4.1': @@ -15895,7 +16094,7 @@ snapshots: '@fastify/busboy@2.1.0': {} - '@formatjs/ecma402-abstract@2.0.0': + '@formatjs/ecma402-abstract@1.18.2': dependencies: '@formatjs/intl-localematcher': 0.5.4 tslib: 2.6.3 @@ -15959,6 +16158,8 @@ snapshots: '@humanwhocodes/object-schema@2.0.2': {} + '@humanwhocodes/object-schema@2.0.2': {} + '@img/sharp-darwin-arm64@0.33.4': optionalDependencies: '@img/sharp-libvips-darwin-arm64': 1.0.2 @@ -16285,7 +16486,7 @@ snapshots: '@metamask/json-rpc-engine@7.3.2': dependencies: - '@metamask/rpc-errors': 6.3.0 + '@metamask/rpc-errors': 6.2.1 '@metamask/safe-event-emitter': 3.1.1 '@metamask/utils': 8.3.0 transitivePeerDependencies: @@ -16388,7 +16589,7 @@ snapshots: transitivePeerDependencies: - supports-color - '@metamask/rpc-errors@6.3.0': + '@metamask/providers@16.1.0': dependencies: '@metamask/utils': 8.3.0 fast-safe-stringify: 2.1.1 @@ -16416,7 +16617,7 @@ snapshots: '@metamask/sdk-communication-layer@0.20.2(cross-fetch@4.0.0(encoding@0.1.13))(eciesjs@0.3.18)(eventemitter2@6.4.9)(readable-stream@3.6.2)(socket.io-client@4.7.4(bufferutil@4.0.8)(utf-8-validate@5.0.10))': dependencies: bufferutil: 4.0.8 - cross-fetch: 4.0.0 + cross-fetch: 3.1.8(encoding@0.1.13) date-fns: 2.30.0 debug: 4.3.7(supports-color@8.1.1) eciesjs: 0.3.18 @@ -16743,6 +16944,11 @@ snapshots: '@motionone/utils': 10.16.3 tslib: 2.6.2 + '@motionone/easing@10.16.3': + dependencies: + '@motionone/utils': 10.16.3 + tslib: 2.6.2 + '@motionone/generators@10.16.4': dependencies: '@motionone/types': 10.16.3 @@ -16800,7 +17006,7 @@ snapshots: '@multiformats/dns': 1.0.6 multiformats: 13.1.3 uint8-varint: 2.0.4 - uint8arrays: 5.1.0 + uint8arrays: 5.0.3 '@noble/curves@1.2.0': dependencies: @@ -16818,6 +17024,10 @@ snapshots: dependencies: '@noble/hashes': 1.4.0 + '@noble/curves@1.4.0': + dependencies: + '@noble/hashes': 1.4.0 + '@noble/hashes@1.2.0': {} '@noble/hashes@1.3.2': {} @@ -17544,6 +17754,9 @@ snapshots: '@rollup/rollup-android-arm-eabi@4.12.0': optional: true + '@rollup/rollup-android-arm-eabi@4.12.0': + optional: true + '@rollup/rollup-android-arm-eabi@4.18.0': optional: true @@ -17553,6 +17766,12 @@ snapshots: '@rollup/rollup-android-arm64@4.12.0': optional: true + '@rollup/rollup-android-arm-eabi@4.21.3': + optional: true + + '@rollup/rollup-android-arm64@4.12.0': + optional: true + '@rollup/rollup-android-arm64@4.17.2': optional: true @@ -19251,7 +19470,11 @@ snapshots: transitivePeerDependencies: - supports-color - '@typescript-eslint/typescript-estree@5.62.0(typescript@5.5.3)': + '@typescript-eslint/types@7.7.0': {} + + '@typescript-eslint/types@7.9.0': {} + + '@typescript-eslint/typescript-estree@5.62.0(typescript@5.4.3)': dependencies: '@typescript-eslint/types': 5.62.0 '@typescript-eslint/visitor-keys': 5.62.0 @@ -19317,10 +19540,11 @@ snapshots: debug: 4.3.4 globby: 11.1.0 is-glob: 4.0.3 - minimatch: 9.0.5 + minimatch: 9.0.4 semver: 7.6.2 - ts-api-utils: 1.3.0(typescript@5.5.3) - typescript: 5.5.3 + ts-api-utils: 1.3.0(typescript@5.4.3) + optionalDependencies: + typescript: 5.4.3 transitivePeerDependencies: - supports-color @@ -19626,12 +19850,13 @@ snapshots: dotenv-expand: 10.0.0 esbuild: 0.19.12 execa: 8.0.1 - fdir: 6.1.1(picomatch@3.0.1) + fdir: 6.3.0(picomatch@3.0.1) find-up: 6.3.0 fs-extra: 11.2.0 ora: 6.3.1 pathe: 1.1.2 picocolors: 1.0.0 + picomatch: 3.0.1 prettier: 3.2.5 viem: 2.9.29(bufferutil@4.0.8)(typescript@5.4.3)(utf-8-validate@5.0.10)(zod@3.22.4) zod: 3.22.4 @@ -19920,8 +20145,42 @@ snapshots: - '@vercel/kv' - bufferutil - encoding - - ioredis - - uWebSockets.js + - supports-color + - utf-8-validate + + '@walletconnect/core@2.16.1(@react-native-async-storage/async-storage@1.22.0(react-native@0.73.4(@babel/core@7.25.2)(@babel/preset-env@7.23.9(@babel/core@7.25.2))(bufferutil@4.0.8)(encoding@0.1.13)(react@18.2.0)(utf-8-validate@5.0.10)))(bufferutil@4.0.8)(utf-8-validate@5.0.10)': + dependencies: + '@walletconnect/heartbeat': 1.2.2 + '@walletconnect/jsonrpc-provider': 1.0.14 + '@walletconnect/jsonrpc-types': 1.0.4 + '@walletconnect/jsonrpc-utils': 1.0.8 + '@walletconnect/jsonrpc-ws-connection': 1.0.14(bufferutil@4.0.8)(utf-8-validate@5.0.10) + '@walletconnect/keyvaluestorage': 1.1.1(@react-native-async-storage/async-storage@1.22.0(react-native@0.73.4(@babel/core@7.25.2)(@babel/preset-env@7.23.9(@babel/core@7.25.2))(bufferutil@4.0.8)(encoding@0.1.13)(react@18.2.0)(utf-8-validate@5.0.10))) + '@walletconnect/logger': 2.1.2 + '@walletconnect/relay-api': 1.0.11 + '@walletconnect/relay-auth': 1.0.4 + '@walletconnect/safe-json': 1.0.2 + '@walletconnect/time': 1.0.2 + '@walletconnect/types': 2.16.1(@react-native-async-storage/async-storage@1.22.0(react-native@0.73.4(@babel/core@7.25.2)(@babel/preset-env@7.23.9(@babel/core@7.25.2))(bufferutil@4.0.8)(encoding@0.1.13)(react@18.2.0)(utf-8-validate@5.0.10))) + '@walletconnect/utils': 2.16.1(@react-native-async-storage/async-storage@1.22.0(react-native@0.73.4(@babel/core@7.25.2)(@babel/preset-env@7.23.9(@babel/core@7.25.2))(bufferutil@4.0.8)(encoding@0.1.13)(react@18.2.0)(utf-8-validate@5.0.10))) + events: 3.3.0 + lodash.isequal: 4.5.0 + uint8arrays: 3.1.0 + transitivePeerDependencies: + - '@azure/app-configuration' + - '@azure/cosmos' + - '@azure/data-tables' + - '@azure/identity' + - '@azure/keyvault-secrets' + - '@azure/storage-blob' + - '@capacitor/preferences' + - '@netlify/blobs' + - '@planetscale/database' + - '@react-native-async-storage/async-storage' + - '@upstash/redis' + - '@vercel/kv' + - bufferutil + - supports-color - utf-8-validate '@walletconnect/core@2.13.3': @@ -20128,39 +20387,6 @@ snapshots: - supports-color - utf-8-validate - '@walletconnect/ethereum-provider@2.13.3(react@18.3.1)': - dependencies: - '@walletconnect/jsonrpc-http-connection': 1.0.8 - '@walletconnect/jsonrpc-provider': 1.0.14 - '@walletconnect/jsonrpc-types': 1.0.4 - '@walletconnect/jsonrpc-utils': 1.0.8 - '@walletconnect/modal': 2.6.2(react@18.3.1) - '@walletconnect/sign-client': 2.13.3 - '@walletconnect/types': 2.13.3 - '@walletconnect/universal-provider': 2.13.3 - '@walletconnect/utils': 2.13.3 - events: 3.3.0 - transitivePeerDependencies: - - '@azure/app-configuration' - - '@azure/cosmos' - - '@azure/data-tables' - - '@azure/identity' - - '@azure/keyvault-secrets' - - '@azure/storage-blob' - - '@capacitor/preferences' - - '@netlify/blobs' - - '@planetscale/database' - - '@react-native-async-storage/async-storage' - - '@types/react' - - '@upstash/redis' - - '@vercel/kv' - - bufferutil - - encoding - - ioredis - - react - - uWebSockets.js - - utf-8-validate - '@walletconnect/events@1.0.1': dependencies: keyvaluestorage-interface: 1.0.0 @@ -20187,6 +20413,15 @@ snapshots: transitivePeerDependencies: - encoding + '@walletconnect/jsonrpc-http-connection@1.0.8(encoding@0.1.13)': + dependencies: + '@walletconnect/jsonrpc-utils': 1.0.8 + '@walletconnect/safe-json': 1.0.2 + cross-fetch: 3.1.8(encoding@0.1.13) + tslib: 1.14.1 + transitivePeerDependencies: + - encoding + '@walletconnect/jsonrpc-http-connection@1.0.8(encoding@0.1.13)': dependencies: '@walletconnect/jsonrpc-utils': 1.0.8 @@ -20426,36 +20661,6 @@ snapshots: - supports-color - utf-8-validate - '@walletconnect/sign-client@2.13.3': - dependencies: - '@walletconnect/core': 2.13.3 - '@walletconnect/events': 1.0.1 - '@walletconnect/heartbeat': 1.2.2 - '@walletconnect/jsonrpc-utils': 1.0.8 - '@walletconnect/logger': 2.1.2 - '@walletconnect/time': 1.0.2 - '@walletconnect/types': 2.13.3 - '@walletconnect/utils': 2.13.3 - events: 3.3.0 - transitivePeerDependencies: - - '@azure/app-configuration' - - '@azure/cosmos' - - '@azure/data-tables' - - '@azure/identity' - - '@azure/keyvault-secrets' - - '@azure/storage-blob' - - '@capacitor/preferences' - - '@netlify/blobs' - - '@planetscale/database' - - '@react-native-async-storage/async-storage' - - '@upstash/redis' - - '@vercel/kv' - - bufferutil - - encoding - - ioredis - - uWebSockets.js - - utf-8-validate - '@walletconnect/time@1.0.2': dependencies: tslib: 1.14.1 @@ -20848,38 +21053,6 @@ snapshots: - '@vercel/kv' - supports-color - '@walletconnect/utils@2.13.3': - dependencies: - '@stablelib/chacha20poly1305': 1.0.1 - '@stablelib/hkdf': 1.0.1 - '@stablelib/random': 1.0.2 - '@stablelib/sha256': 1.0.1 - '@stablelib/x25519': 1.0.3 - '@walletconnect/relay-api': 1.0.10 - '@walletconnect/safe-json': 1.0.2 - '@walletconnect/time': 1.0.2 - '@walletconnect/types': 2.13.3 - '@walletconnect/window-getters': 1.0.1 - '@walletconnect/window-metadata': 1.0.1 - detect-browser: 5.3.0 - query-string: 7.1.3 - uint8arrays: 3.1.0 - transitivePeerDependencies: - - '@azure/app-configuration' - - '@azure/cosmos' - - '@azure/data-tables' - - '@azure/identity' - - '@azure/keyvault-secrets' - - '@azure/storage-blob' - - '@capacitor/preferences' - - '@netlify/blobs' - - '@planetscale/database' - - '@react-native-async-storage/async-storage' - - '@upstash/redis' - - '@vercel/kv' - - ioredis - - uWebSockets.js - '@walletconnect/window-getters@1.0.1': dependencies: tslib: 1.14.1 @@ -21155,38 +21328,10 @@ snapshots: - supports-color - utf-8-validate - '@web3modal/wagmi@4.2.3(@wagmi/connectors@5.0.21)(@wagmi/core@2.11.6)(react@18.3.1)(viem@2.16.5)': + '@web3modal/wallet@4.2.3': dependencies: - '@wagmi/connectors': 5.0.21(@wagmi/core@2.11.6)(react-native@0.74.3)(react@18.3.1)(typescript@5.5.3)(viem@2.16.5) - '@wagmi/core': 2.11.6(react@18.3.1)(typescript@5.5.3)(viem@2.16.5) - '@walletconnect/ethereum-provider': 2.13.0(react@18.3.1) - '@web3modal/polyfills': 4.2.3 - '@web3modal/scaffold': 4.2.3(react@18.3.1) - '@web3modal/scaffold-react': 4.2.3(react@18.3.1) - '@web3modal/scaffold-utils': 4.2.3(react@18.3.1) - '@web3modal/scaffold-vue': 4.2.3(react@18.3.1) - '@web3modal/siwe': 4.2.3(react@18.3.1) - react: 18.3.1 - viem: 2.16.5(typescript@5.5.3)(zod@3.23.8) - transitivePeerDependencies: - - '@azure/app-configuration' - - '@azure/cosmos' - - '@azure/data-tables' - - '@azure/identity' - - '@azure/keyvault-secrets' - - '@azure/storage-blob' - - '@capacitor/preferences' - - '@netlify/blobs' - - '@planetscale/database' - - '@react-native-async-storage/async-storage' - - '@types/react' - - '@upstash/redis' - - '@vercel/kv' - - bufferutil - - encoding - - ioredis - - uWebSockets.js - - utf-8-validate + '@web3modal/polyfills': 4.1.11 + zod: 3.22.4 '@web3modal/wallet@4.2.3': dependencies: @@ -21267,6 +21412,10 @@ snapshots: dependencies: acorn: 8.12.1 + acorn-jsx@5.3.2(acorn@8.12.1): + dependencies: + acorn: 8.12.1 + acorn-walk@8.3.2: {} acorn@8.12.0: {} @@ -21291,6 +21440,12 @@ snapshots: transitivePeerDependencies: - supports-color + agent-base@7.1.0: + dependencies: + debug: 4.3.7(supports-color@8.1.1) + transitivePeerDependencies: + - supports-color + ajv-draft-04@1.0.0(ajv@8.16.0): dependencies: clean-stack: 2.2.0 @@ -21587,8 +21742,8 @@ snapshots: caniuse-lite: 1.0.30001593 fraction.js: 4.3.7 normalize-range: 0.1.2 - picocolors: 1.0.1 - postcss: 8.4.39 + picocolors: 1.0.0 + postcss: 8.4.38 postcss-value-parser: 4.2.0 autoprefixer@10.4.19(postcss@8.4.38): @@ -21811,6 +21966,10 @@ snapshots: dependencies: fill-range: 7.1.1 + braces@3.0.3: + dependencies: + fill-range: 7.1.1 + brorand@1.1.0: {} browser-assert@1.2.1: {} @@ -22036,6 +22195,8 @@ snapshots: change-case@5.4.4: {} + change-case@5.4.4: {} + character-entities-html4@2.1.0: {} character-entities-legacy@3.0.0: {} @@ -22301,6 +22462,8 @@ snapshots: convert-source-map@1.9.0: {} + convert-source-map@1.9.0: {} + convert-source-map@2.0.0: {} cookie-es@1.0.0: {} @@ -22348,6 +22511,15 @@ snapshots: optionalDependencies: typescript: 5.4.3 + cosmiconfig@8.3.6(typescript@5.4.5): + dependencies: + import-fresh: 3.3.0 + js-yaml: 4.1.0 + parse-json: 5.2.0 + path-type: 4.0.0 + optionalDependencies: + typescript: 5.4.3 + cosmiconfig@8.3.6(typescript@5.4.5): dependencies: import-fresh: 3.3.0 @@ -22456,8 +22628,8 @@ snapshots: dependencies: css-selector-tokenizer: 0.8.0 culori: 3.3.0 - picocolors: 1.0.1 - postcss-js: 4.0.1(postcss@8.4.39) + picocolors: 1.0.0 + postcss-js: 4.0.1(postcss@8.4.38) transitivePeerDependencies: - postcss @@ -23274,7 +23446,7 @@ snapshots: globals: 13.24.0 ignore: 5.3.1 is-builtin-module: 3.2.1 - is-core-module: 2.14.0 + is-core-module: 2.13.1 minimatch: 3.1.2 resolve: 1.22.8 semver: 7.6.3 @@ -23428,28 +23600,70 @@ snapshots: optionalDependencies: svelte: 4.2.17 transitivePeerDependencies: + - supports-color - ts-node - eslint-scope@5.1.1: - dependencies: - esrecurse: 4.3.0 - estraverse: 4.3.0 - - eslint-scope@7.2.2: - dependencies: - esrecurse: 4.3.0 - estraverse: 5.3.0 - - eslint-utils@2.1.0: + eslint-plugin-svelte@2.38.0(eslint@8.56.0)(svelte@4.2.17)(ts-node@10.9.2(@types/node@20.12.7)(typescript@5.4.3)): dependencies: - eslint-visitor-keys: 1.3.0 + '@eslint-community/eslint-utils': 4.4.0(eslint@8.56.0) + '@jridgewell/sourcemap-codec': 1.4.15 + debug: 4.3.4 + eslint: 8.56.0 + eslint-compat-utils: 0.5.0(eslint@8.56.0) + esutils: 2.0.3 + known-css-properties: 0.30.0 + postcss: 8.4.38 + postcss-load-config: 3.1.4(postcss@8.4.38)(ts-node@10.9.2(@types/node@20.12.7)(typescript@5.4.3)) + postcss-safe-parser: 6.0.0(postcss@8.4.38) + postcss-selector-parser: 6.0.16 + semver: 7.6.0 + svelte-eslint-parser: 0.35.0(svelte@4.2.17) + optionalDependencies: + svelte: 4.2.17 + transitivePeerDependencies: + - supports-color + - ts-node - eslint-utils@3.0.0(eslint@8.4.1): + eslint-plugin-svelte@2.38.0(eslint@8.56.0)(svelte@4.2.17)(ts-node@10.9.2(@types/node@20.12.7)(typescript@5.4.5)): dependencies: - eslint: 8.4.1 - eslint-visitor-keys: 2.1.0 - - eslint-visitor-keys@1.3.0: {} + '@eslint-community/eslint-utils': 4.4.0(eslint@8.56.0) + '@jridgewell/sourcemap-codec': 1.4.15 + debug: 4.3.4 + eslint: 8.56.0 + eslint-compat-utils: 0.5.0(eslint@8.56.0) + esutils: 2.0.3 + known-css-properties: 0.30.0 + postcss: 8.4.38 + postcss-load-config: 3.1.4(postcss@8.4.38)(ts-node@10.9.2(@types/node@20.12.7)(typescript@5.4.5)) + postcss-safe-parser: 6.0.0(postcss@8.4.38) + postcss-selector-parser: 6.0.16 + semver: 7.6.0 + svelte-eslint-parser: 0.35.0(svelte@4.2.17) + optionalDependencies: + svelte: 4.2.17 + transitivePeerDependencies: + - ts-node + + eslint-scope@5.1.1: + dependencies: + esrecurse: 4.3.0 + estraverse: 4.3.0 + + eslint-scope@7.2.2: + dependencies: + esrecurse: 4.3.0 + estraverse: 5.3.0 + + eslint-utils@2.1.0: + dependencies: + eslint-visitor-keys: 1.3.0 + + eslint-utils@3.0.0(eslint@8.4.1): + dependencies: + eslint: 8.4.1 + eslint-visitor-keys: 2.1.0 + + eslint-visitor-keys@1.3.0: {} eslint-visitor-keys@2.1.0: {} @@ -23541,6 +23755,49 @@ snapshots: transitivePeerDependencies: - supports-color + eslint@8.56.0: + dependencies: + '@eslint-community/eslint-utils': 4.4.0(eslint@8.56.0) + '@eslint-community/regexpp': 4.10.0 + '@eslint/eslintrc': 2.1.4 + '@eslint/js': 8.56.0 + '@humanwhocodes/config-array': 0.11.14 + '@humanwhocodes/module-importer': 1.0.1 + '@nodelib/fs.walk': 1.2.8 + '@ungap/structured-clone': 1.2.0 + ajv: 6.12.6 + chalk: 4.1.2 + cross-spawn: 7.0.3 + debug: 4.3.4 + doctrine: 3.0.0 + escape-string-regexp: 4.0.0 + eslint-scope: 7.2.2 + eslint-visitor-keys: 3.4.3 + espree: 9.6.1 + esquery: 1.5.0 + esutils: 2.0.3 + fast-deep-equal: 3.1.3 + file-entry-cache: 6.0.1 + find-up: 5.0.0 + glob-parent: 6.0.2 + globals: 13.23.0 + graphemer: 1.4.0 + ignore: 5.3.0 + imurmurhash: 0.1.4 + is-glob: 4.0.3 + is-path-inside: 3.0.3 + js-yaml: 4.1.0 + json-stable-stringify-without-jsonify: 1.0.1 + levn: 0.4.1 + lodash.merge: 4.6.2 + minimatch: 3.1.2 + natural-compare: 1.4.0 + optionator: 0.9.3 + strip-ansi: 6.0.1 + text-table: 0.2.0 + transitivePeerDependencies: + - supports-color + eslint@8.56.0: dependencies: '@eslint-community/eslint-utils': 4.4.0(eslint@8.56.0) @@ -23759,6 +24016,21 @@ snapshots: ethjs-util: 0.1.6 rlp: 2.2.7 + ethereumjs-abi@0.6.8: + dependencies: + bn.js: 4.12.0 + ethereumjs-util: 6.2.1 + + ethereumjs-util@6.2.1: + dependencies: + '@types/bn.js': 4.11.6 + bn.js: 4.12.0 + create-hash: 1.2.0 + elliptic: 6.5.7 + ethereum-cryptography: 0.1.3 + ethjs-util: 0.1.6 + rlp: 2.2.7 + ethereumjs-util@7.1.5: dependencies: '@types/bn.js': 5.1.5 @@ -24026,6 +24298,10 @@ snapshots: dependencies: to-regex-range: 5.0.1 + fill-range@7.1.1: + dependencies: + to-regex-range: 5.0.1 + filter-obj@1.1.0: {} finalhandler@1.1.2: @@ -24667,6 +24943,20 @@ snapshots: stringify-entities: 4.0.4 zwitch: 2.0.4 + hast-util-to-html@9.0.2: + dependencies: + '@types/hast': 3.0.4 + '@types/unist': 3.0.2 + ccount: 2.0.1 + comma-separated-tokens: 2.0.3 + hast-util-whitespace: 3.0.0 + html-void-elements: 3.0.0 + mdast-util-to-hast: 13.1.0 + property-information: 6.5.0 + space-separated-tokens: 2.0.2 + stringify-entities: 4.0.4 + zwitch: 2.0.4 + hast-util-to-jsx-runtime@2.3.0: dependencies: '@types/estree': 1.0.5 @@ -25506,6 +25796,35 @@ snapshots: - supports-color - utf-8-validate + jsdom@24.0.0(bufferutil@4.0.8)(utf-8-validate@6.0.3): + dependencies: + cssstyle: 4.0.1 + data-urls: 5.0.0 + decimal.js: 10.4.3 + form-data: 4.0.0 + html-encoding-sniffer: 4.0.0 + http-proxy-agent: 7.0.2 + https-proxy-agent: 7.0.4 + is-potential-custom-element-name: 1.0.1 + nwsapi: 2.2.7 + parse5: 7.1.2 + rrweb-cssom: 0.6.0 + saxes: 6.0.0 + symbol-tree: 3.2.4 + tough-cookie: 4.1.3 + w3c-xmlserializer: 5.0.0 + webidl-conversions: 7.0.0 + whatwg-encoding: 3.1.1 + whatwg-mimetype: 4.0.0 + whatwg-url: 14.0.0 + ws: 8.16.0(bufferutil@4.0.8)(utf-8-validate@6.0.3) + xml-name-validator: 5.0.0 + transitivePeerDependencies: + - bufferutil + - supports-color + - utf-8-validate + optional: true + jsdom@24.1.0: dependencies: cssstyle: 4.0.1 @@ -25854,6 +26173,8 @@ snapshots: lowercase-keys@2.0.0: {} + lowercase-keys@2.0.0: {} + lowercase-keys@3.0.0: {} lru-cache@10.2.0: {} @@ -26624,6 +26945,11 @@ snapshots: braces: 3.0.3 picomatch: 2.3.1 + micromatch@4.0.8: + dependencies: + braces: 3.0.3 + picomatch: 2.3.1 + mime-db@1.52.0: {} mime-types@2.1.35: @@ -26891,10 +27217,6 @@ snapshots: next-tick@1.1.0: {} - nlcst-to-string@4.0.0: - dependencies: - '@types/nlcst': 2.0.3 - nlcst-to-string@4.0.0: dependencies: '@types/nlcst': 2.0.3 @@ -26994,7 +27316,7 @@ snapshots: object-hash@3.0.0: {} - object-inspect@1.13.2: {} + object-inspect@1.13.1: {} object-keys@1.1.1: {} @@ -27192,6 +27514,14 @@ snapshots: dependencies: p-limit: 1.3.0 + p-limit@6.1.0: + dependencies: + yocto-queue: 1.1.1 + + p-locate@2.0.0: + dependencies: + p-limit: 1.3.0 + p-locate@3.0.0: dependencies: p-limit: 2.3.0 @@ -27250,6 +27580,11 @@ snapshots: pako@1.0.11: {} + param-case@3.0.4: + dependencies: + dot-case: 3.0.4 + tslib: 2.6.2 + parent-module@1.0.1: dependencies: callsites: 3.1.0 @@ -27290,15 +27625,6 @@ snapshots: unist-util-visit-children: 3.0.0 vfile: 6.0.3 - parse-latin@7.0.0: - dependencies: - '@types/nlcst': 2.0.3 - '@types/unist': 3.0.2 - nlcst-to-string: 4.0.0 - unist-util-modify-children: 4.0.0 - unist-util-visit-children: 3.0.0 - vfile: 6.0.1 - parse5@7.1.2: dependencies: entities: 4.5.0 @@ -27368,6 +27694,8 @@ snapshots: picocolors@1.1.0: {} + picocolors@1.1.0: {} + picomatch@2.3.1: {} picomatch@3.0.1: {} @@ -27435,7 +27763,7 @@ snapshots: pony-cause@2.1.10: {} - postcss-import@15.1.0(postcss@8.4.39): + postcss-import@15.1.0(postcss@8.4.38): dependencies: postcss: 8.4.39 postcss-value-parser: 4.2.0 @@ -27462,7 +27790,6 @@ snapshots: postcss-load-config@3.1.4(postcss@8.4.38)(ts-node@10.9.2(@types/node@20.12.7)(typescript@5.4.3)): dependencies: lilconfig: 2.1.0 - postcss: 8.4.39 yaml: 1.10.2 optionalDependencies: postcss: 8.4.38 @@ -27501,10 +27828,29 @@ snapshots: ts-node: 10.9.2(@types/node@20.12.7)(typescript@5.4.5) optional: true - postcss-nested@5.0.6(postcss@8.4.39): + postcss-load-config@4.0.2(postcss@8.4.38)(ts-node@10.9.2(@types/node@20.12.7)(typescript@5.4.5)): + dependencies: + lilconfig: 3.1.1 + yaml: 2.3.4 + optionalDependencies: + postcss: 8.4.38 + ts-node: 10.9.2(@types/node@20.12.7)(typescript@5.4.5) + + postcss-load-config@4.0.2(postcss@8.4.47)(ts-node@10.9.2(@types/node@20.12.7)(typescript@5.4.5)): dependencies: - postcss: 8.4.39 - postcss-selector-parser: 6.1.0 + lilconfig: 3.1.1 + yaml: 2.3.4 + optionalDependencies: + postcss: 8.4.47 + ts-node: 10.9.2(@types/node@20.12.7)(typescript@5.4.5) + optional: true + + postcss-nesting@12.1.0(postcss@8.4.38): + dependencies: + '@csstools/selector-resolve-nested': 1.1.0(postcss-selector-parser@6.0.15) + '@csstools/selector-specificity': 3.0.2(postcss-selector-parser@6.0.15) + postcss: 8.4.38 + postcss-selector-parser: 6.0.15 postcss-nested@6.0.1(postcss@8.4.39): dependencies: @@ -27531,6 +27877,11 @@ snapshots: cssesc: 3.0.0 util-deprecate: 1.0.2 + postcss-selector-parser@6.0.15: + dependencies: + cssesc: 3.0.0 + util-deprecate: 1.0.2 + postcss-selector-parser@6.0.16: dependencies: cssesc: 3.0.0 @@ -28106,13 +28457,6 @@ snapshots: unified: 11.0.5 unist-util-visit: 5.0.0 - remark-smartypants@3.0.1: - dependencies: - retext: 9.0.0 - retext-smartypants: 6.1.0 - unified: 11.0.5 - unist-util-visit: 5.0.0 - remark-stringify@11.0.0: dependencies: '@types/mdast': 4.0.4 @@ -28224,13 +28568,6 @@ snapshots: retext-stringify: 4.0.0 unified: 11.0.5 - retext@9.0.0: - dependencies: - '@types/nlcst': 2.0.3 - retext-latin: 4.0.0 - retext-stringify: 4.0.0 - unified: 11.0.5 - retimer@3.0.0: {} retry@0.13.1: {} @@ -28260,7 +28597,7 @@ snapshots: hash-base: 3.1.0 inherits: 2.0.4 - risc0-ethereum#v1.1.2@https://codeload.github.com/risc0/risc0-ethereum/tar.gz/b8a14213d92fff07dacda993804e7edb7946ca58: {} + risc0-ethereum#v1.2.0@https://codeload.github.com/risc0/risc0-ethereum/tar.gz/3c1fd2a859e40ea009a580aac294191196968c60: {} rlp@2.2.7: dependencies: @@ -28342,6 +28679,28 @@ snapshots: '@rollup/rollup-win32-x64-msvc': 4.21.3 fsevents: 2.3.3 + rollup@4.21.3: + dependencies: + '@types/estree': 1.0.5 + optionalDependencies: + '@rollup/rollup-android-arm-eabi': 4.21.3 + '@rollup/rollup-android-arm64': 4.21.3 + '@rollup/rollup-darwin-arm64': 4.21.3 + '@rollup/rollup-darwin-x64': 4.21.3 + '@rollup/rollup-linux-arm-gnueabihf': 4.21.3 + '@rollup/rollup-linux-arm-musleabihf': 4.21.3 + '@rollup/rollup-linux-arm64-gnu': 4.21.3 + '@rollup/rollup-linux-arm64-musl': 4.21.3 + '@rollup/rollup-linux-powerpc64le-gnu': 4.21.3 + '@rollup/rollup-linux-riscv64-gnu': 4.21.3 + '@rollup/rollup-linux-s390x-gnu': 4.21.3 + '@rollup/rollup-linux-x64-gnu': 4.21.3 + '@rollup/rollup-linux-x64-musl': 4.21.3 + '@rollup/rollup-win32-arm64-msvc': 4.21.3 + '@rollup/rollup-win32-ia32-msvc': 4.21.3 + '@rollup/rollup-win32-x64-msvc': 4.21.3 + fsevents: 2.3.3 + rrweb-cssom@0.6.0: {} run-applescript@5.0.0: @@ -28543,6 +28902,10 @@ snapshots: dependencies: shebang-regex: 1.0.0 + shebang-command@1.2.0: + dependencies: + shebang-regex: 1.0.0 + shebang-command@2.0.0: dependencies: shebang-regex: 3.0.0 @@ -28740,6 +29103,31 @@ snapshots: transitivePeerDependencies: - typescript + solhint@5.0.3(typescript@5.4.3): + dependencies: + '@solidity-parser/parser': 0.18.0 + ajv: 6.12.6 + antlr4: 4.13.1 + ast-parents: 0.0.1 + chalk: 4.1.2 + commander: 10.0.1 + cosmiconfig: 8.3.6(typescript@5.4.3) + fast-diff: 1.3.0 + glob: 8.1.0 + ignore: 5.3.1 + js-yaml: 4.1.0 + latest-version: 7.0.0 + lodash: 4.17.21 + pluralize: 8.0.0 + semver: 7.6.0 + strip-ansi: 6.0.1 + table: 6.8.1 + text-table: 0.2.0 + optionalDependencies: + prettier: 2.8.8 + transitivePeerDependencies: + - typescript + solhint@5.0.3(typescript@5.4.3): dependencies: '@solidity-parser/parser': 0.18.0 @@ -28801,7 +29189,7 @@ snapshots: source-map@0.7.4: {} - sp1-contracts#v3.0.0@https://codeload.github.com/succinctlabs/sp1-contracts/tar.gz/1c4acaeab86789995ae5c6baced66f81e4a57f4d: {} + sp1-contracts#v4.0.0-rc.3@https://codeload.github.com/succinctlabs/sp1-contracts/tar.gz/0885c34b525708ed5f7e87a3d7b20c42564b4c00: {} space-separated-tokens@2.0.2: {} @@ -29178,7 +29566,6 @@ snapshots: svelte-preprocess@5.1.3(@babel/core@7.25.2)(postcss-load-config@4.0.2(postcss@8.4.38)(ts-node@10.9.2(@types/node@20.12.7)(typescript@5.4.3)))(postcss@8.4.38)(svelte@4.2.13)(typescript@5.4.5): dependencies: - '@babel/core': 7.24.7 '@types/pug': 2.0.10 detect-indent: 6.1.0 magic-string: 0.30.9 @@ -29254,7 +29641,7 @@ snapshots: '@jridgewell/sourcemap-codec': 1.4.15 '@jridgewell/trace-mapping': 0.3.25 '@types/estree': 1.0.5 - acorn: 8.12.0 + acorn: 8.11.3 aria-query: 5.3.0 axobject-query: 4.0.0 code-red: 1.0.4 @@ -29340,9 +29727,9 @@ snapshots: fast-glob: 3.3.2 glob-parent: 6.0.2 is-glob: 4.0.3 - jiti: 1.21.6 + jiti: 1.21.0 lilconfig: 2.1.0 - micromatch: 4.0.7 + micromatch: 4.0.5 normalize-path: 3.0.0 object-hash: 3.0.0 picocolors: 1.0.0 @@ -29571,7 +29958,7 @@ snapshots: create-require: 1.1.1 diff: 4.0.2 make-error: 1.3.6 - typescript: 5.5.3 + typescript: 5.4.3 v8-compile-cache-lib: 3.0.1 yn: 3.1.1 @@ -29618,6 +30005,12 @@ snapshots: tunnel@0.0.6: {} + tunnel-agent@0.6.0: + dependencies: + safe-buffer: 5.2.1 + + tunnel@0.0.6: {} + tween-functions@1.2.0: {} tweetnacl-util@0.15.1: {} @@ -29688,7 +30081,7 @@ snapshots: typescript@5.4.3: {} - typescript@5.5.3: {} + typescript@5.4.3: {} ufo@1.4.0: {} @@ -29722,6 +30115,8 @@ snapshots: ultron@1.1.1: {} + ultron@1.1.1: {} + unbox-primitive@1.0.2: dependencies: call-bind: 1.0.7 @@ -29782,11 +30177,6 @@ snapshots: '@types/unist': 3.0.2 array-iterate: 2.0.1 - unist-util-modify-children@4.0.0: - dependencies: - '@types/unist': 3.0.2 - array-iterate: 2.0.1 - unist-util-position-from-estree@2.0.0: dependencies: '@types/unist': 3.0.2 @@ -29901,7 +30291,7 @@ snapshots: utf-8-validate@5.0.10: dependencies: - node-gyp-build: 4.8.1 + node-gyp-build: 4.8.0 utf-8-validate@6.0.4: dependencies: @@ -30185,9 +30575,9 @@ snapshots: vite-tsconfig-paths@4.3.2(typescript@5.4.5)(vite@5.2.11(@types/node@20.12.7)(terser@5.27.2)): dependencies: - debug: 4.3.5 + debug: 4.3.4 globrex: 0.1.2 - tsconfck: 3.0.3(typescript@5.4.5) + tsconfck: 3.0.3(typescript@5.4.3) optionalDependencies: vite: 5.2.11(@types/node@20.12.7)(terser@5.27.2) transitivePeerDependencies: @@ -30216,10 +30606,9 @@ snapshots: vite@5.2.11(@types/node@20.12.7)(terser@5.27.2): dependencies: - '@types/node': 20.14.9 - esbuild: 0.21.5 - postcss: 8.4.39 - rollup: 4.18.0 + esbuild: 0.19.12 + postcss: 8.4.38 + rollup: 4.12.0 optionalDependencies: '@types/node': 20.12.7 fsevents: 2.3.3 @@ -30339,15 +30728,14 @@ snapshots: '@vitest/snapshot': 1.6.0 '@vitest/spy': 1.6.0 '@vitest/utils': 1.6.0 - acorn-walk: 8.3.3 + acorn-walk: 8.3.2 chai: 4.4.1 - debug: 4.3.5 + debug: 4.3.4 execa: 8.0.1 - jsdom: 24.1.0 local-pkg: 0.5.0 magic-string: 0.30.10 pathe: 1.1.2 - picocolors: 1.0.1 + picocolors: 1.0.0 std-env: 3.7.0 strip-literal: 2.0.0 tinybench: 2.6.0 @@ -30445,6 +30833,12 @@ snapshots: optionalDependencies: '@volar/language-service': 2.4.5 + volar-service-typescript@0.0.61(@volar/language-service@2.4.5): + dependencies: + vscode-uri: 3.0.8 + optionalDependencies: + '@volar/language-service': 2.4.5 + volar-service-typescript@0.0.61(@volar/language-service@2.4.5): dependencies: '@volar/language-service': 2.2.5 @@ -30475,10 +30869,10 @@ snapshots: vscode-languageserver-types: 3.17.5 vscode-uri: 3.0.8 - vscode-html-languageservice@5.3.0: + vscode-html-languageservice@5.3.1: dependencies: '@vscode/l10n': 0.0.18 - vscode-languageserver-textdocument: 1.0.11 + vscode-languageserver-textdocument: 1.0.12 vscode-languageserver-types: 3.17.5 vscode-uri: 3.0.8