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

roothash/api: rename Genesis.Blocks -> RuntimeStates #2462

Merged
merged 1 commit into from
Dec 24, 2019

Conversation

matevz
Copy link
Member

@matevz matevz commented Dec 10, 2019

PR for #2426:

  • replaces roothash.Genesis.Blocks with map storing api.RuntimeGenesis objects,
  • adds RuntimeGenesis.Round and --runtime.genesis.round flag,
  • on InitChain() generates runtime genesis block using RuntimeGenesis instead of block,
  • replaces RuntimeGenesis.StorageReceipt with StorageReceipts i.e. one receipt per storage node,
  • adds sanity checks for RuntimeGenesis including StorageSignatures verification of StateRoot and tests for it,
  • adds RuntimeGenesis struct to rust,
  • adds base64 serialization/deserialization of Bytes in rust.

@codecov
Copy link

codecov bot commented Dec 10, 2019

Codecov Report

Merging #2462 into master will increase coverage by 0.18%.
The diff coverage is 62.9%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #2462      +/-   ##
==========================================
+ Coverage   66.76%   66.94%   +0.18%     
==========================================
  Files         324      324              
  Lines       29887    29893       +6     
==========================================
+ Hits        19953    20013      +60     
+ Misses       7453     7388      -65     
- Partials     2481     2492      +11
Impacted Files Coverage Δ
go/registry/api/api.go 42.09% <0%> (-0.16%) ⬇️
go/oasis-node/cmd/debug/storage/export.go 47.82% <100%> (+0.92%) ⬆️
go/consensus/tendermint/apps/roothash/genesis.go 100% <100%> (ø) ⬆️
go/oasis-node/cmd/registry/runtime/runtime.go 60.07% <100%> (+0.3%) ⬆️
go/consensus/tendermint/apps/roothash/roothash.go 69.44% <100%> (+0.76%) ⬆️
go/registry/tests/tester.go 87.71% <100%> (ø) ⬆️
go/registry/api/runtime.go 44.89% <33.33%> (-3.76%) ⬇️
go/roothash/api/api.go 80.95% <33.33%> (+19.84%) ⬆️
go/oasis-node/cmd/genesis/genesis.go 50% <8.33%> (+0.23%) ⬆️
go/common/namespace.go 62.5% <0%> (-12.5%) ⬇️
... 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 b4d818b...a3940c4. Read the comment docs.

Copy link
Member

@kostko kostko left a comment

Choose a reason for hiding this comment

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

Signature contexts should not be moved.

go/common/crypto/signature/signer.go Outdated Show resolved Hide resolved
go/consensus/tendermint/apps/roothash/genesis.go Outdated Show resolved Hide resolved
go/oasis-node/cmd/debug/byzantine/compute.go Outdated Show resolved Hide resolved
@matevz matevz force-pushed the matevz/feature/rename-blocks-field-in-genesis branch 2 times, most recently from 6b4acc4 to e1b122e Compare December 20, 2019 12:43
@matevz matevz marked this pull request as ready for review December 20, 2019 12:43
@matevz matevz force-pushed the matevz/feature/rename-blocks-field-in-genesis branch 5 times, most recently from 1034c44 to 16f83fd Compare December 23, 2019 12:15
@kostko kostko added the c:breaking/consensus Category: breaking consensus changes label Dec 23, 2019
@matevz matevz force-pushed the matevz/feature/rename-blocks-field-in-genesis branch from 16f83fd to 67609ff Compare December 23, 2019 12:25
.changelog/2426.feature.md Outdated Show resolved Hide resolved
go/oasis-node/cmd/debug/storage/export.go Outdated Show resolved Hide resolved
go/registry/api/runtime.go Outdated Show resolved Hide resolved
go/registry/api/api.go Show resolved Hide resolved
go/registry/api/runtime.go Show resolved Hide resolved
runtime/src/common/bytes.rs Outdated Show resolved Hide resolved
runtime/src/common/registry.rs Outdated Show resolved Hide resolved
go/registry/api/runtime.go Outdated Show resolved Hide resolved
go/registry/api/runtime.go Outdated Show resolved Hide resolved
runtime/src/common/bytes.rs Outdated Show resolved Hide resolved
@matevz matevz force-pushed the matevz/feature/rename-blocks-field-in-genesis branch from 93fbf34 to ce92b8c Compare December 24, 2019 09:52
Copy link
Member

@kostko kostko left a comment

Choose a reason for hiding this comment

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

Few minor nits, otherwise looks good now.

go/registry/api/runtime.go Outdated Show resolved Hide resolved
go/roothash/api/api.go Outdated Show resolved Hide resolved
runtime/src/common/bytes.rs Outdated Show resolved Hide resolved
runtime/src/common/bytes.rs Outdated Show resolved Hide resolved
runtime/src/common/bytes.rs Outdated Show resolved Hide resolved
runtime/src/common/bytes.rs Outdated Show resolved Hide resolved
@matevz matevz force-pushed the matevz/feature/rename-blocks-field-in-genesis branch from 95137e2 to a3940c4 Compare December 24, 2019 10:50
@matevz matevz merged commit 87d942d into master Dec 24, 2019
@matevz matevz deleted the matevz/feature/rename-blocks-field-in-genesis branch December 24, 2019 12:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
c:breaking/consensus Category: breaking consensus changes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants