@logswap/sdk 0.5.49 → 0.5.51
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.
- package/dist/admin.d.ts +72 -14
- package/dist/admin.js +116 -19
- package/dist/client.d.ts +7 -1
- package/dist/client.js +8 -2
- package/dist/fpool.d.ts +234 -46
- package/dist/fpool.js +122 -66
- package/dist/generated.d.ts +1328 -288
- package/dist/generated.js +866 -158
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/package.json +1 -1
- package/src/admin.ts +139 -19
- package/src/client.ts +14 -2
- package/src/fpool.ts +171 -105
- package/src/generated.ts +872 -160
- package/src/index.ts +1 -1
package/dist/admin.d.ts
CHANGED
|
@@ -1,28 +1,76 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* admin — the protocol's
|
|
3
|
-
*
|
|
4
|
-
* two-step collector handover. Plain writes to the managers
|
|
2
|
+
* admin — the protocol's writes: the C manager's cut of the mint fee (the F manager's is a
|
|
3
|
+
* constant, decisions 049), the policies a pool may be born with (the registry's), the
|
|
4
|
+
* policies' own numbers, and the two-step collector handover. Plain writes to the managers,
|
|
5
|
+
* the registry and the policies; no router.
|
|
5
6
|
*
|
|
6
7
|
* One vocabulary (decisions 040): both managers call the protocol's cut of the mint fee
|
|
7
|
-
* `MINT_FEE_PROTOCOL_CUT
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
*
|
|
8
|
+
* `MINT_FEE_PROTOCOL_CUT`; C sets it through `setFeeParams(uint256)`, F holds it as a constant
|
|
9
|
+
* (049). The harvest's cut is the policy's answer at every harvest (decisions 044), set on the
|
|
10
|
+
* policy (`setHarvestCut`) and capped by the manager (`HARVEST_CUT_MAX`); the release's
|
|
11
|
+
* protocol share likewise (`POT_CUT_MAX`).
|
|
11
12
|
*/
|
|
12
13
|
import type { Address, Hash } from "viem";
|
|
13
14
|
import type { LogswapClient } from "./client.js";
|
|
14
15
|
import { type FPoolKind } from "./fpool.js";
|
|
15
16
|
/** The C manager's `setFeeParams(mintFeeProtocolCut)` — one cut. */
|
|
16
17
|
export declare function setFeeParamsC(c: LogswapClient, mintFeeProtocolCutWad: bigint): Promise<Hash>;
|
|
17
|
-
/** The F manager's `
|
|
18
|
-
export declare function
|
|
18
|
+
/** The F manager's `MINT_FEE_PROTOCOL_CUT` — a constant since F version 18 (decisions 049); there is no setter. */
|
|
19
|
+
export declare function fMintFeeProtocolCut(c: LogswapClient): Promise<bigint>;
|
|
19
20
|
/**
|
|
20
|
-
*
|
|
21
|
-
*
|
|
21
|
+
* The policy registry the F manager asks at every birth — `addresses.policyRegistry` when the
|
|
22
|
+
* deployment carries it, else read once from the manager. The zero address is a deployment with
|
|
23
|
+
* no registry: it asks nobody, and nothing here can be written.
|
|
22
24
|
*/
|
|
23
|
-
export declare function
|
|
24
|
-
/** Whether `policy` is approved
|
|
25
|
-
export declare function policyApproved(c: LogswapClient,
|
|
25
|
+
export declare function policyRegistryOf(c: LogswapClient): Promise<Address>;
|
|
26
|
+
/** Whether `policy` is approved now — listed and not yet sunset. True everywhere on a deployment with no registry. */
|
|
27
|
+
export declare function policyApproved(c: LogswapClient, policy: Address): Promise<boolean>;
|
|
28
|
+
/** One policy on the registry's list, with what it says it is. */
|
|
29
|
+
export interface RegistryEntry {
|
|
30
|
+
policy: Address;
|
|
31
|
+
/** The policy's own `kind()` tag (decisions 049) — what a pool born under it is. */
|
|
32
|
+
kind: FPoolKind;
|
|
33
|
+
name: string;
|
|
34
|
+
/** The block it closes to new pools from; 0 = open. */
|
|
35
|
+
until: bigint;
|
|
36
|
+
/** Approved now: listed and not yet sunset. */
|
|
37
|
+
approved: boolean;
|
|
38
|
+
}
|
|
39
|
+
/**
|
|
40
|
+
* Every policy listed, sunset ones included — one flat list (decisions 049), each with the kind
|
|
41
|
+
* it says it is; `kind` narrows it to one, which is what a create form's dropdown reads. Empty
|
|
42
|
+
* with no registry.
|
|
43
|
+
*/
|
|
44
|
+
export declare function registryPolicies(c: LogswapClient, kind?: FPoolKind): Promise<RegistryEntry[]>;
|
|
45
|
+
/** The registry's owner — the LOG authority — and the proposed next one. */
|
|
46
|
+
export declare function registryOwner(c: LogswapClient): Promise<{
|
|
47
|
+
owner: Address;
|
|
48
|
+
pending: Address;
|
|
49
|
+
}>;
|
|
50
|
+
/** `PolicyRegistry.approve`: list `policy` under `name` (at most 31 bytes). Again renames it and clears its sunset. The owner's. */
|
|
51
|
+
export declare function registryApprove(c: LogswapClient, policy: Address, name: string): Promise<Hash>;
|
|
52
|
+
/** `PolicyRegistry.sunset`: close `policy` to new pools from `untilBlock` on; 0 reopens. The owner's. */
|
|
53
|
+
export declare function registrySunset(c: LogswapClient, policy: Address, untilBlock: bigint): Promise<Hash>;
|
|
54
|
+
/** `PolicyRegistry.revoke`: remove `policy` from the list at once. Live pools are untouched. The owner's. */
|
|
55
|
+
export declare function registryRevoke(c: LogswapClient, policy: Address): Promise<Hash>;
|
|
56
|
+
/** The registry owner's two-step handover. */
|
|
57
|
+
export declare function registryProposeOwner(c: LogswapClient, next: Address): Promise<Hash>;
|
|
58
|
+
export declare function registryAcceptOwner(c: LogswapClient): Promise<Hash>;
|
|
59
|
+
/**
|
|
60
|
+
* Approve or revoke, the F version 15–16 shape kept for callers: `approved` true is
|
|
61
|
+
* {@link registryApprove} under the policy's own tag as its name, false is {@link registryRevoke}.
|
|
62
|
+
*/
|
|
63
|
+
export declare function setPolicyApproved(c: LogswapClient, policy: Address, approved: boolean): Promise<Hash>;
|
|
64
|
+
/**
|
|
65
|
+
* Move a pool to another approved policy of the same kind (decisions 046, 049): the registry
|
|
66
|
+
* owner's alone, orchestrated on the registry — `migrate(manager, poolId, to)`. The new policy
|
|
67
|
+
* takes the authority and the name from the old; the operator and the lists void; no swap lands
|
|
68
|
+
* in the block.
|
|
69
|
+
*/
|
|
70
|
+
export declare function fPoolMigrate(c: LogswapClient, a: {
|
|
71
|
+
poolId: `0x${string}`;
|
|
72
|
+
to: Address;
|
|
73
|
+
}): Promise<Hash>;
|
|
26
74
|
/** The protocol's rate on the income part of every harvest under `policy`, WAD ≤ `HARVEST_CUT_MAX`. */
|
|
27
75
|
export declare function setHarvestCut(c: LogswapClient, policy: Address, rateWad: bigint): Promise<Hash>;
|
|
28
76
|
/** `PadPolicy.setSchedule`: `T(0)`, the rung's growth, the creator's and the protocol's shares of the pot (≤ `POT_CUT_MAX`), the burn per rung (≤ `BURN_MAX`). */
|
|
@@ -38,6 +86,16 @@ export declare function polSetRules(c: LogswapClient, policy: Address, s: {
|
|
|
38
86
|
keepQuote: bigint;
|
|
39
87
|
minQuoteAtSeed: bigint;
|
|
40
88
|
}): Promise<Hash>;
|
|
89
|
+
/** `setQuoteListed` on any protocol policy: a quote a pool of that kind may be born against while it curates quotes. The collector's. */
|
|
90
|
+
export declare function policySetQuoteListed(c: LogswapClient, policy: Address, quote: Address, listed: boolean): Promise<Hash>;
|
|
91
|
+
/** `setQuoteCurated` on any protocol policy: on, a birth against an unlisted quote is refused. The collector's. */
|
|
92
|
+
export declare function policySetQuoteCurated(c: LogswapClient, policy: Address, curated: boolean): Promise<Hash>;
|
|
93
|
+
/** Whether `quote` passes `policy`'s birth check now: listed, or the policy does not curate quotes. */
|
|
94
|
+
export declare function policyQuoteAllowed(c: LogswapClient, policy: Address, quote: Address): Promise<{
|
|
95
|
+
curated: boolean;
|
|
96
|
+
listed: boolean;
|
|
97
|
+
allowed: boolean;
|
|
98
|
+
}>;
|
|
41
99
|
/** `PublicPolicy.setListed`: an asset a curated seed may hold. */
|
|
42
100
|
export declare function publicSetListed(c: LogswapClient, policy: Address, token: Address, listed: boolean): Promise<Hash>;
|
|
43
101
|
/** `PublicPolicy.setCurated`: whether every public seed is checked against the list. */
|
package/dist/admin.js
CHANGED
|
@@ -1,16 +1,17 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* admin — the protocol's
|
|
3
|
-
*
|
|
4
|
-
* two-step collector handover. Plain writes to the managers
|
|
2
|
+
* admin — the protocol's writes: the C manager's cut of the mint fee (the F manager's is a
|
|
3
|
+
* constant, decisions 049), the policies a pool may be born with (the registry's), the
|
|
4
|
+
* policies' own numbers, and the two-step collector handover. Plain writes to the managers,
|
|
5
|
+
* the registry and the policies; no router.
|
|
5
6
|
*
|
|
6
7
|
* One vocabulary (decisions 040): both managers call the protocol's cut of the mint fee
|
|
7
|
-
* `MINT_FEE_PROTOCOL_CUT
|
|
8
|
-
*
|
|
9
|
-
*
|
|
10
|
-
*
|
|
8
|
+
* `MINT_FEE_PROTOCOL_CUT`; C sets it through `setFeeParams(uint256)`, F holds it as a constant
|
|
9
|
+
* (049). The harvest's cut is the policy's answer at every harvest (decisions 044), set on the
|
|
10
|
+
* policy (`setHarvestCut`) and capped by the manager (`HARVEST_CUT_MAX`); the release's
|
|
11
|
+
* protocol share likewise (`POT_CUT_MAX`).
|
|
11
12
|
*/
|
|
12
|
-
import { cPoolManagerAbi, fPoolManagerAbi, padPolicyAbi, polPolicyAbi, publicPolicyAbi } from "./generated.js";
|
|
13
|
-
import {
|
|
13
|
+
import { cPoolManagerAbi, fPoolManagerAbi, padPolicyAbi, polPolicyAbi, policyRegistryAbi, publicPolicyAbi } from "./generated.js";
|
|
14
|
+
import { bytes32ToText, fPolicyBaseAbi, fPoolKindOfPolicy, textToBytes32 } from "./fpool.js";
|
|
14
15
|
function wallet(c) {
|
|
15
16
|
if (!c.wallet)
|
|
16
17
|
throw new Error("a wallet client is required");
|
|
@@ -23,20 +24,100 @@ function write(c, address, abi, functionName, args) {
|
|
|
23
24
|
export async function setFeeParamsC(c, mintFeeProtocolCutWad) {
|
|
24
25
|
return write(c, c.addresses.cPoolManager, cPoolManagerAbi, "setFeeParams", [mintFeeProtocolCutWad]);
|
|
25
26
|
}
|
|
26
|
-
/** The F manager's `
|
|
27
|
-
export async function
|
|
28
|
-
return
|
|
27
|
+
/** The F manager's `MINT_FEE_PROTOCOL_CUT` — a constant since F version 18 (decisions 049); there is no setter. */
|
|
28
|
+
export async function fMintFeeProtocolCut(c) {
|
|
29
|
+
return c.public.readContract({ address: c.addresses.fPoolManager, abi: fPoolManagerAbi, functionName: "MINT_FEE_PROTOCOL_CUT" });
|
|
29
30
|
}
|
|
31
|
+
// ─── the registry (decisions 046): the LOG authority's, not the collector's ─────────────────
|
|
32
|
+
const ZERO = "0x0000000000000000000000000000000000000000";
|
|
30
33
|
/**
|
|
31
|
-
*
|
|
32
|
-
*
|
|
34
|
+
* The policy registry the F manager asks at every birth — `addresses.policyRegistry` when the
|
|
35
|
+
* deployment carries it, else read once from the manager. The zero address is a deployment with
|
|
36
|
+
* no registry: it asks nobody, and nothing here can be written.
|
|
33
37
|
*/
|
|
34
|
-
export async function
|
|
35
|
-
|
|
38
|
+
export async function policyRegistryOf(c) {
|
|
39
|
+
if (c.addresses.policyRegistry)
|
|
40
|
+
return c.addresses.policyRegistry;
|
|
41
|
+
return (await c.public.readContract({ address: c.addresses.fPoolManager, abi: fPoolManagerAbi, functionName: "registry" }));
|
|
36
42
|
}
|
|
37
|
-
/** Whether `policy` is approved
|
|
38
|
-
export async function policyApproved(c,
|
|
39
|
-
|
|
43
|
+
/** Whether `policy` is approved now — listed and not yet sunset. True everywhere on a deployment with no registry. */
|
|
44
|
+
export async function policyApproved(c, policy) {
|
|
45
|
+
const registry = await policyRegistryOf(c);
|
|
46
|
+
if (registry === ZERO)
|
|
47
|
+
return true;
|
|
48
|
+
return c.public.readContract({ address: registry, abi: policyRegistryAbi, functionName: "isApproved", args: [policy] });
|
|
49
|
+
}
|
|
50
|
+
/**
|
|
51
|
+
* Every policy listed, sunset ones included — one flat list (decisions 049), each with the kind
|
|
52
|
+
* it says it is; `kind` narrows it to one, which is what a create form's dropdown reads. Empty
|
|
53
|
+
* with no registry.
|
|
54
|
+
*/
|
|
55
|
+
export async function registryPolicies(c, kind) {
|
|
56
|
+
const registry = await policyRegistryOf(c);
|
|
57
|
+
if (registry === ZERO)
|
|
58
|
+
return [];
|
|
59
|
+
const list = (await c.public.readContract({ address: registry, abi: policyRegistryAbi, functionName: "policies" }));
|
|
60
|
+
const block = await c.public.getBlockNumber();
|
|
61
|
+
const all = await Promise.all(list.map(async (policy) => {
|
|
62
|
+
const [[listed, until, , name], tag] = await Promise.all([
|
|
63
|
+
c.public.readContract({ address: registry, abi: policyRegistryAbi, functionName: "entries", args: [policy] }),
|
|
64
|
+
fPoolKindOfPolicy(c, policy),
|
|
65
|
+
]);
|
|
66
|
+
return { policy, kind: tag, name: bytes32ToText(name), until, approved: listed && (until === 0n || block < until) };
|
|
67
|
+
}));
|
|
68
|
+
return kind ? all.filter((e) => e.kind === kind) : all;
|
|
69
|
+
}
|
|
70
|
+
/** The registry's owner — the LOG authority — and the proposed next one. */
|
|
71
|
+
export async function registryOwner(c) {
|
|
72
|
+
const registry = await policyRegistryOf(c);
|
|
73
|
+
if (registry === ZERO)
|
|
74
|
+
return { owner: ZERO, pending: ZERO };
|
|
75
|
+
const [owner, pending] = await Promise.all([
|
|
76
|
+
c.public.readContract({ address: registry, abi: policyRegistryAbi, functionName: "owner" }),
|
|
77
|
+
c.public.readContract({ address: registry, abi: policyRegistryAbi, functionName: "pendingOwner" }),
|
|
78
|
+
]);
|
|
79
|
+
return { owner, pending };
|
|
80
|
+
}
|
|
81
|
+
async function registryWrite(c, functionName, args) {
|
|
82
|
+
const registry = await policyRegistryOf(c);
|
|
83
|
+
if (registry === ZERO)
|
|
84
|
+
throw new Error("logswap: this deployment carries no policy registry");
|
|
85
|
+
return write(c, registry, policyRegistryAbi, functionName, args);
|
|
86
|
+
}
|
|
87
|
+
/** `PolicyRegistry.approve`: list `policy` under `name` (at most 31 bytes). Again renames it and clears its sunset. The owner's. */
|
|
88
|
+
export async function registryApprove(c, policy, name) {
|
|
89
|
+
return registryWrite(c, "approve", [policy, textToBytes32(name)]);
|
|
90
|
+
}
|
|
91
|
+
/** `PolicyRegistry.sunset`: close `policy` to new pools from `untilBlock` on; 0 reopens. The owner's. */
|
|
92
|
+
export async function registrySunset(c, policy, untilBlock) {
|
|
93
|
+
return registryWrite(c, "sunset", [policy, untilBlock]);
|
|
94
|
+
}
|
|
95
|
+
/** `PolicyRegistry.revoke`: remove `policy` from the list at once. Live pools are untouched. The owner's. */
|
|
96
|
+
export async function registryRevoke(c, policy) {
|
|
97
|
+
return registryWrite(c, "revoke", [policy]);
|
|
98
|
+
}
|
|
99
|
+
/** The registry owner's two-step handover. */
|
|
100
|
+
export async function registryProposeOwner(c, next) {
|
|
101
|
+
return registryWrite(c, "proposeOwner", [next]);
|
|
102
|
+
}
|
|
103
|
+
export async function registryAcceptOwner(c) {
|
|
104
|
+
return registryWrite(c, "acceptOwner", []);
|
|
105
|
+
}
|
|
106
|
+
/**
|
|
107
|
+
* Approve or revoke, the F version 15–16 shape kept for callers: `approved` true is
|
|
108
|
+
* {@link registryApprove} under the policy's own tag as its name, false is {@link registryRevoke}.
|
|
109
|
+
*/
|
|
110
|
+
export async function setPolicyApproved(c, policy, approved) {
|
|
111
|
+
return approved ? registryApprove(c, policy, await fPoolKindOfPolicy(c, policy)) : registryRevoke(c, policy);
|
|
112
|
+
}
|
|
113
|
+
/**
|
|
114
|
+
* Move a pool to another approved policy of the same kind (decisions 046, 049): the registry
|
|
115
|
+
* owner's alone, orchestrated on the registry — `migrate(manager, poolId, to)`. The new policy
|
|
116
|
+
* takes the authority and the name from the old; the operator and the lists void; no swap lands
|
|
117
|
+
* in the block.
|
|
118
|
+
*/
|
|
119
|
+
export async function fPoolMigrate(c, a) {
|
|
120
|
+
return registryWrite(c, "migrate", [c.addresses.fPoolManager, a.poolId, a.to]);
|
|
40
121
|
}
|
|
41
122
|
// ─── the policies' numbers (the collector's; each bounded where it reaches the manager) ─────
|
|
42
123
|
/** The protocol's rate on the income part of every harvest under `policy`, WAD ≤ `HARVEST_CUT_MAX`. */
|
|
@@ -51,6 +132,22 @@ export async function padSetSchedule(c, policy, s) {
|
|
|
51
132
|
export async function polSetRules(c, policy, s) {
|
|
52
133
|
return write(c, policy, polPolicyAbi, "setRules", [s.keepQuote, s.minQuoteAtSeed]);
|
|
53
134
|
}
|
|
135
|
+
/** `setQuoteListed` on any protocol policy: a quote a pool of that kind may be born against while it curates quotes. The collector's. */
|
|
136
|
+
export async function policySetQuoteListed(c, policy, quote, listed) {
|
|
137
|
+
return write(c, policy, fPolicyBaseAbi, "setQuoteListed", [quote, listed]);
|
|
138
|
+
}
|
|
139
|
+
/** `setQuoteCurated` on any protocol policy: on, a birth against an unlisted quote is refused. The collector's. */
|
|
140
|
+
export async function policySetQuoteCurated(c, policy, curated) {
|
|
141
|
+
return write(c, policy, fPolicyBaseAbi, "setQuoteCurated", [curated]);
|
|
142
|
+
}
|
|
143
|
+
/** Whether `quote` passes `policy`'s birth check now: listed, or the policy does not curate quotes. */
|
|
144
|
+
export async function policyQuoteAllowed(c, policy, quote) {
|
|
145
|
+
const [curated, listed] = await Promise.all([
|
|
146
|
+
c.public.readContract({ address: policy, abi: fPolicyBaseAbi, functionName: "quoteCurated" }),
|
|
147
|
+
c.public.readContract({ address: policy, abi: fPolicyBaseAbi, functionName: "quoteListed", args: [quote] }),
|
|
148
|
+
]);
|
|
149
|
+
return { curated, listed, allowed: !curated || listed };
|
|
150
|
+
}
|
|
54
151
|
/** `PublicPolicy.setListed`: an asset a curated seed may hold. */
|
|
55
152
|
export async function publicSetListed(c, policy, token, listed) {
|
|
56
153
|
return write(c, policy, publicPolicyAbi, "setListed", [token, listed]);
|
package/dist/client.d.ts
CHANGED
|
@@ -29,6 +29,12 @@ export interface LogswapAddresses {
|
|
|
29
29
|
privatePolicy?: Address;
|
|
30
30
|
polPolicy?: Address;
|
|
31
31
|
padPolicy?: Address;
|
|
32
|
+
/**
|
|
33
|
+
* The policy registry (decisions 046): what a pool of each kind may be born under, and the
|
|
34
|
+
* owner that may move a pool between policies. Read from the F manager (`registry()`) when
|
|
35
|
+
* absent; a deployment with none asks nobody.
|
|
36
|
+
*/
|
|
37
|
+
policyRegistry?: Address;
|
|
32
38
|
/** Optional — the router falls back to plain approvals when absent. */
|
|
33
39
|
permit2?: Address;
|
|
34
40
|
}
|
|
@@ -77,5 +83,5 @@ export declare const EXPECTED_VERSION = 4n;
|
|
|
77
83
|
* passes it; when one lands, raise this constant in the same change, which is the discipline
|
|
78
84
|
* `EXPECTED_VERSION` enforces mechanically and this one asks for.
|
|
79
85
|
*/
|
|
80
|
-
export declare const EXPECTED_F_VERSION =
|
|
86
|
+
export declare const EXPECTED_F_VERSION = 18n;
|
|
81
87
|
export declare function assertVersion(c: LogswapClient, expected?: bigint): Promise<void>;
|
package/dist/client.js
CHANGED
|
@@ -77,13 +77,19 @@ export const EXPECTED_VERSION = 4n;
|
|
|
77
77
|
// 15 (2026-09-20): the policy answers every question (decisions 044) — `FPoolKey.authority` is
|
|
78
78
|
// `creator` (every pool id moves again); the roles, gates and list are the pool's POLICY's
|
|
79
79
|
// (`FPolicyBase` / `PrivatePolicy`), not the manager's: `getPool` has `policy` and `asks` and no
|
|
80
|
-
// role; `proposeAuthority`, `appointOperator`, `setGates`, `setAllowed` are policy writes;
|
|
80
|
+
// role; `proposeAuthority`, `appointOperator`, `setGates`, `setAllowed` (`setMinters` / `setTakers` since 17) are policy writes;
|
|
81
81
|
// `policyApproved(kind, policy)` / `setPolicyApproved(kind, policy, ok)`; `Regenerated` names the payee;
|
|
82
82
|
// `HARVEST_CUT_MAX` / `POT_CUT_MAX` cap what a policy may route to the protocol.
|
|
83
83
|
// 16 (2026-09-21): the word is POLICY (decisions 045) — a rename, no pool id moves: `FPoolKey.policy`,
|
|
84
84
|
// `IFPolicy`, `FPolicyBase`, `PublicPolicy` … `PadPolicy`, `policyApproved` / `setPolicyApproved`,
|
|
85
85
|
// `PolicyApproved`; `PolPolicy.setPolicy` / `PolicySet` are `setRules` / `RulesSet`.
|
|
86
|
-
|
|
86
|
+
// 17 (2026-09-21): the registry, the move, the stamp, two lists, one base (decisions 046–048) — no
|
|
87
|
+
// pool id moves: the F manager takes a `PolicyRegistry` at construction and asks it at a birth
|
|
88
|
+
// (`policyApproved` / `setPolicyApproved` left the manager: `registryApprove` …); the key's policy
|
|
89
|
+
// is the policy at birth, `migrate` moves a pool for the registry's owner; `stamp` / `setAsks` are
|
|
90
|
+
// the policy's; the desk's `setAllowed` / `isAllowed` are `setMinters` / `setTakers` / `isMinter` /
|
|
91
|
+
// `isTaker`; a pad and a POL hold one base (`OneBase`).
|
|
92
|
+
export const EXPECTED_F_VERSION = 18n;
|
|
87
93
|
export async function assertVersion(c, expected = EXPECTED_VERSION) {
|
|
88
94
|
const { cPoolManagerAbi } = await import("./generated.js");
|
|
89
95
|
const got = await c.public.readContract({
|