fix(cli): supply the persist field on subname registration and sync the v0.7.0 ABIs - #297
fix(cli): supply the persist field on subname registration and sync the v0.7.0 ABIs#297filip-parity wants to merge 1 commit into
Conversation
CI Summary
Release - PassedTest this PR Download artifact (GitHub CLI required): gh run download 34730637395 -n cli-release-0.0.0-pr.297 -R paritytech/dotns-sdkInstall globally: npm install -g ./parity-dotns-cli-0.0.0-pr.297.tgzVerify: dotns --helpDeploy Example — Passed
Labelspkg: cli, dependencies Test - Passed320 passed, 0 failed across 320 tests. |
…he v0.7.0 ABIs The v0.7.0 registry's SubnodeRecord carries a persist flag deciding whether the subname is indexed into the owner's LabelStore. The CLI never set it: released 0.9.1 fails at encoding (its build-time ABI has the field), and the committed v0.6.0 ABIs miss the new selector entirely. registerSubnode now persists by default with --no-persist to opt out, and the committed ABIs move to the v0.7.0 release, matching the deployed reference chain. Verified on paseo-v2 (v0.7.0): register subname completes and the name resolves with its owner; 0.9.1 fails with 'Invalid boolean value'. Fixes the issuance half of paritytech/dotns#285 (the lite-read half shipped in 0.9.1).
69ef946 to
dff0e2f
Compare
|
We should make it true by default for public paths only pop names avoid persisting since they dont have runtime limitations and those names eventually settle when the user claims their store via tooling WDYT? |
re-gius
left a comment
There was a problem hiding this comment.
Nit: help/parse coverage exists for register subname, but nothing asserts the encoded SubnodeRecord actually carries persist: true (or false under --no-persist). A small unit test would stop this class of ABI drift from showing up as a runtime encode error again.
Otherwise LGTM
My take: this path is signed CLI register subname, so persist correctly stays on by default. PoP already skips persist in the controller and the user claims the store later, so I'm fine with the current status of this PR. |
Description
Two things the v0.7.0 registry needs that the CLI doesn't do:
SubnodeRecordgained apersistflag (index the subname into the owner's Label Store, or write only the record). The code never set it, so released 0.9.1 dies at encoding withInvalid boolean value: "undefined".registerSubnodenow persists by default,--no-persistopts out.setSubnodeOwnerselector no longer exists on the deployed chain — synced to v0.7.0. (npm builds resync at release time, which is why 0.9.1's failure was the encode rather than a revert.)Covers the issuance half of paritytech/dotns#285; the lite-read half shipped in 0.9.1.
Type
Package
@parity/dotns-cliTesting
Live on paseo-v2 (v0.7.0):
register subname -n vzerosub -p filipverifyninezerocompletes (tx0xc5b80088…) andlookup name vzerosub.filipverifyninezeroresolves with its owner. Same command on 0.9.1 fails at encoding. 320 unit tests, typecheck, lint green.Version bumped to 0.9.2 for the release guard.