bulletin-deploy 0.20.0-rc.1 → 0.20.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (87) hide show
  1. package/bin/bulletin-deploy +4 -0
  2. package/dist/auth/index.d.ts +5 -4
  3. package/dist/auth/index.js +17 -8
  4. package/dist/{allocations-CEPeZr6T.d.ts → auth/vendor/allocations.d.ts} +1 -1
  5. package/dist/auth/vendor/allocations.js +14 -0
  6. package/dist/{auth-CA_YKtM2.d.ts → auth/vendor/auth.d.ts} +3 -26
  7. package/dist/auth/vendor/auth.js +10 -0
  8. package/dist/auth/vendor/index.d.ts +7 -31
  9. package/dist/auth/vendor/index.js +16 -9
  10. package/dist/auth/vendor/sessionSigner.d.ts +28 -0
  11. package/dist/auth/vendor/sessionSigner.js +14 -0
  12. package/dist/{signer-Duup0hgQ.d.ts → auth/vendor/signer.d.ts} +5 -2
  13. package/dist/auth/vendor/signer.js +10 -0
  14. package/dist/auth/vendor/types.d.ts +25 -0
  15. package/dist/auth/vendor/types.js +0 -0
  16. package/dist/auth/vendor/ui/index.d.ts +4 -13
  17. package/dist/auth/vendor/ui/index.js +6 -3
  18. package/dist/auth/vendor/ui/qr.d.ts +1 -0
  19. package/dist/auth/vendor/ui/qr.js +6 -0
  20. package/dist/auth/vendor/ui/status.d.ts +16 -0
  21. package/dist/auth/vendor/ui/status.js +8 -0
  22. package/dist/auth-config.d.ts +12 -3
  23. package/dist/auth-config.js +6 -4
  24. package/dist/bug-report.js +4 -4
  25. package/dist/chain-health.js +3 -3
  26. package/dist/{chunk-IJ3ONWE7.js → chunk-26ZYMWSC.js} +4 -1
  27. package/dist/chunk-2C6SLLBI.js +57 -0
  28. package/dist/{chunk-QKEZK2M6.js → chunk-3BSPX4JN.js} +3 -3
  29. package/dist/chunk-6GHDPDZN.js +59 -0
  30. package/dist/chunk-7SXO544V.js +40 -0
  31. package/dist/{chunk-567ZRMI6.js → chunk-BXDMEOLH.js} +1 -1
  32. package/dist/chunk-DBDOISNQ.js +120 -0
  33. package/dist/chunk-DFKEG3WY.js +0 -0
  34. package/dist/{chunk-JYVJRJ7H.js → chunk-DHHHYZTR.js} +1 -1
  35. package/dist/{chunk-JBMBQFCO.js → chunk-DT6ABL3J.js} +8 -8
  36. package/dist/{chunk-FR73P4GO.js → chunk-EBYWI7FI.js} +31 -30
  37. package/dist/{chunk-H44NO63C.js → chunk-G7EH3XIW.js} +8 -185
  38. package/dist/{chunk-KACRAHSV.js → chunk-IF3SANQR.js} +6 -4
  39. package/dist/{chunk-JYJQNITR.js → chunk-IHC2QG2L.js} +12 -122
  40. package/dist/{chunk-NGVCDMLS.js → chunk-LRRFXOLE.js} +3 -3
  41. package/dist/{chunk-IUPVNIVY.js → chunk-MTXFJTX6.js} +1 -1
  42. package/dist/chunk-NJKXXDDK.js +0 -0
  43. package/dist/{chunk-4GDRFJER.js → chunk-QBHUCTVT.js} +1 -1
  44. package/dist/chunk-RHCXBXBW.js +17 -0
  45. package/dist/chunk-RPBMNTGZ.js +6 -0
  46. package/dist/chunk-S6CPT2TU.js +94 -0
  47. package/dist/{chunk-SKL6ULZN.js → chunk-YIVCOJAB.js} +109 -79
  48. package/dist/{chunk-A3VWIJKO.js → chunk-YLLTQM5Z.js} +2 -2
  49. package/dist/{chunk-RIRDBSBG.js → chunk-YP3LINCF.js} +0 -4
  50. package/dist/chunk-probe.js +3 -3
  51. package/dist/cli-name.d.ts +3 -0
  52. package/dist/cli-name.js +6 -0
  53. package/dist/code-paths.d.ts +24 -0
  54. package/dist/code-paths.js +6 -0
  55. package/dist/commands/login.d.ts +1 -1
  56. package/dist/commands/login.js +27 -19
  57. package/dist/commands/logout.d.ts +3 -2
  58. package/dist/commands/logout.js +13 -7
  59. package/dist/commands/transfer.js +11 -9
  60. package/dist/commands/whoami.d.ts +3 -2
  61. package/dist/commands/whoami.js +6 -6
  62. package/dist/deploy-actors.d.ts +4 -3
  63. package/dist/deploy-actors.js +19 -11
  64. package/dist/deploy.d.ts +1 -1
  65. package/dist/deploy.js +25 -17
  66. package/dist/dotns.d.ts +40 -27
  67. package/dist/dotns.js +8 -6
  68. package/dist/index.d.ts +3 -48
  69. package/dist/index.js +32 -22
  70. package/dist/manifest/product-preflight.d.ts +46 -0
  71. package/dist/manifest/product-preflight.js +17 -0
  72. package/dist/manifest/publish.js +27 -18
  73. package/dist/memory-report.js +2 -2
  74. package/dist/merkle.js +25 -17
  75. package/dist/personhood/bootstrap.js +19 -16
  76. package/dist/personhood/people-client.js +10 -7
  77. package/dist/pool.js +6 -1
  78. package/dist/run-state.js +1 -1
  79. package/dist/sss-allowance-cache.js +5 -5
  80. package/dist/storage-signer.js +25 -17
  81. package/dist/telemetry.d.ts +1 -23
  82. package/dist/telemetry.js +2 -2
  83. package/dist/version-check.js +3 -3
  84. package/dist/ws.d.ts +12 -0
  85. package/dist/ws.js +16 -0
  86. package/package.json +3 -3
  87. /package/dist/{chunk-TSPERKUS.js → chunk-DNXE3Q5D.js} +0 -0
@@ -13,9 +13,13 @@ import { setDeployContext, installLogCapture, buildCliFlagsSummary } from "../di
13
13
  import { loadRunState, writeRunState, shouldSkipStaleWarning, shouldShowOomHint, probablyOomRssMb } from "../dist/run-state.js";
14
14
  import { loadEnvironments, listEnvironments, formatEnvironmentTable, resolveEndpoints, DEFAULT_ENV_ID } from "../dist/environments.js";
15
15
  import { DEFAULT_TLD } from "../dist/dotns.js";
16
+ import { GuardedWebSocket } from "../dist/ws.js";
16
17
  import * as fs from "fs";
17
18
  import * as readline from "readline";
18
19
 
20
+ // The SSO SDKs build their own papi providers from the global WebSocket.
21
+ globalThis.WebSocket = GuardedWebSocket;
22
+
19
23
  // Install early so anything printed during flag parsing / preflight is
20
24
  // available to the bug-report log tail.
21
25
  installLogCapture();
@@ -1,7 +1,8 @@
1
- export { A as AuthClient, a as AuthConfig, C as ConnectResult, L as LoginHandle, b as LoginStatus, c as LogoutHandle, d as LogoutStatus, S as SessionAddresses, e as SessionHandle, f as createAuthClient } from '../auth-CA_YKtM2.js';
1
+ export { AuthClient, ConnectResult, LoginHandle, LoginStatus, LogoutHandle, LogoutStatus, SessionAddresses, SessionHandle, createAuthClient } from './vendor/auth.js';
2
2
  export { renderQrCode } from '@parity/product-sdk-terminal';
3
- export { R as ResolvedSigner, S as SignerNotAvailableError, r as resolveSigner } from '../signer-Duup0hgQ.js';
4
- export { A as AllocatableResource, a as AllocationOutcome, b as AllocationSummary, B as BULLETIN_RESOURCE, D as DEFAULT_RESOURCES, c as createSlotAccountSigner, r as requestResourceAllocation, s as summarizeOutcomes } from '../allocations-CEPeZr6T.js';
5
- export { renderLoginStatus, renderLogoutStatus } from './vendor/ui/index.js';
3
+ export { ResolvedSigner, SignerNotAvailableError, resolveSigner } from './vendor/signer.js';
4
+ export { AllocatableResource, AllocationOutcome, AllocationSummary, BULLETIN_RESOURCE, DEFAULT_RESOURCES, createSlotAccountSigner, requestResourceAllocation, summarizeOutcomes } from './vendor/allocations.js';
5
+ export { AuthConfig } from './vendor/types.js';
6
+ export { renderLoginStatus, renderLogoutStatus } from './vendor/ui/status.js';
6
7
  import 'polkadot-api';
7
8
  import '@parity/product-sdk-tx';
@@ -1,21 +1,30 @@
1
1
  import "../chunk-JQKKMUCT.js";
2
+ import "../chunk-DFKEG3WY.js";
2
3
  import {
3
- renderLoginStatus,
4
- renderLogoutStatus,
5
4
  renderQrCode
6
- } from "../chunk-RIRDBSBG.js";
5
+ } from "../chunk-RPBMNTGZ.js";
6
+ import {
7
+ renderLoginStatus,
8
+ renderLogoutStatus
9
+ } from "../chunk-YP3LINCF.js";
10
+ import "../chunk-NJKXXDDK.js";
11
+ import {
12
+ createAuthClient
13
+ } from "../chunk-G7EH3XIW.js";
7
14
  import {
8
15
  BULLETIN_RESOURCE,
9
16
  DEFAULT_RESOURCES,
10
- SignerNotAvailableError,
11
- createAuthClient,
12
17
  createSlotAccountSigner,
13
18
  requestResourceAllocation,
14
- resolveSigner,
15
19
  summarizeOutcomes
16
- } from "../chunk-H44NO63C.js";
17
- import "../chunk-TSPERKUS.js";
20
+ } from "../chunk-7SXO544V.js";
21
+ import "../chunk-S6CPT2TU.js";
22
+ import {
23
+ SignerNotAvailableError,
24
+ resolveSigner
25
+ } from "../chunk-2C6SLLBI.js";
18
26
  import "../chunk-SH2LG52Z.js";
27
+ import "../chunk-DNXE3Q5D.js";
19
28
  export {
20
29
  BULLETIN_RESOURCE,
21
30
  DEFAULT_RESOURCES,
@@ -108,4 +108,4 @@ declare function summarizeOutcomes(outcomes: AllocationOutcome[], resources: All
108
108
  */
109
109
  declare function createSlotAccountSigner(adapter: TerminalAdapter, resource: AllocatableResource): Promise<polkadot_api.PolkadotSigner | null>;
110
110
 
111
- export { type AllocatableResource as A, BULLETIN_RESOURCE as B, DEFAULT_RESOURCES as D, type OnExistingAllowancePolicy as O, type ResourceTag as R, type AllocationOutcome as a, type AllocationSummary as b, createSlotAccountSigner as c, requestResourceAllocation as r, summarizeOutcomes as s };
111
+ export { type AllocatableResource, type AllocationOutcome, type AllocationSummary, BULLETIN_RESOURCE, DEFAULT_RESOURCES, type OnExistingAllowancePolicy, type ResourceTag, createSlotAccountSigner, requestResourceAllocation, summarizeOutcomes };
@@ -0,0 +1,14 @@
1
+ import {
2
+ BULLETIN_RESOURCE,
3
+ DEFAULT_RESOURCES,
4
+ createSlotAccountSigner,
5
+ requestResourceAllocation,
6
+ summarizeOutcomes
7
+ } from "../../chunk-7SXO544V.js";
8
+ export {
9
+ BULLETIN_RESOURCE,
10
+ DEFAULT_RESOURCES,
11
+ createSlotAccountSigner,
12
+ requestResourceAllocation,
13
+ summarizeOutcomes
14
+ };
@@ -1,30 +1,7 @@
1
1
  import { TerminalAdapter, UserSession } from '@parity/product-sdk-terminal';
2
2
  import { PolkadotSigner } from 'polkadot-api';
3
- import { A as AllocatableResource, O as OnExistingAllowancePolicy, a as AllocationOutcome } from './allocations-CEPeZr6T.js';
4
-
5
- /**
6
- * Per-product configuration injected into `createAuthClient`. Lifting the
7
- * sign-in glue out of playground-cli (issue #411) means the env-specific
8
- * constants playground hard-coded in its `config.ts` (DAPP_ID, product id,
9
- * metadata URL, People-chain endpoints) become consumer-supplied so the same
10
- * package serves `playground` and `dot` (and future products) unchanged.
11
- */
12
- interface AuthConfig {
13
- /** The dApp identity string. Scopes the on-disk session namespace
14
- * (`~/.polkadot-apps/${dappId}_*`) and the SSO pairing — each product
15
- * gets its own, independently-revocable session. */
16
- dappId: string;
17
- /** Product id used to derive the product account (`/product/{productId}/{index}`). */
18
- productId: string;
19
- /** Derivation index of the product account (0 = default). */
20
- derivationIndex: number;
21
- /** Wallet-facing app name shown on the Sign-In screen (sent inline at pairing). */
22
- hostName: string;
23
- /** Host app version sent inline at pairing. */
24
- hostVersion: string;
25
- /** People-parachain RPC endpoints the terminal adapter connects to. */
26
- peopleEndpoints: string[];
27
- }
3
+ import { AllocatableResource, OnExistingAllowancePolicy, AllocationOutcome } from './allocations.js';
4
+ import { AuthConfig } from './types.js';
28
5
 
29
6
  /**
30
7
  * The three addresses we surface from a paired session.
@@ -125,4 +102,4 @@ interface AuthClient {
125
102
  */
126
103
  declare function createAuthClient(config: AuthConfig): AuthClient;
127
104
 
128
- export { type AuthClient as A, type ConnectResult as C, type LoginHandle as L, type SessionAddresses as S, type AuthConfig as a, type LoginStatus as b, type LogoutHandle as c, type LogoutStatus as d, type SessionHandle as e, createAuthClient as f };
105
+ export { type AuthClient, type ConnectResult, type LoginHandle, type LoginStatus, type LogoutHandle, type LogoutStatus, type SessionAddresses, type SessionHandle, createAuthClient };
@@ -0,0 +1,10 @@
1
+ import {
2
+ createAuthClient
3
+ } from "../../chunk-G7EH3XIW.js";
4
+ import "../../chunk-7SXO544V.js";
5
+ import "../../chunk-S6CPT2TU.js";
6
+ import "../../chunk-SH2LG52Z.js";
7
+ import "../../chunk-DNXE3Q5D.js";
8
+ export {
9
+ createAuthClient
10
+ };
@@ -1,32 +1,8 @@
1
- export { A as AuthClient, a as AuthConfig, C as ConnectResult, L as LoginHandle, b as LoginStatus, c as LogoutHandle, d as LogoutStatus, S as SessionAddresses, e as SessionHandle, f as createAuthClient } from '../../auth-CA_YKtM2.js';
2
- import { UserSession } from '@parity/product-sdk-terminal';
3
- import { PolkadotSigner } from 'polkadot-api';
4
- export { R as ResolvedSigner, S as SignerNotAvailableError, a as SignerOptions, b as SignerSource, p as parseDevAccountName, r as resolveSigner } from '../../signer-Duup0hgQ.js';
5
- export { A as AllocatableResource, a as AllocationOutcome, b as AllocationSummary, B as BULLETIN_RESOURCE, D as DEFAULT_RESOURCES, O as OnExistingAllowancePolicy, R as ResourceTag, c as createSlotAccountSigner, r as requestResourceAllocation, s as summarizeOutcomes } from '../../allocations-CEPeZr6T.js';
1
+ export { AuthClient, ConnectResult, LoginHandle, LoginStatus, LogoutHandle, LogoutStatus, SessionAddresses, SessionHandle, createAuthClient } from './auth.js';
2
+ export { INCOMPLETE_SESSION_MESSAGE, ProductAccountRef, createSessionSigner, deriveProductPublicKey, sessionRootPublicKey } from './sessionSigner.js';
3
+ export { ResolvedSigner, SignerNotAvailableError, SignerOptions, SignerSource, parseDevAccountName, resolveSigner } from './signer.js';
4
+ export { AllocatableResource, AllocationOutcome, AllocationSummary, BULLETIN_RESOURCE, DEFAULT_RESOURCES, OnExistingAllowancePolicy, ResourceTag, createSlotAccountSigner, requestResourceAllocation, summarizeOutcomes } from './allocations.js';
5
+ export { AuthConfig } from './types.js';
6
+ import '@parity/product-sdk-terminal';
7
+ import 'polkadot-api';
6
8
  import '@parity/product-sdk-tx';
7
-
8
- interface ProductAccountRef {
9
- productId: string;
10
- derivationIndex: number;
11
- }
12
- declare const INCOMPLETE_SESSION_MESSAGE = "Stored login session is missing the root account public key. Run \"logout\" and then \"login\" to pair again.";
13
- declare function sessionRootPublicKey(session: UserSession): Uint8Array;
14
- /**
15
- * Soft-derive the product account public key off a wallet root.
16
- *
17
- * This is the single source of truth for product-account math. Both
18
- * `createSessionSigner` (which builds the signer used to actually sign
19
- * on-chain) and `deriveSessionAddresses` (which builds the display triple)
20
- * go through here so a future change to derivation params can't silently
21
- * desync the signer from what we print.
22
- *
23
- * sr25519 soft derivation is composable on public keys alone, so deriving
24
- * from `rootAccountId` locally produces the SAME public key the mobile
25
- * derives privately via `mnemonic + "/product/...{idx}"`. Algorithm parity
26
- * with mobile/desktop is locked by the frozen vectors in
27
- * `@parity/product-sdk-keys`'s `product-account.test.ts`.
28
- */
29
- declare function deriveProductPublicKey(rootAccountId: Uint8Array, ref: ProductAccountRef): Uint8Array;
30
- declare function createSessionSigner(session: UserSession, ref: ProductAccountRef): PolkadotSigner;
31
-
32
- export { INCOMPLETE_SESSION_MESSAGE, type ProductAccountRef, createSessionSigner, deriveProductPublicKey, sessionRootPublicKey };
@@ -1,20 +1,27 @@
1
+ import "../../chunk-NJKXXDDK.js";
2
+ import {
3
+ createAuthClient
4
+ } from "../../chunk-G7EH3XIW.js";
1
5
  import {
2
6
  BULLETIN_RESOURCE,
3
7
  DEFAULT_RESOURCES,
8
+ createSlotAccountSigner,
9
+ requestResourceAllocation,
10
+ summarizeOutcomes
11
+ } from "../../chunk-7SXO544V.js";
12
+ import {
4
13
  INCOMPLETE_SESSION_MESSAGE,
5
- SignerNotAvailableError,
6
- createAuthClient,
7
14
  createSessionSigner,
8
- createSlotAccountSigner,
9
15
  deriveProductPublicKey,
16
+ sessionRootPublicKey
17
+ } from "../../chunk-S6CPT2TU.js";
18
+ import {
19
+ SignerNotAvailableError,
10
20
  parseDevAccountName,
11
- requestResourceAllocation,
12
- resolveSigner,
13
- sessionRootPublicKey,
14
- summarizeOutcomes
15
- } from "../../chunk-H44NO63C.js";
16
- import "../../chunk-TSPERKUS.js";
21
+ resolveSigner
22
+ } from "../../chunk-2C6SLLBI.js";
17
23
  import "../../chunk-SH2LG52Z.js";
24
+ import "../../chunk-DNXE3Q5D.js";
18
25
  export {
19
26
  BULLETIN_RESOURCE,
20
27
  DEFAULT_RESOURCES,
@@ -0,0 +1,28 @@
1
+ import { UserSession } from '@parity/product-sdk-terminal';
2
+ import { PolkadotSigner } from 'polkadot-api';
3
+
4
+ interface ProductAccountRef {
5
+ productId: string;
6
+ derivationIndex: number;
7
+ }
8
+ declare const INCOMPLETE_SESSION_MESSAGE = "Stored login session is missing the root account public key. Run \"logout\" and then \"login\" to pair again.";
9
+ declare function sessionRootPublicKey(session: UserSession): Uint8Array;
10
+ /**
11
+ * Soft-derive the product account public key off a wallet root.
12
+ *
13
+ * This is the single source of truth for product-account math. Both
14
+ * `createSessionSigner` (which builds the signer used to actually sign
15
+ * on-chain) and `deriveSessionAddresses` (which builds the display triple)
16
+ * go through here so a future change to derivation params can't silently
17
+ * desync the signer from what we print.
18
+ *
19
+ * sr25519 soft derivation is composable on public keys alone, so deriving
20
+ * from `rootAccountId` locally produces the SAME public key the mobile
21
+ * derives privately via `mnemonic + "/product/...{idx}"`. Algorithm parity
22
+ * with mobile/desktop is locked by the frozen vectors in
23
+ * `@parity/product-sdk-keys`'s `product-account.test.ts`.
24
+ */
25
+ declare function deriveProductPublicKey(rootAccountId: Uint8Array, ref: ProductAccountRef): Uint8Array;
26
+ declare function createSessionSigner(session: UserSession, ref: ProductAccountRef): PolkadotSigner;
27
+
28
+ export { INCOMPLETE_SESSION_MESSAGE, type ProductAccountRef, createSessionSigner, deriveProductPublicKey, sessionRootPublicKey };
@@ -0,0 +1,14 @@
1
+ import {
2
+ INCOMPLETE_SESSION_MESSAGE,
3
+ createSessionSigner,
4
+ deriveProductPublicKey,
5
+ sessionRootPublicKey
6
+ } from "../../chunk-S6CPT2TU.js";
7
+ import "../../chunk-SH2LG52Z.js";
8
+ import "../../chunk-DNXE3Q5D.js";
9
+ export {
10
+ INCOMPLETE_SESSION_MESSAGE,
11
+ createSessionSigner,
12
+ deriveProductPublicKey,
13
+ sessionRootPublicKey
14
+ };
@@ -1,6 +1,9 @@
1
1
  import { DevAccountName } from '@parity/product-sdk-tx';
2
2
  import { PolkadotSigner } from 'polkadot-api';
3
- import { e as SessionHandle, S as SessionAddresses, A as AuthClient } from './auth-CA_YKtM2.js';
3
+ import { SessionHandle, SessionAddresses, AuthClient } from './auth.js';
4
+ import '@parity/product-sdk-terminal';
5
+ import './allocations.js';
6
+ import './types.js';
4
7
 
5
8
  type SignerSource = "dev" | "session";
6
9
  interface ResolvedSigner {
@@ -32,4 +35,4 @@ declare function parseDevAccountName(suri: string): DevAccountName | null;
32
35
  */
33
36
  declare function resolveSigner(authClient: AuthClient, options?: SignerOptions): Promise<ResolvedSigner>;
34
37
 
35
- export { type ResolvedSigner as R, SignerNotAvailableError as S, type SignerOptions as a, type SignerSource as b, parseDevAccountName as p, resolveSigner as r };
38
+ export { type ResolvedSigner, SignerNotAvailableError, type SignerOptions, type SignerSource, parseDevAccountName, resolveSigner };
@@ -0,0 +1,10 @@
1
+ import {
2
+ SignerNotAvailableError,
3
+ parseDevAccountName,
4
+ resolveSigner
5
+ } from "../../chunk-2C6SLLBI.js";
6
+ export {
7
+ SignerNotAvailableError,
8
+ parseDevAccountName,
9
+ resolveSigner
10
+ };
@@ -0,0 +1,25 @@
1
+ /**
2
+ * Per-product configuration injected into `createAuthClient`. Lifting the
3
+ * sign-in glue out of playground-cli (issue #411) means the env-specific
4
+ * constants playground hard-coded in its `config.ts` (DAPP_ID, product id,
5
+ * metadata URL, People-chain endpoints) become consumer-supplied so the same
6
+ * package serves `playground` and `dot` (and future products) unchanged.
7
+ */
8
+ interface AuthConfig {
9
+ /** The dApp identity string. Scopes the on-disk session namespace
10
+ * (`~/.polkadot-apps/${dappId}_*`) and the SSO pairing — each product
11
+ * gets its own, independently-revocable session. */
12
+ dappId: string;
13
+ /** Product id used to derive the product account (`/product/{productId}/{index}`). */
14
+ productId: string;
15
+ /** Derivation index of the product account (0 = default). */
16
+ derivationIndex: number;
17
+ /** Wallet-facing app name shown on the Sign-In screen (sent inline at pairing). */
18
+ hostName: string;
19
+ /** Host app version sent inline at pairing. */
20
+ hostVersion: string;
21
+ /** People-parachain RPC endpoints the terminal adapter connects to. */
22
+ peopleEndpoints: string[];
23
+ }
24
+
25
+ export type { AuthConfig };
File without changes
@@ -1,15 +1,6 @@
1
1
  export { renderQrCode } from '@parity/product-sdk-terminal';
2
- import { b as LoginStatus, d as LogoutStatus } from '../../../auth-CA_YKtM2.js';
2
+ export { renderLoginStatus, renderLogoutStatus } from './status.js';
3
+ import '../auth.js';
3
4
  import 'polkadot-api';
4
- import '../../../allocations-CEPeZr6T.js';
5
-
6
- /**
7
- * Pure formatters that map the `LoginStatus` / `LogoutStatus` streams to
8
- * one-line terminal messages. No I/O, no terminal deps — `import type` only,
9
- * so this module stays unit-testable without the SSO stack.
10
- */
11
-
12
- declare function renderLoginStatus(status: LoginStatus): string;
13
- declare function renderLogoutStatus(status: LogoutStatus): string;
14
-
15
- export { renderLoginStatus, renderLogoutStatus };
5
+ import '../allocations.js';
6
+ import '../types.js';
@@ -1,8 +1,11 @@
1
+ import "../../../chunk-DFKEG3WY.js";
1
2
  import {
2
- renderLoginStatus,
3
- renderLogoutStatus,
4
3
  renderQrCode
5
- } from "../../../chunk-RIRDBSBG.js";
4
+ } from "../../../chunk-RPBMNTGZ.js";
5
+ import {
6
+ renderLoginStatus,
7
+ renderLogoutStatus
8
+ } from "../../../chunk-YP3LINCF.js";
6
9
  export {
7
10
  renderLoginStatus,
8
11
  renderLogoutStatus,
@@ -0,0 +1 @@
1
+ export { renderQrCode } from '@parity/product-sdk-terminal';
@@ -0,0 +1,6 @@
1
+ import {
2
+ renderQrCode
3
+ } from "../../../chunk-RPBMNTGZ.js";
4
+ export {
5
+ renderQrCode
6
+ };
@@ -0,0 +1,16 @@
1
+ import '@parity/product-sdk-terminal';
2
+ import { LoginStatus, LogoutStatus } from '../auth.js';
3
+ import 'polkadot-api';
4
+ import '../allocations.js';
5
+ import '../types.js';
6
+
7
+ /**
8
+ * Pure formatters that map the `LoginStatus` / `LogoutStatus` streams to
9
+ * one-line terminal messages. No I/O, no terminal deps — `import type` only,
10
+ * so this module stays unit-testable without the SSO stack.
11
+ */
12
+
13
+ declare function renderLoginStatus(status: LoginStatus): string;
14
+ declare function renderLogoutStatus(status: LogoutStatus): string;
15
+
16
+ export { renderLoginStatus, renderLogoutStatus };
@@ -0,0 +1,8 @@
1
+ import {
2
+ renderLoginStatus,
3
+ renderLogoutStatus
4
+ } from "../../../chunk-YP3LINCF.js";
5
+ export {
6
+ renderLoginStatus,
7
+ renderLogoutStatus
8
+ };
@@ -1,8 +1,9 @@
1
- import { a as AuthConfig, A as AuthClient } from './auth-CA_YKtM2.js';
1
+ import { AuthClient } from './auth/vendor/auth.js';
2
+ import { AuthConfig } from './auth/vendor/types.js';
2
3
  import { EnvironmentsDoc } from './environments.js';
3
4
  import '@parity/product-sdk-terminal';
4
5
  import 'polkadot-api';
5
- import './allocations-CEPeZr6T.js';
6
+ import './auth/vendor/allocations.js';
6
7
 
7
8
  /** dApp identity: scopes the SSO session namespace + terminal allowance cache on disk
8
9
  * and the wallet pairing product. Aligned to the app's dedicated id "polkadot-app-deploy". */
@@ -24,6 +25,14 @@ declare const DOT_HOST_NAME = "polkadot-app-deploy";
24
25
  * The adapter silently returns [] in this case; we surface the cause and recovery steps.
25
26
  */
26
27
  declare const STALE_SESSION_MESSAGE: string;
28
+ /**
29
+ * Deploy-specific variant of STALE_SESSION_MESSAGE. See src/deploy-actors.ts's
30
+ * resolveDeployActors for the full rationale (issue #234) — in short, `deploy`
31
+ * has a remedy `whoami` doesn't: an explicit `--mnemonic` / `MNEMONIC` signer,
32
+ * which wins even when the persisted session can't be read. Naming it here
33
+ * means the fail-fast error doesn't just point at re-pairing.
34
+ */
35
+ declare const STALE_SESSION_DEPLOY_MESSAGE = "Stored login session could not be read \u2014 it may have been written by an older version. Run \"bulletin-deploy logout\", then \"bulletin-deploy login\" to pair again. Or pass --mnemonic explicitly to sign with a different key.";
27
36
  /**
28
37
  * Returns true if there is a persisted SSO session file on disk.
29
38
  * Does NOT load the SSO stack — uses only node fs/os/path.
@@ -63,4 +72,4 @@ declare function getPeopleChainEndpoints(envId: string): Promise<string[]>;
63
72
  */
64
73
  declare function getAuthClient(envId: string): Promise<AuthClient>;
65
74
 
66
- export { DOT_DAPP_ID, DOT_DERIVATION_INDEX, DOT_HOST_NAME, DOT_PRODUCT_ID, STALE_SESSION_MESSAGE, buildAuthConfig, getAuthClient, getPeopleChainEndpoints, hasPersistedSession, resolveBulletinEndpoints };
75
+ export { DOT_DAPP_ID, DOT_DERIVATION_INDEX, DOT_HOST_NAME, DOT_PRODUCT_ID, STALE_SESSION_DEPLOY_MESSAGE, STALE_SESSION_MESSAGE, buildAuthConfig, getAuthClient, getPeopleChainEndpoints, hasPersistedSession, resolveBulletinEndpoints };
@@ -3,23 +3,25 @@ import {
3
3
  DOT_DERIVATION_INDEX,
4
4
  DOT_HOST_NAME,
5
5
  DOT_PRODUCT_ID,
6
+ STALE_SESSION_DEPLOY_MESSAGE,
6
7
  STALE_SESSION_MESSAGE,
7
8
  buildAuthConfig,
8
9
  getAuthClient,
9
10
  getPeopleChainEndpoints,
10
11
  hasPersistedSession,
11
12
  resolveBulletinEndpoints
12
- } from "./chunk-KACRAHSV.js";
13
- import "./chunk-TSPERKUS.js";
13
+ } from "./chunk-IF3SANQR.js";
14
14
  import "./chunk-3NR3T7US.js";
15
- import "./chunk-A3VWIJKO.js";
16
- import "./chunk-QKEZK2M6.js";
15
+ import "./chunk-YLLTQM5Z.js";
16
+ import "./chunk-3BSPX4JN.js";
17
17
  import "./chunk-SH2LG52Z.js";
18
+ import "./chunk-DNXE3Q5D.js";
18
19
  export {
19
20
  DOT_DAPP_ID,
20
21
  DOT_DERIVATION_INDEX,
21
22
  DOT_HOST_NAME,
22
23
  DOT_PRODUCT_ID,
24
+ STALE_SESSION_DEPLOY_MESSAGE,
23
25
  STALE_SESSION_MESSAGE,
24
26
  buildAuthConfig,
25
27
  getAuthClient,
@@ -10,10 +10,10 @@ import {
10
10
  offerBugReport,
11
11
  scrubSecrets,
12
12
  setDeployContext
13
- } from "./chunk-NGVCDMLS.js";
14
- import "./chunk-567ZRMI6.js";
15
- import "./chunk-A3VWIJKO.js";
16
- import "./chunk-QKEZK2M6.js";
13
+ } from "./chunk-LRRFXOLE.js";
14
+ import "./chunk-BXDMEOLH.js";
15
+ import "./chunk-YLLTQM5Z.js";
16
+ import "./chunk-3BSPX4JN.js";
17
17
  import "./chunk-SH2LG52Z.js";
18
18
  export {
19
19
  buildCliFlagsSummary,
@@ -3,9 +3,9 @@ import {
3
3
  DEFAULT_WINDOW_BLOCKS,
4
4
  MAX_SPANS_PER_SAMPLER,
5
5
  endpointHost
6
- } from "./chunk-IUPVNIVY.js";
7
- import "./chunk-A3VWIJKO.js";
8
- import "./chunk-QKEZK2M6.js";
6
+ } from "./chunk-MTXFJTX6.js";
7
+ import "./chunk-YLLTQM5Z.js";
8
+ import "./chunk-3BSPX4JN.js";
9
9
  import "./chunk-SH2LG52Z.js";
10
10
  export {
11
11
  ChainHealthSampler,
@@ -1,9 +1,12 @@
1
+ import {
2
+ getWsProvider
3
+ } from "./chunk-6GHDPDZN.js";
4
+
1
5
  // src/pool.ts
2
6
  import { sr25519CreateDerive } from "@polkadot-labs/hdkd";
3
7
  import { DEV_PHRASE, entropyToMiniSecret, mnemonicToEntropy } from "@polkadot-labs/hdkd-helpers";
4
8
  import { createClient, Enum } from "polkadot-api";
5
9
  import { getPolkadotSigner } from "polkadot-api/signer";
6
- import { getWsProvider } from "polkadot-api/ws";
7
10
  import { Keyring } from "@polkadot/keyring";
8
11
  import { cryptoWaitReady } from "@polkadot/util-crypto";
9
12
  var PAS_DECIMALS_DIVISOR = 1e10;
@@ -0,0 +1,57 @@
1
+ // src/auth/vendor/signer.ts
2
+ import { ss58Encode } from "@parity/product-sdk-address";
3
+ import { createDevSigner, getDevPublicKey } from "@parity/product-sdk-tx";
4
+ import { seedToAccount } from "@parity/product-sdk-keys";
5
+ var SignerNotAvailableError = class extends Error {
6
+ constructor() {
7
+ super('No signer available. Run "login" to sign in, or pass --suri //Alice for dev.');
8
+ this.name = "SignerNotAvailableError";
9
+ }
10
+ };
11
+ var DEV_NAMES = ["Alice", "Bob", "Charlie", "Dave", "Eve", "Ferdie"];
12
+ function parseDevAccountName(suri) {
13
+ const name = suri.replace(/^\/\//, "");
14
+ return DEV_NAMES.find((n) => n.toLowerCase() === name.toLowerCase()) ?? null;
15
+ }
16
+ async function resolveSigner(authClient, options) {
17
+ if (options?.suri) {
18
+ const devName = parseDevAccountName(options.suri);
19
+ if (devName) {
20
+ return {
21
+ signer: createDevSigner(devName),
22
+ address: ss58Encode(getDevPublicKey(devName)),
23
+ source: "dev",
24
+ destroy() {
25
+ }
26
+ };
27
+ }
28
+ const sepIdx = options.suri.indexOf("//");
29
+ const mnemonic = (sepIdx === -1 ? options.suri : options.suri.slice(0, sepIdx)).trim();
30
+ const path = sepIdx === -1 ? "" : options.suri.slice(sepIdx);
31
+ try {
32
+ const account = seedToAccount(mnemonic, path);
33
+ return {
34
+ signer: account.signer,
35
+ address: ss58Encode(account.publicKey),
36
+ source: "dev",
37
+ destroy() {
38
+ }
39
+ };
40
+ } catch {
41
+ throw new Error(
42
+ `Unrecognized SURI "${options.suri}". Expected a dev name (${DEV_NAMES.join(", ")}) or a BIP-39 mnemonic.`
43
+ );
44
+ }
45
+ }
46
+ const session = await authClient.getSessionSigner();
47
+ if (session) {
48
+ return { ...session, source: "session" };
49
+ }
50
+ throw new SignerNotAvailableError();
51
+ }
52
+
53
+ export {
54
+ SignerNotAvailableError,
55
+ parseDevAccountName,
56
+ resolveSigner
57
+ };
@@ -6,7 +6,7 @@ import * as path from "path";
6
6
  // package.json
7
7
  var package_default = {
8
8
  name: "bulletin-deploy",
9
- version: "0.20.0-rc.1",
9
+ version: "0.20.0",
10
10
  private: false,
11
11
  repository: {
12
12
  type: "git",
@@ -52,11 +52,11 @@ var package_default = {
52
52
  "tools/verify-baked-dsn.mjs"
53
53
  ],
54
54
  scripts: {
55
- build: "tsup src/suppress-localstorage-warning.ts src/index.ts src/deploy.ts src/dotns.ts src/mnemonic.ts src/dotns-protocol.ts src/pool.ts src/telemetry.ts src/chain-health.ts src/memory-report.ts src/merkle.ts src/version-check.ts src/bug-report.ts src/run-state.ts src/environments.ts src/errors.ts src/subname-depth.ts src/manifest.ts src/chunk-probe.ts src/manifest-embed.ts src/manifest-fetch.ts src/manifest-roundtrip.ts src/incremental-stats.ts src/chunker.ts src/personhood/encoding.ts src/personhood/hashing.ts src/personhood/constants.ts src/personhood/member-key.ts src/personhood/people-client.ts src/personhood/proof-validity.ts src/personhood/ring-proof.ts src/personhood/reprove.ts src/personhood/bind-personal-id.ts src/personhood/claim-pgas.ts src/personhood/bind-paid-alias.ts src/personhood/bootstrap.ts src/personhood/chain-prereqs.ts src/manifest/types.ts src/manifest/schema.ts src/manifest/byte-budget.ts src/manifest/compose.ts src/manifest/config-load.ts src/manifest/publish.ts src/auth/index.ts src/auth/vendor/index.ts src/auth/vendor/ui/index.ts src/auth-config.ts src/commands/login.ts src/commands/logout.ts src/commands/whoami.ts src/commands/transfer.ts src/storage-signer.ts src/spinner.ts src/sss-allowance.ts src/sss-allowance-cache.ts src/deploy-actors.ts src/product-account.ts --format esm --dts --clean --target node22",
55
+ build: "tsup",
56
56
  "refresh-environments": "node scripts/refresh-environments.mjs",
57
57
  postinstall: "patch-package || true",
58
58
  prepare: "npm run build",
59
- test: "npm run build && node --test test/test.js test/cli-help.test.js test/helpers/e2e-helpers.test.js test/helpers/e2e-exit-guard.test.js test/environments.test.js test/refresh-environments.test.js test/chunk-sharing-report.test.js test/car-section1-dedup.test.js test/dotns-deployments-parser.test.js test/dotns-token-id.test.js test/dotns-subnode-id.test.js test/dotns-protocol.test.js test/product-manifest.test.js test/bin-manifest-preflight.test.js test/manifest-trusted-products.test.js test/cache-savings-totals.test.js test/error-pattern-signature.test.js test/exit-codes.test.js test/probe-env-health.test.js test/chunk-probe-timeout.test.js test/e2e-chain-calls.test.js test/auth-config.test.js test/whoami.test.js test/login.test.js test/logout.test.js test/auth-resolve.test.js test/storage-signer.test.js test/spinner.test.js test/sss-allowance.test.js test/sss-allowance-cache.test.js test/dotns-transfer.test.js test/deploy-actors.test.js test/transfer-command.test.js test/dotns-register-fee.test.js test/dotns-commitment-resume.test.js test/deploy-label-ordering.test.js test/benign-teardown.test.js test/verify-baked-dsn.test.js test/product-account.test.js test/post-release-monitor-skill.test.js test/test-release-retry-wrapper.js test/reprove-alias-tool.test.js test/bootstrap-env.test.js test/check-chain-identity.test.js && npm run test:vendor",
59
+ test: "npm run build && node scripts/run-unit-tests.mjs && npm run test:vendor",
60
60
  "test:e2e": "npm run build && node --test test/e2e.test.js",
61
61
  "test:e2e:smoke": "bash scripts/e2e-pass.sh smoke",
62
62
  "test:e2e:pr": "bash scripts/e2e-pass.sh pr",