ecadlabs / taquito

A library for building dApps on the Tezos Blockchain - JavaScript / TypeScript
https://taquito.io
Apache License 2.0
298 stars 118 forks source link

USER STORY: Validate entrypoint params and storage based on Michelson types #1017

Open Innkst opened 3 years ago

Innkst commented 3 years ago

As Taquito user, I want to validate smart contract calls, so that I can have improved error handling through catch errors earlier and with more context

Background The Taquito smart contract abstractions do not validate data based on the Michelson Types and defer this validation to the RPC. By incorporating this validation into Taquito directly, we can provide better error handling and a superior developer experience to developers building on Taquito.

Use cases: Example of a failing validation where incorrect data is passed to a smart contract entrypoint

Acceptance criteria:

Non-functional:

OUT OF SCOPE: N/A

Additional context This work can be done separately from #784

dsawali commented 2 years ago

MIght be valuable to address that currently some types in the michelson-encoder package does not have validation in its member functions (i.e. string.ts , timestamp.ts and some others)