Open roxaneletourneau opened 2 years ago
Hello @roxaneletourneau, what would be the expected behaviour if the util function receives an empty Michelson expression, is that even a scenario we would like to take into account?
Hi @dsawali, I suggest throwing an exception if the expression is empty.
The implementation of this function currently depends on the valueEncoder()
function in the @taquito/local-forging
package. Importing that function creates a circular dependency which results in the build failing.
Rewriting the valueEncoder()
function in @taquito/utils
would result in duplication of code.
This issue will be put back into the ready for work pile until a more elegant solution is formulated
As Taquito user, I want to calculate the hash of a global constant having its Michelson expression, so that I can easily retrieve the hash of an already registered expression.
Acceptance criteria:
Out of scope Validate if the expression is registered as a global constant.
Additional context To produce the hash: 1- forge the Michelson expression using
valueEncoder
from@taquito/local-forging
2- hash using blake2b + b58cencode + appends expr prefix (this can by done withencodeExpr
from@taquito/utils
)example: