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

refactor: state: Move randomness versioning out of the VM #7816

Merged
merged 1 commit into from
Dec 17, 2021

Conversation

arajasek
Copy link
Contributor

@arajasek arajasek commented Dec 17, 2021

Related Issues

The rand versioning in the VM is currently bloated, and in the wrong place -- the VM shouldn't be reasoning about how randomness is versioned.

Proposed Changes

Moves the randomness versioning logic out of the VM and into the Rand module.

Checklist

Before you mark the PR ready for review, please make sure that:

  • All commits have a clear commit message.
  • The PR title is in the form of of <PR type>: <#issue number> <area>: <change being made>
    • example: fix: #1234 mempool: Introduce a cache for valid signatures
    • PR type: fix, feat, INTERFACE BREAKING CHANGE, CONSENSUS BREAKING, build, chore, ci, docs, misc,perf, refactor, revert, style, test
    • area: api, chain, state, vm, data transfer, market, mempool, message, block production, multisig, networking, paychan, proving, sealing, wallet
  • This PR has tests for new functionality or change in behaviour
  • If new user-facing features are introduced, clear usage guidelines and / or documentation updates should be included in https://lotus.filecoin.io or Discussion Tutorials.
  • CI is green

@arajasek arajasek requested a review from a team as a code owner December 17, 2021 19:01
@codecov
Copy link

codecov bot commented Dec 17, 2021

Codecov Report

Merging #7816 (aa1b770) into master (a4728d3) will increase coverage by 0.03%.
The diff coverage is 90.90%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #7816      +/-   ##
==========================================
+ Coverage   39.47%   39.51%   +0.03%     
==========================================
  Files         654      654              
  Lines       70033    70010      -23     
==========================================
+ Hits        27649    27665      +16     
+ Misses      37633    37605      -28     
+ Partials     4751     4740      -11     
Impacted Files Coverage Δ
chain/vm/vm.go 62.96% <ø> (ø)
chain/gen/genesis/miners.go 57.80% <50.00%> (+1.93%) ⬆️
chain/rand/rand.go 66.66% <93.75%> (+8.77%) ⬆️
chain/stmgr/stmgr.go 65.34% <100.00%> (-1.15%) ⬇️
chain/vm/runtime.go 53.45% <100.00%> (-0.75%) ⬇️
markets/loggers/loggers.go 89.28% <0.00%> (-10.72%) ⬇️
chain/actors/builtin/miner/diff.go 52.94% <0.00%> (-5.89%) ⬇️
chain/stmgr/execute.go 86.95% <0.00%> (-4.35%) ⬇️
storage/wdpost_sched.go 77.45% <0.00%> (-3.93%) ⬇️
chain/vm/mkactor.go 48.48% <0.00%> (-3.04%) ⬇️
... and 16 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update a4728d3...aa1b770. Read the comment docs.

Copy link
Contributor

@ZenGround0 ZenGround0 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a very nice change. But I feel deeply conflicted about your go.sum

@@ -37,15 +37,7 @@ cloud.google.com/go/storage v1.6.0/go.mod h1:N7U0C8pVQ/+NIKOBQyamJIeKQKkZ+mxpohl
cloud.google.com/go/storage v1.8.0/go.mod h1:Wv1Oy7z6Yz3DshWRJFhqM/UCfaWIRTdp0RXyy7KQOVs=
cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9ullr3+Kg0=
collectd.org v0.3.0/go.mod h1:A/8DzQBkF6abtvrT2j/AU/4tiBgJWYyh0y/oB/4MlWE=
<<<<<<< HEAD
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fix conflicts

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is fixing the conflicts ;)

@arajasek arajasek merged commit 94e1a83 into master Dec 17, 2021
@arajasek arajasek deleted the asr/rand-refactor branch December 17, 2021 20:57
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.

2 participants