-
Notifications
You must be signed in to change notification settings - Fork 212
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(swingset): raise meter FULL from 1e7 to 1e8
The agoric-cli/integration-test was failing: while dapp-encouragement's contract was being installed into the on-chain Zoe, the zoe.install() crank spends a lot of time in babel applying the metering transform to the contract bundle. Most of this happens during import, after the initial nestedEvaluate wrapper executes, which means the global meter is active. All that babel code calls primordial functions like Object.keys a lot, and all those calls count against the meter. The dapp-encouragement contract required about 12M total units, and the default meter budget only allowed 10M. After raising the meter value to let the test pass, @michaelfig helped me find a way to turn off the global meter while inside the transform functions, so we don't "charge" contracts for their usage of Babel. This reduces the dapp-encouragement evaluation's metering usage by at least a factor of 10, making the budget increase mostly unnecessary. I'm going to leave the framework for it in place for now, however. We might lower the budget back to the original values later, if meter-exhausting tests take too long, but so far they seem to "finish" infinite loops quickly enough.
- Loading branch information
Showing
1 changed file
with
51 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters