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

Improve blockchain-less experience of Gnolang/GnoVM #972

Open
moul opened this issue Jul 13, 2023 · 2 comments
Open

Improve blockchain-less experience of Gnolang/GnoVM #972

moul opened this issue Jul 13, 2023 · 2 comments
Assignees
Labels
📖 documentation Improvements or additions to documentation help wanted Extra attention is needed 📦 🤖 gnovm Issues or PRs gnovm related 🌟 improvement performance improvements, refactors ...

Comments

@moul
Copy link
Member

moul commented Jul 13, 2023

Context

The goal is to improve tooling and documentation for an easier transition "from Go to Gno". This includes expanding the applications of Gno beyond chain execution and enabling experimentation with language features (refer to gnolang/hackerspace#15). The proposed tool aims to become a versatile platform for experimenting with language features, including Go2 proposals.

Suggestions

  1. Enhance cmd/gno usage, specifically improving gno run for writing contracts. (Improve gno run #930)
  2. Introduce a compilation mechanism to generate executable units with gno build/install, incorporating contract code and gnovm.
  3. Improve gno to go functionality, either through enhancing gno precompile or introducing gno transpile. This allows Gno contracts to become importable libraries in Go code, leveraging Gno's language features. Consider organizing generated files in a more meaningful manner, such as a subfolder like ~/gno/gno2go/package....
  4. Design a developer-friendly approach for locally fetching on-chain contract state, potentially by generating Go code with an initialization function. Eliminate the need for internet dependencies in Go packages, granting local access to contract state.
  5. Enhance documentation, especially the getting started guides, to provide a comprehensive discovery experience without requiring localnet execution or testnet interaction.
  6. Explore the possibility of multiple parallel sandboxes, such as feature flags for experimental features, "recipes" of language features, or per pull-request playground deployment.
  7. Consider innovative approaches that are safe and explicit, such as a fuse/LD_PRELOAD hack to simulate Gno code as Go code automatically for unmodified Go tools (refer to Gno file compatibility with Go tooling hackerspace#5).

Implementing these ideas can isolate the gnolang/gnovm component from the blockchain aspect, enabling web2-focused presentations and discussions with low-level developers. It also promotes the project's independence, allowing blockchain engineers to focus solely on blockchain topics while treating more gnolang/gnovm as a standalone component.

PS: assigning myself to coordinate the initiative, but looking for help, please.

@moul moul added 📖 documentation Improvements or additions to documentation help wanted Extra attention is needed 📦 🤖 gnovm Issues or PRs gnovm related 🌟 improvement performance improvements, refactors ... labels Jul 13, 2023
@moul moul self-assigned this Jul 13, 2023
@moul
Copy link
Member Author

moul commented Aug 1, 2023

Adding gno serve (gnolang/hackerspace#23)

@moul
Copy link
Member Author

moul commented Oct 11, 2023

In my opinion, there are two straightforward ideas:

  1. Create a blockchain-independent multiuser PoC by building a wrapper around VMKeeper. You can find more details here: Multiuser Gno REPL hackerspace#16. This PoC could provide a HTTP API or a REPL over SSH.
  2. Develop a method to package a Gno contract into an executable file. This would involve embedding the Gno runtime and including an automatic flag to specify a custom location for auto-persisted data. With this approach, we can write CLI programs using versatile "gnolang".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
📖 documentation Improvements or additions to documentation help wanted Extra attention is needed 📦 🤖 gnovm Issues or PRs gnovm related 🌟 improvement performance improvements, refactors ...
Projects
Status: 🐢 Someday/Maybe
Status: 🔵 Not Needed for Launch
Development

No branches or pull requests

2 participants