v0 source realm
untrusted-render: live is the only stored string Render echoes, and SetLive validates it with assertPkgPath before st...
View source
gno.land/r/moul/x/upgrade/store/root/v0
The data realm of pattern C. Holds the counter and grants write access to
exactly one logic realm at a time, identified by the package path read off the
crossing frame. SetLive(path) is the upgrade.
See the pattern and the exploration.
Part of moul/gno-contracts — moul's versioned gno.land contracts. See the repository for the full catalog, build/test tooling, and usage.
Dependency graph:

🧪 Highly experimental — potentially vibe-coded. Not audited; may break, change, or be removed at any time. Do not use with anything of value. Full disclaimer: DISCLAIMER.
untrusted-render: live is the only stored string Render echoes, and SetLive validates it with assertPkgPath before storing it.
Package root is the data realm of the "state realm + swappable logic" upgrade pattern (pattern C of the exploration; see ../../README.md).
root holds the state and nothing else worth changing. It grants write access to exactly one logic realm at a time, identified by package path off the crossing frame rather than passed in as an argument, so a logic realm cannot claim to be a path it does not occupy. Upgrading is a single SetLive call: no migration, no downtime, and the data never moves.
1
5
func Get
ActionGet is open to everyone: the data is public, only writes are gated.
func Inc
crossing ActionInc adds n to the stored counter. Only the live logic realm may call it.
func Live
ActionLive is the package path currently allowed to write.
func Render
func SetLive
crossing ActionSetLive hands write access to another logic realm. This is the upgrade.
3
- gno.land/p/nt/ownable/v0 package
- gno.land/p/nt/ufmt/v0 package
- strings stdlib