Add option in the ContractCallContext
to hold the contract that is currently being deployed
#9798
Labels
ContractCallContext
to hold the contract that is currently being deployed
#9798
Problem
During the implementation of the reusable services integration it turns out that now the contracts are deployed in 2 steps:
FileCreateTransactionBody
.ContractCreateTransactionBody
.Each step performs a separate transaction.
For step 2 even if we pass the correct file id, since the mirror node data is readonly, the
FileReadableKVState
is not able to populate the contract's bytecode from the DB since it was never explicitly persisted in the DB.Solution
Add 2 new fields in the
ContractCallContext
that preserve the file id and the contract's bytecode. If they are available when we callFileReadableKVState#readFromDataSource
, return them with priority.Alternatives
No response
The text was updated successfully, but these errors were encountered: