fix: record mod lineage on-chain + migrate to current meta-registry#229
Merged
UtkarshBhardwaj007 merged 2 commits intoMay 29, 2026
Merged
Conversation
The modded_from argument to the registry publish() call was read from options.moddedFrom, an option no caller sets, so the contract always received "" and never recorded a lineage edge or awarded the source owner the "your app is modded" XP. Route the value dot mod captures in dot.json (via readModdedFrom) into the publish call instead, with the explicit option kept as a fallback. Adds a test that writes a real dot.json and asserts the captured source domain reaches publish().
playground-app and playground-constellation migrated to a freshly deployed CDM meta-registry (0xf62c, target b7a87bf) where @w3s/playground-registry was redeployed at v0 with additive lineage methods (getLineage/getLineageCount). The CLI was still resolving live addresses from the old meta-registry (0xa7ae), so it published to a stale registry the app no longer reads from. Regenerate cdm.json against the new registry + latest ABI (byte-identical to app/constellation), drop the stale target, and bump @dotdm/env to 2.0.2 so dot contract defaults match. The publish() signature is unchanged, so mod lineage flows through modded_from end-to-end.
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
Contributor
|
Dev build ready — try this branch: |
Contributor
E2E Test Pass · ❌ FAILTag:
Sentry traces: view spans for this run |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Two related fixes so
dot deploy --playgroundactually records mod lineage that playground-app and playground-constellation can display.1. Record mod lineage on-chain
The
modded_fromargument to the registrypublish()call was read fromoptions.moddedFrom— an option no caller ever sets — so the contract always received""and never recorded a lineage edge or awarded the source owner the "your app is modded" XP. The valuedot modcaptures indot.json(read viareadModdedFrom) was only used for the off-chain Bulletin metadata blob, not the on-chain argument.Fix: route the captured
dot.jsonvalue into the publish call, keeping the explicit option as a fallback. Adds a test that writes a realdot.jsonand asserts the source domain reachespublish().2. Migrate to the current CDM meta-registry
playground-app and playground-constellation migrated to a freshly deployed meta-registry (
0xf62c2ece…, targetb7a87bf…) where@w3s/playground-registrywas redeployed at v0 with additive lineage methods (getLineage/getLineageCount). The CLI was still resolving live contract addresses from the old meta-registry (0xa7ae171c…), so it published to a stale registry the app no longer reads from — and the contract's source-exists check (Storage::info().contains(&modded_from)) would silently drop every lineage edge.Fix: regenerate
cdm.jsonagainst the new registry + latest ABI (byte-identical to app/constellation), drop the stale target, and bump@dotdm/envto 2.0.2 sodot contractfallback defaults match. Thepublish()signature is unchanged.Both fixes are required: #1 passes the value, #2 ensures the source app exists on the registry the CLI publishes to.
Verification
cdm.jsoncheck: CLI, app, and constellation agree on targetb7a87bf…, registry0xf62c…, contract0x1C12456f…v0, and a byte-identical@w3s/playground-registryABI (incl.getLineage/getLineageCount).dot modwritesmoddedFrom→ publish passesmodded_from→ contract recordsLineageEdge { child, source }(registry/lib.rs:755) → constellation reads it viagetLineage(reads.ts:loadLineage).pnpm format:check,pnpm lint:license,pnpm build,pnpm test(594 passed, 1 skipped) all green.Notes
dot mod Bto create C setsmoddedFrom=B(immediate parent), not A. Constellation reconstructs the full tree from individual edges.import_lineageadmin backfill.