-
Notifications
You must be signed in to change notification settings - Fork 632
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
feat: implement NEP264, function call gas weight #6285
Merged
Merged
Changes from all commits
Commits
Show all changes
29 commits
Select commit
Hold shift + click to select a range
1b5f49e
feat: implement NEP264, function call gas ratio
austinabell fd91668
adjust wording to weight instead of ratio, cleanup
austinabell e012271
cleanup remaining ratio references
austinabell 44044ff
change logic to assign all unused gas
austinabell ac4c2f0
wrap gas weight and fix clearing weights
austinabell 60d7293
add test for weight over u64 bounds
austinabell 886ebf6
Merge branch 'master' of github.com:near/nearcore into austin/nep264
austinabell 78d4a95
expose GasWeight newtype to trait interface
austinabell 43b2f92
Merge branch 'master' into austin/nep264
austinabell ab3e7ac
addr comments
austinabell 0350337
Merge branch 'master' into austin/nep264
austinabell 9bf9846
address nagisa's comments
austinabell 6d0ec3a
fix lint ignore
austinabell 0436ab6
switch vm logic function to have generic callback and gate by feature
austinabell 1e88e76
Merge branch 'master' of github.com:near/nearcore into austin/nep264
austinabell a979f6a
fit lint and nightly hash for Protocol version bump
austinabell 56caf81
update gas distribution function return
austinabell 343741b
gate new types under feature flag
austinabell 5aca615
Make GasDistribution non_exhaustive
austinabell 50d3a13
Merge branch 'master' into austin/nep264
austinabell 0f36da2
Merge branch 'master' into austin/nep264
austinabell bfb3c99
Merge branch 'master' into austin/nep264
austinabell e46f4a0
Merge branch 'master' into austin/nep264
austinabell b713308
addr docs comments
austinabell 429c4d6
fmt
austinabell db092fb
Merge branch 'master' of github.com:near/nearcore into austin/nep264
austinabell 662a7f7
update assert syntax
austinabell bf069c1
address comments
austinabell 0f6a8a2
Merge branch 'master' of github.com:near/nearcore into austin/nep264
austinabell File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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
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
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
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
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
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
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
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
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd mention that this is the same function as above (append_action_function_call) with the added argument.
And maybe in this documentation focus a little bit more on what 'gas_weight' means.
And what happens if I set both 'prepaid_gas' and gas_weight?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
and what if gas_weight is 0 ? does it still include gas then ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Assumed the docs for this would be lighter since it's documented in
promise_batch_action_function_call_weight
, but I see the benefit in giving some info here also.There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it is fine to have lighter docs - but then let's make sure that we have a 'pointer' to the place where people can read more details.
(I actually don't know which file is read by users - this one or logic.rs?)