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

feat(core): add genesis API #14223

Merged
merged 7 commits into from
Dec 15, 2022
Merged

feat(core): add genesis API #14223

merged 7 commits into from
Dec 15, 2022

Conversation

aaronc
Copy link
Member

@aaronc aaronc commented Dec 8, 2022

Description

This extracts the genesis portion of the core API proposal (#12239) into a standalone PR. The canonical implementation for genesis target and source is being done in #13724.

We should attempt to iron out the high-level semantics for how this genesis API works in this PR. In particular, this API assumes that we either have:

  • a single JSON blob for a module in the genesis.json file as we currently do, or
  • individual files for each field in separate files (<genesis_folder>/<module>/<field>.json) to support better memory usage from streaming as requested by crypto.com
  • or some combination of these two

Author Checklist

All items are required. Please add a note to the item if the item is not applicable and
please add links to any relevant follow up issues.

I have...

  • included the correct type prefix in the PR title
  • added ! to the type prefix if API or client breaking change
  • targeted the correct branch (see PR Targeting)
  • provided a link to the relevant issue or specification
  • followed the guidelines for building modules
  • included the necessary unit and integration tests
  • added a changelog entry to CHANGELOG.md
  • included comments for documenting Go code
  • updated the relevant documentation or specification
  • reviewed "Files changed" and left comments if necessary
  • confirmed all CI checks have passed

Reviewers Checklist

All items are required. Please add a note if the item is not applicable and please add
your handle next to the items reviewed if you only reviewed selected items.

I have...

  • confirmed the correct type prefix in the PR title
  • confirmed ! in the type prefix if API or client breaking change
  • confirmed all author checklist items have been addressed
  • reviewed state machine logic
  • reviewed API design and naming
  • reviewed documentation is accurate
  • reviewed tests and test coverage
  • manually tested (if applicable)

@aaronc aaronc marked this pull request as ready for review December 8, 2022 17:02
@aaronc aaronc requested a review from a team as a code owner December 8, 2022 17:02
core/genesis/genesis.go Outdated Show resolved Hide resolved
core/appmodule/genesis.go Outdated Show resolved Hide resolved
core/genesis/genesis.go Outdated Show resolved Hide resolved
core/appmodule/genesis.go Outdated Show resolved Hide resolved
@sonarcloud
Copy link

sonarcloud bot commented Dec 14, 2022

[Cosmos SDK] Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
No Duplication information No Duplication information

core/genesis/genesis.go Outdated Show resolved Hide resolved
aaronc and others added 2 commits December 15, 2022 13:03
Co-authored-by: Amaury <1293565+amaurym@users.noreply.github.com>
@aaronc
Copy link
Member Author

aaronc commented Dec 15, 2022

@AmauryM I have switched from interfaces to function types as discussed. Can you re-review?

@sonarcloud
Copy link

sonarcloud bot commented Dec 15, 2022

[Cosmos SDK - Core] Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
No Duplication information No Duplication information

Copy link
Contributor

@amaury1093 amaury1093 left a comment

Choose a reason for hiding this comment

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

LGTM!

@aaronc aaronc enabled auto-merge (squash) December 15, 2022 18:33
@aaronc aaronc merged commit 2d5b67c into main Dec 15, 2022
@aaronc aaronc deleted the aaronc/core-api-genesis branch December 15, 2022 19:24
@aaronc aaronc mentioned this pull request Dec 15, 2022
19 tasks
@aaronc
Copy link
Member Author

aaronc commented Dec 15, 2022

Tagged core/v0.3.4 with this

@coderabbitai coderabbitai bot mentioned this pull request May 3, 2024
12 tasks
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.

5 participants