Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Not charge gas for contract dependency loading #797

Merged
merged 1 commit into from May 22, 2023

Conversation

codchen
Copy link
Collaborator

@codchen codchen commented May 22, 2023

Describe your changes and provide context

Since the number of times and timing of contract dependency loading can be different across nodes due to issues like process restart, transaction parallelization, etc., we decide to not charge gas for times when the dependencies need to be loaded from the store, so that the difference wouldn't cause non-determinism.

Using an infinite gas meter instead of the original gas meter + refund because we don't want this now "free" operation to cause panics (e.g. when the original meter is just about to run out of gas)

Testing performed to validate your change

unit tests + load test

@philipsu522 philipsu522 merged commit cfd716b into master May 22, 2023
27 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants