fix(deploy): zero-tap dev-signer deploys (stop bulletin-deploy resolving the phone session)#280
Merged
Merged
Conversation
… the phone session
bulletin-deploy 0.8.x answers empty auth options by resolving the
persisted SSO session from playground init (shared dot-cli namespace)
and phone-signing DotNS, and auto-reads the user's cached
BulletInAllowance slot key for chunk uploads whenever storageSigner is
absent. Dev-mode deploys passed {} and so silently turned into 3-4
phone approvals plus user quota burn for every logged-in user.
Dev mode now pins mnemonic: DEFAULT_MNEMONIC (same bare-root identity
as before) and storageSigner to the dev bare-root; --suri deploys pin
storageSigner to the suri key. Phone mode is unchanged. Owner claiming
(claimedOwnerH160) and the is_dev_signer XP gate are unaffected.
Contributor
|
Dev build ready — try this branch: |
Contributor
E2E Test Pass · ✅ PASSTag:
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.
Problem
playground deploy --signer dev(andplayground decentralisedev mode) started asking for 3-4 phone approvals, defeating the whole point of the dev signer.Root cause
Dev mode passed empty auth options to
bulletin-deploy.deploy(), relying on its old "empty = DEFAULT_MNEMONIC / pool" fallback. bulletin-deploy 0.8.x added two implicit fallbacks that fire on empty options:deploy.tschooseSignerInput): nomnemonic/signer/suri+ a persisted SSO session file at~/.polkadot-apps/dot-cli_SsoSessions.json(written byplayground init; bulletin-deploy reuses thedot-clinamespace) means it loads the SSO stack and phone-signs DotNS with the user's session. Every logged-in user therefore got phone taps in dev mode.storageSigneris absent, it picks up the user's cached BulletInAllowance slot key and signs chunk uploads with it, silently burning the small phone-granted quota (~10 txs / 4 MiB per grant) on dev deploys. This also affected--surideploys.Fix
All in
src/utils/deploy/signerMode.ts(the designated signer-matrix boundary):mnemonic: DEFAULT_MNEMONICexplicitly, which wins bulletin-deploy's signer resolution outright, so the session file is never read. The on-chain identity is unchanged: the mnemonic's bare root (5DfhGyQd…=DEV_PUBLISH_ADDRESS) is exactly what the old empty-options path used for DotNS.resolveStorageSignerOptionsnow pinsstorageSignerin every mode: the BulletInAllowance slot key (phone+session, unchanged), the--surikey, or the dev bare-root. The bare-root carries its own Bulletin authorization on paseo-next-v2 (verified on-chain: 2366 txs / 868 MB remaining); if it ever lapses, bulletin-deploy's committed-signer wrapper silently falls back to the shared pool (the pre-0.8 dev storage path).runDecentralizeflows through the same two functions, so it is fixed by the same change; its displayed signer address now resolves the mnemonic case toDEV_PUBLISH_ADDRESS.Unchanged by design:
productH160as owner, so the app shows in MyApps.is_dev_signer = true, so the registry awards no XP.Testing
authshape reachingrunStorageDeployin bothrunDeployandrunDecentralize.pnpm test: 645/645 passing.pnpm format:checkandpnpm lint:licenseclean.tsc --noEmiterror count unchanged at the 13-error baseline.Includes a changeset and a new CLAUDE.md invariant documenting the gotcha.