aurora-is-near / aurora-engine

⚙️ Aurora Engine implements an Ethereum Virtual Machine (EVM) on the NEAR Protocol.
https://doc.aurora.dev/develop/compat/evm
327 stars 80 forks source link

Feat: Allow hashchain to be initialized with new directly #846

Closed birchmd closed 1 year ago

birchmd commented 1 year ago

Description

For the mainnet Aurora Engine we must use the pause_contract + start_hashchain migration procedure because it is already live. However, for new silos it will be useful to have the hashchain enabled from the start. This PR adds a new optional parameter to the new function where an initial (genesis) hashchain value can be specified and then hashchain will be enabled on all transactions going forward.

Performance / NEAR gas cost considerations

N/A; impacts new only.

Testing

Tests updated to use new for starting the hashchain by default. Some tests still use the migration procedure to ensure that is also tested.