zkevm-circuits icon indicating copy to clipboard operation
zkevm-circuits copied to clipboard

Feat/#1752 fix witness generation - json exportor

Open KimiWu123 opened this issue 1 year ago • 1 comments

Description

closed #1752

Issue Link

#1752

Type of change

  • [x] New feature (non-breaking change which adds functionality)

Contents

  • This PR merged .go files of #1756.
  • Have a new function, GenerateWitness to export json for stack trie.
  • Add isTxProof flag in equipLeafWithModExtensionNode and `addBranchAndPlaceholder' to avoid touching the exising logic of the state trie.
  • Fix GetProof(): before this fix, if any hashed nodes in the proof, other non-hashed nodes will not append to the proof. This causes the output proofs are incorrect.
  • Add nibbles and proof type in StackProof for exporting json files.
  • Modified extension node is not included in this PR, will do it in futher PR. #1809

KimiWu123 avatar Mar 08 '24 06:03 KimiWu123

Hi @miha-stopar, I merged #1756, but only .go files, and now everything works, all the tests were passed! It' ready for review .

KimiWu123 avatar Apr 19 '24 08:04 KimiWu123