massalabs/massa

Add some context to error `Provided gas {} is lower than the base instance creation gas cost {}.`

bilboquet opened this issue · 0 comments

Here is a scenario with a poor / misleading error message:

  • Readonly call correctly provides a max gas value of 3728755.
  • When this max gas is used in the send_operation, an error occurs: Provided gas 1895238 is lower than the base instance creation gas cost 2100000.

This seems to be a nested call issue:
The schema is something like:

  • an operation calls a SC1 with 3728755 gas
  • SC1 use some gas
  • SC1 calls SC2 with 1895238
  • SC2 fails with Provided gas 1895238 is lower than the base instance creation gas cost 2100000

Tasks:

  • #4587
  • add dedicated test massalabs/massa-functional-tests#13