Repository navigation
Conversation
Port all of gnodaokit to gno master (2c7f1abe324e, 2026-06-01) and the interrealm v2 specification. Interrealm v2: - Crossing functions take `cur realm` as first param; cross-calls use `cross(cur)`. The realm is threaded only down the Execute path (DAO.Execute(id, rlm) -> Handler.Execute(action, rlm) -> executor), since Propose/Vote do not cross. Non-first realm params are named `rlm`. - Drop the crossing-DAO wrapper: remove crossing.gno, daokit.NewCrossing, the CrossFn config field, and per-realm crossFn helpers. Demos use localDAO and a one-arg setImplem. - Use chain/runtime/unsafe for PreviousRealm/CurrentRealm; keep chain/runtime for the Realm type and ChainHeight. Tests: - Test functions that cross-call take `func TestX(cur realm, t *testing.T)`. - urequire PanicsWithMessage/NotPanics gain the new `rlm realm` arg. Fixes beyond mechanical porting: - Thread the realm through basedao.MigrateFn so the documented migration-via-basedao.New pattern compiles under v2. Tooling and docs: - Bump Makefile GNOVERSION to 2c7f1abe324e8fa6fac6dc71a36635cc4e92a0be. - Update both READMEs to the v2 API (interfaces, Config, Quick Start, custom-resource and migration examples).
gno lint/test download dependencies from the gno.land chain, which lags master. Since the interrealm-v2 port targets bleeding-edge gno, the chain's deployed packages (uassert, onbloc/json, r/demo/profile) no longer build under the pinned toolchain, turning CI red even though our code is correct. scripts/gno-overlay.sh assembles a GNOROOT overlay from the pinned gno version's stdlibs + examples, injects this repo's packages under their on-chain import paths, and runs lint/test against it with -root-dir so every dependency resolves locally instead of from the chain. Also bump GNOVERSION to the latest gno master (ba9da8eb).
go list -m -f '{{.Dir}}' returns an empty Dir until the module is
extracted, so on a fresh CI runner the overlay build ran cp on
/gnovm/stdlibs and failed. go mod download -json both extracts the
source and reports its directory, without touching go.mod/go.sum.
Guard against an empty result so a future breakage fails loudly.
Revert lint/test to `gno lint/test ./gno/...` and remove scripts/gno-overlay.sh: the overlay added too much machinery for the payoff. These targets resolve deps from the gno.land chain, which lags master, so they stay red until gno.land ships interrealm v2; the code itself is verified against gno master. Keeps GNOVERSION at latest master.
|
CI is expected red here, and it is not the code. The code is verified against gno master: lint + test pass locally for every package. CI will go green once gno.land ships interrealm v2. 619929e (AI Agent) |
The quick-start examples still declared the exported DAO var that the interrealm v2 port removed from the demos, and the membership-extension example referenced dao.DAO across realms. Use localDAO like the demos and gate cross-realm membership checks behind a read-only IsMember helper exposed by the DAO realm.
|
Superseded — every part of this landed, nothing is left. Its substantive commit (
Not merged directly because its head does not compile on topaz-1 (two-value Thanks — the port itself is the foundation the whole freeze stack sits on. |
Ports all of gnodaokit to gno master (
2c7f1abe324e, 2026-06-01) and the interrealm v2 specification.Interrealm v2
cur realmas the first param; cross-calls usecross(cur). The realm is threaded only down the Execute path (DAO.Execute(id, rlm)→Handler.Execute(action, rlm)→executor(payload, rlm)), since Propose/Vote do not cross. Realm params that are not first are namedrlm(reserved-name rule).crossing.gno,daokit.NewCrossing, theCrossFnconfig field, and the per-realmcrossFnhelpers. Demos uselocalDAOand a one-argsetImplem.chain/runtime/unsafeforPreviousRealm/CurrentRealm; keepchain/runtimefor theRealmtype andChainHeight.Tests
func TestX(cur realm, t *testing.T).urequirePanicsWithMessage/NotPanicsgain the newrlm realmargument.Fixes beyond mechanical porting
basedao.MigrateFn(func(prev, params, rlm realm)) so the documented migration-via-basedao.Newpattern compiles under v2. The handler already received a realm but discarded it.Tooling and docs
MakefileGNOVERSIONto2c7f1abe324e8fa6fac6dc71a36635cc4e92a0be.gno fixis a clean no-op (nostd.usage remained).Config, Quick Start, custom-resource and migration examples).Verification
Lint exits 0 with zero diagnostics and all tests pass, verified against the exact target gno version via a local monorepo overlay. Note:
make test/make lintresolvegno.land/p/...deps from the live chain, which still lags master, so those targets may fail locally until the chain catches up.🤖 Generated with Claude Code