Closed antho1404 closed 5 years ago
Is it behavior has been fixed?
Not yet, we are still allowing more data from the service without throwing any errors. This kind of fix will break services like the ethereum one that send all the payload of a block where the mesg api just expose few data from the block
With the issue https://github.com/mesg-foundation/core/issues/194 data from inputs, results and events are validated to match at least the data in the
mesg.yml
We should make sure that we also don't send too much data but exactly the ones needed.
Example:
Let's have an event that have the data "foo" and "bar"
we actually need to send the payload with "foo" and "bar" but we can also add any other attribute "x", "y"... and this will be accepted by the core.
We can be strict on the validation and make sure to only have what the
mesg.yml
file defines otherwise it's an error.This filter can be done directly in the different libraries like https://github.com/mesg-foundation/mesg-js