Open olonho opened 2 years ago
If we protocol change this, we should also consider changing how we limit promises gas. Rather than checking gas limit on every deduct_gas
operation, we can check it once, after wasm execution finishes. Note that we already postpone actual promise creation in the Rust SDK.
It's not hard to keep exact promises gas counter IMO.
This issue has been automatically marked as stale because it has not had recent activity in the last 2 months. It will be closed in 7 days if no further activity occurs. Thank you for your contributions.
This issue has been automatically marked as stale because it has not had recent activity in the last 2 months. It will be closed in 7 days if no further activity occurs. Thank you for your contributions.
When transaction fails we still require (by tests) that used amount of gas is sum of promised and burnt gas. Seems more natural to zero out promised part.
I agree in principle with that statement but want to make clear that it doesn't matter, since on an error, we refund prepaid - burnt
and the promised gas is not relevant:
During work on https://github.com/near/nearcore/pull/5121 we identified two questionable places in gas metering.