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

PoC for Genesis Manipulation Libraries and Tools #1189

Closed
moul opened this issue Oct 2, 2023 · 1 comment · Fixed by #1252
Closed

PoC for Genesis Manipulation Libraries and Tools #1189

moul opened this issue Oct 2, 2023 · 1 comment · Fixed by #1252
Assignees

Comments

@moul
Copy link
Member

moul commented Oct 2, 2023

Objective:

Advance the development of a comprehensive suite of libraries and tools focused on genesis manipulation and management. This suite will bolster the ongoing efforts to establish an eventually-consistent testnet (#1131) and refine local net development.

As of now, the genesis generation for the gnoland main is rudimentary and manual. The ambition is to progress from this baseline to facilitate the design of new genesis files, amend current ones, and furnish the capacity to read, consolidate, or modify various genesis files.

Clarification on Project Philosophy:

It's important to rectify a common misunderstanding about the project's scope and philosophy. While gno.land, gnovm, and tm2 espouse a rigorous adherence to minimalism and simplicity, this doesn't imply that all extensions or tools related to the project should mirror this strict philosophy.

For instance, while the gnoland binary philosophy aims for minimalism, other components like gnosdk might accommodate more advanced tools and features. One example is the proposed introduction of proof of stake coordination tools or other advanced utilities. For those who envision gno.land being more akin to cosmos-sdk, the suggested approach would be to work directly within tm2 or gnovm (when the requirements align with the project's minimalistic principles). Alternatively, contributors can utilize the gnosdk top-level folder for functions that might not strictly adhere to the gnoland binary philosophy.

To further underscore this concept, consider reviewing and merging proposal #1105, which emphasizes the role of gnosdk as a suitable destination for ideas that aren't minimalistic enough for gnoland.

Library Requirements:

  1. Gnotxsync Integration: Design libraries to synchronize flawlessly with gnotxsync outputs.
  2. Data Management Helpers: Equip the suite with utilities tailored for filtering and overwriting genesis data.
  3. Balance Management: Introduce tools that optimize balance-related tasks within the genesis.
  4. Automatic Balance Additions: Implement a function to auto-update balances grounded on gnotxsync transactions, guaranteeing initialization of relevant addresses.
  5. Local Development Balances: Incorporate a function that derives balances from the local gnokey list, ensuring a consistent fund flow for developers during local development.
  6. Future Additions: Envisage the inclusion of proof-of-stake coordination utilities in forthcoming iterations.

Tool Requirements:

  1. Genesis SDK Tool: Champion the inception of the "gnosdk-genesis" tool. A feasible modus operandi might be its integration into the gnosdk binary, introducing "genesis" as a subcommand (gnosdk genesis). Although this arrangement appears suitable, it remains receptive to feedback and alternative propositions.
  2. Makefile Integration: Revamp the makefiles to utilize the gnosdk-genesis tool. This action aims to spawn a local genesis file labeled genesis-tx.local.txt, rooted in genesis-tx.txt (sourced from git). Accompany this with a git configuration to disregard files with the *.local.txt nomenclature.

Future Considerations: Down the line, other blockchain projects might aspire to consolidate functionalities into a single binary like mychain. This could comprise the chain production node, genesis manipulation utilities, and the client. For gno.land, however, the vision remains to keep the gnoland binary streamlined, focusing on core functionalities while assigning auxiliary functions to dedicated tools. The gnosdk emerges as the optimal solution to this dichotomy.

Related with gnolang/tx-exports#1.

@zivkovicmilos
Copy link
Member

@moul

I've created a new mega-issue to track the genesis library / command tooling suite:
#1203

We can create mini-issues for each subcommand / functionality and assign them accordingly

@zivkovicmilos zivkovicmilos linked a pull request Oct 18, 2023 that will close this issue
7 tasks
moul pushed a commit that referenced this issue Oct 28, 2023
## Description

This PR introduces the genesis.json command suite, as outlined in #1203.

Closes #1203 and #1189

<details><summary>Contributors' checklist...</summary>

- [x] Added new tests, or not needed, or not feasible
- [x] Provided an example (e.g. screenshot) to aid review or the PR is
self-explanatory
- [x] Updated the official documentation or not needed
- [x] No breaking changes were made, or a `BREAKING CHANGE: xxx` message
was included in the description
- [x] Added references to related issues and PRs
- [ ] Provided any useful hints for running manual tests
- [ ] Added new benchmarks to [generated
graphs](https://gnoland.github.io/benchmarks), if any. More info
[here](https://github.com/gnolang/gno/blob/master/.benchmarks/README.md).
</details>
gfanton pushed a commit to gfanton/gno that referenced this issue Nov 9, 2023
## Description

This PR introduces the genesis.json command suite, as outlined in gnolang#1203.

Closes gnolang#1203 and gnolang#1189

<details><summary>Contributors' checklist...</summary>

- [x] Added new tests, or not needed, or not feasible
- [x] Provided an example (e.g. screenshot) to aid review or the PR is
self-explanatory
- [x] Updated the official documentation or not needed
- [x] No breaking changes were made, or a `BREAKING CHANGE: xxx` message
was included in the description
- [x] Added references to related issues and PRs
- [ ] Provided any useful hints for running manual tests
- [ ] Added new benchmarks to [generated
graphs](https://gnoland.github.io/benchmarks), if any. More info
[here](https://github.com/gnolang/gno/blob/master/.benchmarks/README.md).
</details>
moul pushed a commit to moul/gno that referenced this issue Nov 14, 2023
## Description

This PR introduces the genesis.json command suite, as outlined in gnolang#1203.

Closes gnolang#1203 and gnolang#1189

<details><summary>Contributors' checklist...</summary>

- [x] Added new tests, or not needed, or not feasible
- [x] Provided an example (e.g. screenshot) to aid review or the PR is
self-explanatory
- [x] Updated the official documentation or not needed
- [x] No breaking changes were made, or a `BREAKING CHANGE: xxx` message
was included in the description
- [x] Added references to related issues and PRs
- [ ] Provided any useful hints for running manual tests
- [ ] Added new benchmarks to [generated
graphs](https://gnoland.github.io/benchmarks), if any. More info
[here](https://github.com/gnolang/gno/blob/master/.benchmarks/README.md).
</details>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: 🌟 Wanted for Launch
Status: Done
Development

Successfully merging a pull request may close this issue.

2 participants