@agoric/governance 0.10.4-dev-aa68d8f.0 → 0.10.4-dev-651b051.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.
- package/package.json +22 -22
- package/src/contractGovernance/governApi.d.ts +7 -6
- package/src/contractGovernance/governApi.d.ts.map +1 -1
- package/src/contractGovernance/governApi.js +3 -2
- package/src/contractGovernance/governParam.d.ts +2 -1
- package/src/contractGovernance/governParam.d.ts.map +1 -1
- package/src/contractGovernance/governParam.js +1 -0
- package/src/contractGovernance/paramManager.d.ts +2 -2
- package/src/contractGovernance/paramManager.d.ts.map +1 -1
- package/src/contractGovernance/paramManager.js +2 -2
- package/src/contractGovernorKit.d.ts +1 -1
- package/src/contractGovernorKit.d.ts.map +1 -1
- package/src/contractGovernorKit.js +2 -1
- package/src/contractHelper.d.ts +29 -29
- package/src/electorateTools.d.ts +1 -1
- package/src/quorumCounter.d.ts +1 -1
- package/src/typeGuards.d.ts +1 -1
- package/src/types.d.ts +10 -963
- package/src/types.d.ts.map +1 -1
- package/src/types.js +14 -10
- package/tools/puppetContractGovernor.d.ts +8 -6
- package/tools/puppetContractGovernor.d.ts.map +1 -1
- package/tools/puppetContractGovernor.js +2 -1
- package/tools/puppetGovernance.d.ts +13 -13
- package/tools/puppetGovernance.d.ts.map +1 -1
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@agoric/governance",
|
|
3
|
-
"version": "0.10.4-dev-
|
|
3
|
+
"version": "0.10.4-dev-651b051.0+651b051",
|
|
4
4
|
"description": "Core governance support",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "src/index.js",
|
|
@@ -31,28 +31,28 @@
|
|
|
31
31
|
},
|
|
32
32
|
"homepage": "https://github.com/Agoric/agoric-sdk#readme",
|
|
33
33
|
"dependencies": {
|
|
34
|
-
"@agoric/assert": "0.6.1-dev-
|
|
35
|
-
"@agoric/ertp": "0.16.3-dev-
|
|
36
|
-
"@agoric/internal": "0.3.3-dev-
|
|
37
|
-
"@agoric/network": "0.1.1-dev-
|
|
38
|
-
"@agoric/notifier": "0.6.3-dev-
|
|
39
|
-
"@agoric/store": "0.9.3-dev-
|
|
40
|
-
"@agoric/time": "0.3.3-dev-
|
|
41
|
-
"@agoric/vat-data": "0.5.3-dev-
|
|
42
|
-
"@agoric/zoe": "0.26.3-dev-
|
|
43
|
-
"@endo/bundle-source": "^3.2.
|
|
44
|
-
"@endo/captp": "^4.
|
|
45
|
-
"@endo/eventual-send": "^1.2.
|
|
46
|
-
"@endo/far": "^1.1.
|
|
47
|
-
"@endo/marshal": "^1.
|
|
48
|
-
"@endo/nat": "^5.0.
|
|
49
|
-
"@endo/promise-kit": "^1.1.
|
|
34
|
+
"@agoric/assert": "0.6.1-dev-651b051.0+651b051",
|
|
35
|
+
"@agoric/ertp": "0.16.3-dev-651b051.0+651b051",
|
|
36
|
+
"@agoric/internal": "0.3.3-dev-651b051.0+651b051",
|
|
37
|
+
"@agoric/network": "0.1.1-dev-651b051.0+651b051",
|
|
38
|
+
"@agoric/notifier": "0.6.3-dev-651b051.0+651b051",
|
|
39
|
+
"@agoric/store": "0.9.3-dev-651b051.0+651b051",
|
|
40
|
+
"@agoric/time": "0.3.3-dev-651b051.0+651b051",
|
|
41
|
+
"@agoric/vat-data": "0.5.3-dev-651b051.0+651b051",
|
|
42
|
+
"@agoric/zoe": "0.26.3-dev-651b051.0+651b051",
|
|
43
|
+
"@endo/bundle-source": "^3.2.3",
|
|
44
|
+
"@endo/captp": "^4.2.0",
|
|
45
|
+
"@endo/eventual-send": "^1.2.2",
|
|
46
|
+
"@endo/far": "^1.1.2",
|
|
47
|
+
"@endo/marshal": "^1.5.0",
|
|
48
|
+
"@endo/nat": "^5.0.7",
|
|
49
|
+
"@endo/promise-kit": "^1.1.2",
|
|
50
50
|
"import-meta-resolve": "^2.2.1"
|
|
51
51
|
},
|
|
52
52
|
"devDependencies": {
|
|
53
|
-
"@agoric/swingset-vat": "0.32.3-dev-
|
|
54
|
-
"@endo/bundle-source": "^3.2.
|
|
55
|
-
"@endo/init": "^1.1.
|
|
53
|
+
"@agoric/swingset-vat": "0.32.3-dev-651b051.0+651b051",
|
|
54
|
+
"@endo/bundle-source": "^3.2.3",
|
|
55
|
+
"@endo/init": "^1.1.2",
|
|
56
56
|
"ava": "^5.3.0",
|
|
57
57
|
"c8": "^9.1.0"
|
|
58
58
|
},
|
|
@@ -77,7 +77,7 @@
|
|
|
77
77
|
"access": "public"
|
|
78
78
|
},
|
|
79
79
|
"typeCoverage": {
|
|
80
|
-
"atLeast": 89.
|
|
80
|
+
"atLeast": 89.31
|
|
81
81
|
},
|
|
82
|
-
"gitHead": "
|
|
82
|
+
"gitHead": "651b05136f236230c67c8b40224540c585beaa54"
|
|
83
83
|
}
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* manage contracts that allow governance to invoke functions.
|
|
3
3
|
*
|
|
4
|
-
* @param {ERef<{ [methodName: string]: (...args: any) =>
|
|
4
|
+
* @param {ERef<{ [methodName: string]: (...args: any) => Passable }>} governedApis
|
|
5
5
|
* @param {Array<string | symbol>} governedNames names of the governed API methods
|
|
6
6
|
* @param {ERef<import('@agoric/time').TimerService>} timer
|
|
7
7
|
* @param {() => Promise<PoserFacet>} getUpdatedPoserFacet
|
|
8
8
|
* @returns {ApiGovernor}
|
|
9
9
|
*/
|
|
10
|
-
export function setupApiGovernance(governedApis: ERef<{
|
|
11
|
-
[methodName: string]: (...args: any) =>
|
|
10
|
+
export function setupApiGovernance(governedApis: globalThis.ERef<{
|
|
11
|
+
[methodName: string]: (...args: any) => Passable;
|
|
12
12
|
}>, governedNames: Array<string | symbol>, timer: ERef<import("@agoric/time").TimerService>, getUpdatedPoserFacet: () => Promise<PoserFacet>): ApiGovernor;
|
|
13
13
|
/**
|
|
14
14
|
* Make a pair of positions for a question about whether to invoke an API. If
|
|
@@ -16,17 +16,18 @@ export function setupApiGovernance(governedApis: ERef<{
|
|
|
16
16
|
* arguments that were provided.
|
|
17
17
|
*
|
|
18
18
|
* @param {string} apiMethodName
|
|
19
|
-
* @param {
|
|
19
|
+
* @param {Passable[]} methodArgs
|
|
20
20
|
*/
|
|
21
|
-
export function makeApiInvocationPositions(apiMethodName: string, methodArgs:
|
|
21
|
+
export function makeApiInvocationPositions(apiMethodName: string, methodArgs: Passable[]): {
|
|
22
22
|
positive: {
|
|
23
23
|
apiMethodName: string;
|
|
24
|
-
methodArgs:
|
|
24
|
+
methodArgs: Passable[];
|
|
25
25
|
};
|
|
26
26
|
negative: {
|
|
27
27
|
dontInvoke: string;
|
|
28
28
|
};
|
|
29
29
|
};
|
|
30
|
+
import type { Passable } from '@endo/pass-style';
|
|
30
31
|
import type { PoserFacet } from '../types.js';
|
|
31
32
|
import type { ApiGovernor } from '../types.js';
|
|
32
33
|
//# sourceMappingURL=governApi.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"governApi.d.ts","sourceRoot":"","sources":["governApi.js"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"governApi.d.ts","sourceRoot":"","sources":["governApi.js"],"names":[],"mappings":"AAgCA;;;;;;;;GAQG;AACH;oCANkD,GAAG;mBAC1C,KAAK,CAAC,MAAM,GAAG,MAAM,CAAC,SACtB,IAAI,CAAC,OAAO,cAAc,EAAE,YAAY,CAAC,gEA0FnD;AA7GD;;;;;;;GAOG;AACH,0DAHW,MAAM;;;;;;;;EAOhB;8BAlB2C,kBAAkB;gCAC+B,aAAa;iCAAb,aAAa"}
|
|
@@ -10,6 +10,7 @@ import {
|
|
|
10
10
|
} from '../question.js';
|
|
11
11
|
|
|
12
12
|
/**
|
|
13
|
+
* @import {Passable, RemotableObject} from '@endo/pass-style';
|
|
13
14
|
* @import {Position, ApiGovernor, ApiInvocationIssue, PoserFacet, VoteOnApiInvocation} from '../types.js';
|
|
14
15
|
*/
|
|
15
16
|
|
|
@@ -21,7 +22,7 @@ const { Fail, quote: q } = assert;
|
|
|
21
22
|
* arguments that were provided.
|
|
22
23
|
*
|
|
23
24
|
* @param {string} apiMethodName
|
|
24
|
-
* @param {
|
|
25
|
+
* @param {Passable[]} methodArgs
|
|
25
26
|
*/
|
|
26
27
|
const makeApiInvocationPositions = (apiMethodName, methodArgs) => {
|
|
27
28
|
const positive = harden({ apiMethodName, methodArgs });
|
|
@@ -32,7 +33,7 @@ const makeApiInvocationPositions = (apiMethodName, methodArgs) => {
|
|
|
32
33
|
/**
|
|
33
34
|
* manage contracts that allow governance to invoke functions.
|
|
34
35
|
*
|
|
35
|
-
* @param {ERef<{ [methodName: string]: (...args: any) =>
|
|
36
|
+
* @param {ERef<{ [methodName: string]: (...args: any) => Passable }>} governedApis
|
|
36
37
|
* @param {Array<string | symbol>} governedNames names of the governed API methods
|
|
37
38
|
* @param {ERef<import('@agoric/time').TimerService>} timer
|
|
38
39
|
* @param {() => Promise<PoserFacet>} getUpdatedPoserFacet
|
|
@@ -13,7 +13,7 @@ export function setupParamGovernance(paramManagerRetriever: globalThis.ERef<Para
|
|
|
13
13
|
* @param {Record<string, ParamValue>} changes
|
|
14
14
|
* @returns {ParamChangePositions}
|
|
15
15
|
*/
|
|
16
|
-
export function makeParamChangePositions(changes: Record<string,
|
|
16
|
+
export function makeParamChangePositions(changes: Record<string, ParamValue>): ParamChangePositions;
|
|
17
17
|
/**
|
|
18
18
|
* assert that the parameter described by paramSpec is proposed to be changed in
|
|
19
19
|
* the question described by questionSpec.
|
|
@@ -33,6 +33,7 @@ export const CONTRACT_ELECTORATE: "Electorate";
|
|
|
33
33
|
import type { ParamManagerRetriever } from '../types.js';
|
|
34
34
|
import type { PoserFacet } from '../types.js';
|
|
35
35
|
import type { ParamGovernor } from '../types.js';
|
|
36
|
+
import type { ParamValue } from '../types.js';
|
|
36
37
|
import type { ParamChangePositions } from '../types.js';
|
|
37
38
|
import type { ParamChangeIssue } from '../types.js';
|
|
38
39
|
import type { QuestionSpec } from '../types.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"governParam.d.ts","sourceRoot":"","sources":["governParam.js"],"names":[],"mappings":"AAyDA;;;;;;GAMG;AACH,sHALW,QAAQ,SACR,OAAO,cAAc,EAAE,YAAY,
|
|
1
|
+
{"version":3,"file":"governParam.d.ts","sourceRoot":"","sources":["governParam.js"],"names":[],"mappings":"AAyDA;;;;;;GAMG;AACH,sHALW,QAAQ,SACR,OAAO,cAAc,EAAE,YAAY,kEA2F7C;AA/HD;;;;;;GAMG;AACH,oGAMC;AAED;;;;;;GAMG;AACH,qDAHW;IAAE,aAAa,EAAE,MAAM,CAAC;IAAC,SAAS,EAAE,OAAO,CAAA;CAAC,+DAYtD;AArCD;;;GAGG;AACH,+CAAyC;2CATsI,aAAa;gCAAb,aAAa;mCAAb,aAAa;gCAAb,aAAa;0CAAb,aAAa;sCAAb,aAAa;kCAAb,aAAa"}
|
|
@@ -78,6 +78,7 @@ const setupParamGovernance = (
|
|
|
78
78
|
paramSpec,
|
|
79
79
|
) => {
|
|
80
80
|
const paramMgr = await E(paramManagerRetriever).get(paramSpec.paramPath);
|
|
81
|
+
/** @type {import('@endo/marshal').Passable} */
|
|
81
82
|
const changePs = {};
|
|
82
83
|
for (const name of Object.keys(paramSpec.changes)) {
|
|
83
84
|
const proposedValue = E(paramMgr).getVisibleValue(
|
|
@@ -6,7 +6,7 @@ export type ParamManagerBuilder = {
|
|
|
6
6
|
addInvitation: (name: string, value: Invitation) => ParamManagerBuilder;
|
|
7
7
|
addNat: (name: string, value: bigint) => ParamManagerBuilder;
|
|
8
8
|
addRatio: (name: string, value: Ratio) => ParamManagerBuilder;
|
|
9
|
-
addRecord: (name: string, value: import("@endo/marshal").CopyRecord<
|
|
9
|
+
addRecord: (name: string, value: import("@endo/marshal").CopyRecord<any>) => ParamManagerBuilder;
|
|
10
10
|
addString: (name: string, value: string) => ParamManagerBuilder;
|
|
11
11
|
addTimestamp: (name: string, value: import("@agoric/time").Timestamp) => ParamManagerBuilder;
|
|
12
12
|
addRelativeTime: (name: string, value: import("@agoric/time").RelativeTime) => ParamManagerBuilder;
|
|
@@ -29,7 +29,7 @@ export function assertElectorateMatches(paramManager: ParamManagerBase, governed
|
|
|
29
29
|
* @property {(name: string, value: Invitation) => ParamManagerBuilder} addInvitation
|
|
30
30
|
* @property {(name: string, value: bigint) => ParamManagerBuilder} addNat
|
|
31
31
|
* @property {(name: string, value: Ratio) => ParamManagerBuilder} addRatio
|
|
32
|
-
* @property {(name: string, value: import('@endo/marshal').CopyRecord<
|
|
32
|
+
* @property {(name: string, value: import('@endo/marshal').CopyRecord<any>) => ParamManagerBuilder} addRecord
|
|
33
33
|
* @property {(name: string, value: string) => ParamManagerBuilder} addString
|
|
34
34
|
* @property {(name: string, value: import('@agoric/time').Timestamp) => ParamManagerBuilder} addTimestamp
|
|
35
35
|
* @property {(name: string, value: import('@agoric/time').RelativeTime) => ParamManagerBuilder} addRelativeTime
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"paramManager.d.ts","sourceRoot":"","sources":["paramManager.js"],"names":[],"mappings":";eA4Cc,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,KAAK,mBAAmB;cACpD,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,KAAK,KAAK,mBAAmB;qBACnD,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,YAAY,KAAK,mBAAmB;iBAC1D,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,QAAQ,KAAK,mBAAmB;mBACtD,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,UAAU,KAAK,mBAAmB;YACxD,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,KAAK,mBAAmB;cACpD,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,KAAK,KAAK,mBAAmB;eACnD,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,eAAe,EAAE,UAAU,CAAC,
|
|
1
|
+
{"version":3,"file":"paramManager.d.ts","sourceRoot":"","sources":["paramManager.js"],"names":[],"mappings":";eA4Cc,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,KAAK,mBAAmB;cACpD,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,KAAK,KAAK,mBAAmB;qBACnD,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,YAAY,KAAK,mBAAmB;iBAC1D,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,QAAQ,KAAK,mBAAmB;mBACtD,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,UAAU,KAAK,mBAAmB;YACxD,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,KAAK,mBAAmB;cACpD,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,KAAK,KAAK,mBAAmB;eACnD,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,eAAe,EAAE,UAAU,CAAC,GAAG,CAAC,KAAK,mBAAmB;eACrF,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,KAAK,mBAAmB;kBACpD,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,cAAc,EAAE,SAAS,KAAK,mBAAmB;qBAC9E,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,cAAc,EAAE,YAAY,KAAK,mBAAmB;gBACjF,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,GAAG,KAAK,mBAAmB;;;AA7B/D;;;GAGG;AACH;;SAUC;AAED;;;;;;;;;;;;;;;GAeG;AAEH;;;GAGG;AACH,sMAgXC;qCA1ZiI,aAAa;sCAAb,aAAa;oCAH3G,kBAAkB;qCAG4E,aAAa;iDAAb,aAAa"}
|
|
@@ -49,7 +49,7 @@ const assertElectorateMatches = (paramManager, governedParams) => {
|
|
|
49
49
|
* @property {(name: string, value: Invitation) => ParamManagerBuilder} addInvitation
|
|
50
50
|
* @property {(name: string, value: bigint) => ParamManagerBuilder} addNat
|
|
51
51
|
* @property {(name: string, value: Ratio) => ParamManagerBuilder} addRatio
|
|
52
|
-
* @property {(name: string, value: import('@endo/marshal').CopyRecord<
|
|
52
|
+
* @property {(name: string, value: import('@endo/marshal').CopyRecord<any>) => ParamManagerBuilder} addRecord
|
|
53
53
|
* @property {(name: string, value: string) => ParamManagerBuilder} addString
|
|
54
54
|
* @property {(name: string, value: import('@agoric/time').Timestamp) => ParamManagerBuilder} addTimestamp
|
|
55
55
|
* @property {(name: string, value: import('@agoric/time').RelativeTime) => ParamManagerBuilder} addRelativeTime
|
|
@@ -184,7 +184,7 @@ const makeParamManagerBuilder = (publisherKit, zoe) => {
|
|
|
184
184
|
return builder;
|
|
185
185
|
};
|
|
186
186
|
|
|
187
|
-
/** @type {(name: string, value: import('@endo/marshal').CopyRecord
|
|
187
|
+
/** @type {(name: string, value: import('@endo/marshal').CopyRecord, builder: ParamManagerBuilder) => ParamManagerBuilder} */
|
|
188
188
|
const addRecord = (name, value, builder) => {
|
|
189
189
|
const assertRecord = v => {
|
|
190
190
|
passStyleOf(v);
|
|
@@ -20,7 +20,7 @@ export function prepareContractGovernorKit(baggage: import("@agoric/vat-data").B
|
|
|
20
20
|
/** @type {VoteOnParamChanges} */
|
|
21
21
|
voteOnParamChanges(voteCounterInstallation: Installation<any>, deadline: import("@agoric/time").Timestamp, paramSpec: import("./types.js").ParamChangesSpec<import("./types.js").StandardParamPath>): Promise<import("./types.js").ContractGovernanceVoteResult>;
|
|
22
22
|
/** @type {VoteOnApiInvocation} */
|
|
23
|
-
voteOnApiInvocation(apiMethodName: string, methodArgs:
|
|
23
|
+
voteOnApiInvocation(apiMethodName: string, methodArgs: import("@endo/pass-style").Passable[], voteCounterInstallation: Installation, deadline: import("@agoric/time").Timestamp): Promise<import("./types.js").ContractGovernanceVoteResult>;
|
|
24
24
|
/** @type {VoteOnOfferFilter} */
|
|
25
25
|
voteOnOfferFilter(voteCounterInstallation: Installation, deadline: import("@agoric/time").Timestamp, strings: string[]): Promise<import("./types.js").ContractGovernanceVoteResult>;
|
|
26
26
|
getCreatorFacet(): any;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"contractGovernorKit.d.ts","sourceRoot":"","sources":["contractGovernorKit.js"],"names":[],"mappings":"AAkEO,oDANI,OAAO,kBAAkB,EAAE,OAAO,UAClC;IACV,KAAS,EAAE,OAAO,cAAc,EAAE,YAAY,CAAC;IAC/C,GAAO,EAAE,IAAI,CAAC,UAAU,CAAC,CAAC;CACvB;;QAiCI,sCAAsC;iCAArB,OAAO,CAAC,QAAQ,CAAC;QAOlC,wCAAwC;;;;;;;
|
|
1
|
+
{"version":3,"file":"contractGovernorKit.d.ts","sourceRoot":"","sources":["contractGovernorKit.js"],"names":[],"mappings":"AAkEO,oDANI,OAAO,kBAAkB,EAAE,OAAO,UAClC;IACV,KAAS,EAAE,OAAO,cAAc,EAAE,YAAY,CAAC;IAC/C,GAAO,EAAE,IAAI,CAAC,UAAU,CAAC,CAAC;CACvB;;QAiCI,sCAAsC;iCAArB,OAAO,CAAC,QAAQ,CAAC;QAOlC,wCAAwC;;;;;;;QAoExC;;;WAGG;2CAFQ,UAAU,GACR,OAAO,CAAC,IAAI,CAAC;QAgB1B,iCAAiC;;QAOjC,kCAAkC;+HAoF8mU,YAAY,YAAqC,OAAO,cAAc,EAAE,SAAS;QArEjuU,gCAAgC;mDAqEmzU,YAAY,YAAqC,OAAO,cAAc,EAAE,SAAS,WAAsB,QAAQ;;;;;;;;;QAzCl8U,gCAAgC;qCAApB,QAAQ;QAepB,6BAA6B;iCAAjB,QAAQ;QAWpB,uCAAuC;;;GAY9C;kCAEa,UAAU,CAAC,UAAU,CAAC,OAAO,0BAA0B,CAAC,CAAC;uCArQ2K,YAAY;gCAAZ,YAAY;iCAAZ,YAAY"}
|
|
@@ -129,7 +129,8 @@ export const prepareContractGovernorKit = (baggage, powers) => {
|
|
|
129
129
|
]);
|
|
130
130
|
trace('setupApiGovernance');
|
|
131
131
|
apiGovernance = governedNames.length
|
|
132
|
-
?
|
|
132
|
+
? // @ts-expect-error FIXME
|
|
133
|
+
setupApiGovernance(governedApis, governedNames, timer, () =>
|
|
133
134
|
this.facets.helper.getUpdatedPoserFacet(),
|
|
134
135
|
)
|
|
135
136
|
: {
|
package/src/contractHelper.d.ts
CHANGED
|
@@ -22,17 +22,17 @@ import type { GovernanceTerms } from './types.js';
|
|
|
22
22
|
* @param {ERef<Marshaller>} [marshaller]
|
|
23
23
|
*/
|
|
24
24
|
export function handleParamGovernance<M extends import("./contractGovernance/typedParamManager.js").ParamTypesMap>(zcf: ZCF<GovernanceTerms<M>>, initialPoserInvitation: Invitation, paramTypesMap: M, storageNode?: globalThis.ERef<globalThis.StorageNode> | undefined, marshaller?: globalThis.ERef<{
|
|
25
|
-
toCapData: import("
|
|
26
|
-
fromCapData: import("
|
|
27
|
-
serialize: import("
|
|
28
|
-
unserialize: import("
|
|
25
|
+
toCapData: import("@endo/marshal").ToCapData<unknown>;
|
|
26
|
+
fromCapData: import("@endo/marshal").FromCapData<unknown>;
|
|
27
|
+
serialize: import("@endo/marshal").ToCapData<unknown>;
|
|
28
|
+
unserialize: import("@endo/marshal").FromCapData<unknown>;
|
|
29
29
|
}> | undefined): {
|
|
30
30
|
publicMixin: {
|
|
31
31
|
getAmount: (name: string) => globalThis.Amount;
|
|
32
32
|
getBrand: (name: string) => globalThis.Brand;
|
|
33
33
|
getInstance: (name: string) => Instance;
|
|
34
34
|
getInstallation: (name: string) => Installation<any>;
|
|
35
|
-
getInvitationAmount: (name: string) =>
|
|
35
|
+
getInvitationAmount: (name: string) => import("@agoric/ertp/exported.js").SetAmount<InvitationDetails>;
|
|
36
36
|
getNat: (name: string) => bigint;
|
|
37
37
|
getRatio: (name: string) => Ratio;
|
|
38
38
|
getString: (name: string) => string;
|
|
@@ -44,31 +44,31 @@ export function handleParamGovernance<M extends import("./contractGovernance/typ
|
|
|
44
44
|
};
|
|
45
45
|
augmentPublicFacet: <PF extends {}>(originalPublicFacet: PF) => GovernedPublicFacet<PF>;
|
|
46
46
|
augmentVirtualPublicFacet: <OPF extends {}>(originalPublicFacet: OPF) => OPF & {
|
|
47
|
-
getBrand: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) =>
|
|
48
|
-
getInstallation: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) =>
|
|
49
|
-
getInstance: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) =>
|
|
50
|
-
getAmount: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) =>
|
|
51
|
-
getInvitationAmount: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) =>
|
|
52
|
-
getNat: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) =>
|
|
53
|
-
getRatio: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) =>
|
|
54
|
-
getString: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) =>
|
|
55
|
-
getTimestamp: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) =>
|
|
56
|
-
getRelativeTime: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) =>
|
|
57
|
-
getUnknown: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) =>
|
|
47
|
+
getBrand: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) => import("@agoric/ertp/exported.js").SetAmount<InvitationDetails>) | ((name: string) => globalThis.Amount) | ((name: string) => globalThis.Brand) | ((name: string) => Instance) | ((name: string) => Installation<any>) | ((name: string) => bigint) | ((name: string) => Ratio) | ((name: string) => string) | ((name: string) => import("@agoric/time").TimestampRecord) | ((name: string) => import("@agoric/time").RelativeTimeRecord) | ((name: string) => any)>;
|
|
48
|
+
getInstallation: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) => import("@agoric/ertp/exported.js").SetAmount<InvitationDetails>) | ((name: string) => globalThis.Amount) | ((name: string) => globalThis.Brand) | ((name: string) => Instance) | ((name: string) => Installation<any>) | ((name: string) => bigint) | ((name: string) => Ratio) | ((name: string) => string) | ((name: string) => import("@agoric/time").TimestampRecord) | ((name: string) => import("@agoric/time").RelativeTimeRecord) | ((name: string) => any)>;
|
|
49
|
+
getInstance: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) => import("@agoric/ertp/exported.js").SetAmount<InvitationDetails>) | ((name: string) => globalThis.Amount) | ((name: string) => globalThis.Brand) | ((name: string) => Instance) | ((name: string) => Installation<any>) | ((name: string) => bigint) | ((name: string) => Ratio) | ((name: string) => string) | ((name: string) => import("@agoric/time").TimestampRecord) | ((name: string) => import("@agoric/time").RelativeTimeRecord) | ((name: string) => any)>;
|
|
50
|
+
getAmount: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) => import("@agoric/ertp/exported.js").SetAmount<InvitationDetails>) | ((name: string) => globalThis.Amount) | ((name: string) => globalThis.Brand) | ((name: string) => Instance) | ((name: string) => Installation<any>) | ((name: string) => bigint) | ((name: string) => Ratio) | ((name: string) => string) | ((name: string) => import("@agoric/time").TimestampRecord) | ((name: string) => import("@agoric/time").RelativeTimeRecord) | ((name: string) => any)>;
|
|
51
|
+
getInvitationAmount: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) => import("@agoric/ertp/exported.js").SetAmount<InvitationDetails>) | ((name: string) => globalThis.Amount) | ((name: string) => globalThis.Brand) | ((name: string) => Instance) | ((name: string) => Installation<any>) | ((name: string) => bigint) | ((name: string) => Ratio) | ((name: string) => string) | ((name: string) => import("@agoric/time").TimestampRecord) | ((name: string) => import("@agoric/time").RelativeTimeRecord) | ((name: string) => any)>;
|
|
52
|
+
getNat: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) => import("@agoric/ertp/exported.js").SetAmount<InvitationDetails>) | ((name: string) => globalThis.Amount) | ((name: string) => globalThis.Brand) | ((name: string) => Instance) | ((name: string) => Installation<any>) | ((name: string) => bigint) | ((name: string) => Ratio) | ((name: string) => string) | ((name: string) => import("@agoric/time").TimestampRecord) | ((name: string) => import("@agoric/time").RelativeTimeRecord) | ((name: string) => any)>;
|
|
53
|
+
getRatio: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) => import("@agoric/ertp/exported.js").SetAmount<InvitationDetails>) | ((name: string) => globalThis.Amount) | ((name: string) => globalThis.Brand) | ((name: string) => Instance) | ((name: string) => Installation<any>) | ((name: string) => bigint) | ((name: string) => Ratio) | ((name: string) => string) | ((name: string) => import("@agoric/time").TimestampRecord) | ((name: string) => import("@agoric/time").RelativeTimeRecord) | ((name: string) => any)>;
|
|
54
|
+
getString: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) => import("@agoric/ertp/exported.js").SetAmount<InvitationDetails>) | ((name: string) => globalThis.Amount) | ((name: string) => globalThis.Brand) | ((name: string) => Instance) | ((name: string) => Installation<any>) | ((name: string) => bigint) | ((name: string) => Ratio) | ((name: string) => string) | ((name: string) => import("@agoric/time").TimestampRecord) | ((name: string) => import("@agoric/time").RelativeTimeRecord) | ((name: string) => any)>;
|
|
55
|
+
getTimestamp: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) => import("@agoric/ertp/exported.js").SetAmount<InvitationDetails>) | ((name: string) => globalThis.Amount) | ((name: string) => globalThis.Brand) | ((name: string) => Instance) | ((name: string) => Installation<any>) | ((name: string) => bigint) | ((name: string) => Ratio) | ((name: string) => string) | ((name: string) => import("@agoric/time").TimestampRecord) | ((name: string) => import("@agoric/time").RelativeTimeRecord) | ((name: string) => any)>;
|
|
56
|
+
getRelativeTime: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) => import("@agoric/ertp/exported.js").SetAmount<InvitationDetails>) | ((name: string) => globalThis.Amount) | ((name: string) => globalThis.Brand) | ((name: string) => Instance) | ((name: string) => Installation<any>) | ((name: string) => bigint) | ((name: string) => Ratio) | ((name: string) => string) | ((name: string) => import("@agoric/time").TimestampRecord) | ((name: string) => import("@agoric/time").RelativeTimeRecord) | ((name: string) => any)>;
|
|
57
|
+
getUnknown: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) => import("@agoric/ertp/exported.js").SetAmount<InvitationDetails>) | ((name: string) => globalThis.Amount) | ((name: string) => globalThis.Brand) | ((name: string) => Instance) | ((name: string) => Installation<any>) | ((name: string) => bigint) | ((name: string) => Ratio) | ((name: string) => string) | ((name: string) => import("@agoric/time").TimestampRecord) | ((name: string) => import("@agoric/time").RelativeTimeRecord) | ((name: string) => any)>;
|
|
58
58
|
getSubscription: () => globalThis.StoredSubscription<GovernanceSubscriptionState>;
|
|
59
59
|
getGovernedParams: () => globalThis.ERef<import("./types.js").ParamStateRecord>;
|
|
60
|
-
} & import("@endo/eventual-send").RemotableBrand<{}, OPF & {
|
|
61
|
-
getBrand: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) =>
|
|
62
|
-
getInstallation: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) =>
|
|
63
|
-
getInstance: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) =>
|
|
64
|
-
getAmount: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) =>
|
|
65
|
-
getInvitationAmount: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) =>
|
|
66
|
-
getNat: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) =>
|
|
67
|
-
getRatio: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) =>
|
|
68
|
-
getString: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) =>
|
|
69
|
-
getTimestamp: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) =>
|
|
70
|
-
getRelativeTime: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) =>
|
|
71
|
-
getUnknown: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) =>
|
|
60
|
+
} & import("@endo/marshal").RemotableObject<`Alleged: ${string}`> & import("@endo/eventual-send").RemotableBrand<{}, OPF & {
|
|
61
|
+
getBrand: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) => import("@agoric/ertp/exported.js").SetAmount<InvitationDetails>) | ((name: string) => globalThis.Amount) | ((name: string) => globalThis.Brand) | ((name: string) => Instance) | ((name: string) => Installation<any>) | ((name: string) => bigint) | ((name: string) => Ratio) | ((name: string) => string) | ((name: string) => import("@agoric/time").TimestampRecord) | ((name: string) => import("@agoric/time").RelativeTimeRecord) | ((name: string) => any)>;
|
|
62
|
+
getInstallation: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) => import("@agoric/ertp/exported.js").SetAmount<InvitationDetails>) | ((name: string) => globalThis.Amount) | ((name: string) => globalThis.Brand) | ((name: string) => Instance) | ((name: string) => Installation<any>) | ((name: string) => bigint) | ((name: string) => Ratio) | ((name: string) => string) | ((name: string) => import("@agoric/time").TimestampRecord) | ((name: string) => import("@agoric/time").RelativeTimeRecord) | ((name: string) => any)>;
|
|
63
|
+
getInstance: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) => import("@agoric/ertp/exported.js").SetAmount<InvitationDetails>) | ((name: string) => globalThis.Amount) | ((name: string) => globalThis.Brand) | ((name: string) => Instance) | ((name: string) => Installation<any>) | ((name: string) => bigint) | ((name: string) => Ratio) | ((name: string) => string) | ((name: string) => import("@agoric/time").TimestampRecord) | ((name: string) => import("@agoric/time").RelativeTimeRecord) | ((name: string) => any)>;
|
|
64
|
+
getAmount: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) => import("@agoric/ertp/exported.js").SetAmount<InvitationDetails>) | ((name: string) => globalThis.Amount) | ((name: string) => globalThis.Brand) | ((name: string) => Instance) | ((name: string) => Installation<any>) | ((name: string) => bigint) | ((name: string) => Ratio) | ((name: string) => string) | ((name: string) => import("@agoric/time").TimestampRecord) | ((name: string) => import("@agoric/time").RelativeTimeRecord) | ((name: string) => any)>;
|
|
65
|
+
getInvitationAmount: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) => import("@agoric/ertp/exported.js").SetAmount<InvitationDetails>) | ((name: string) => globalThis.Amount) | ((name: string) => globalThis.Brand) | ((name: string) => Instance) | ((name: string) => Installation<any>) | ((name: string) => bigint) | ((name: string) => Ratio) | ((name: string) => string) | ((name: string) => import("@agoric/time").TimestampRecord) | ((name: string) => import("@agoric/time").RelativeTimeRecord) | ((name: string) => any)>;
|
|
66
|
+
getNat: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) => import("@agoric/ertp/exported.js").SetAmount<InvitationDetails>) | ((name: string) => globalThis.Amount) | ((name: string) => globalThis.Brand) | ((name: string) => Instance) | ((name: string) => Installation<any>) | ((name: string) => bigint) | ((name: string) => Ratio) | ((name: string) => string) | ((name: string) => import("@agoric/time").TimestampRecord) | ((name: string) => import("@agoric/time").RelativeTimeRecord) | ((name: string) => any)>;
|
|
67
|
+
getRatio: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) => import("@agoric/ertp/exported.js").SetAmount<InvitationDetails>) | ((name: string) => globalThis.Amount) | ((name: string) => globalThis.Brand) | ((name: string) => Instance) | ((name: string) => Installation<any>) | ((name: string) => bigint) | ((name: string) => Ratio) | ((name: string) => string) | ((name: string) => import("@agoric/time").TimestampRecord) | ((name: string) => import("@agoric/time").RelativeTimeRecord) | ((name: string) => any)>;
|
|
68
|
+
getString: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) => import("@agoric/ertp/exported.js").SetAmount<InvitationDetails>) | ((name: string) => globalThis.Amount) | ((name: string) => globalThis.Brand) | ((name: string) => Instance) | ((name: string) => Installation<any>) | ((name: string) => bigint) | ((name: string) => Ratio) | ((name: string) => string) | ((name: string) => import("@agoric/time").TimestampRecord) | ((name: string) => import("@agoric/time").RelativeTimeRecord) | ((name: string) => any)>;
|
|
69
|
+
getTimestamp: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) => import("@agoric/ertp/exported.js").SetAmount<InvitationDetails>) | ((name: string) => globalThis.Amount) | ((name: string) => globalThis.Brand) | ((name: string) => Instance) | ((name: string) => Installation<any>) | ((name: string) => bigint) | ((name: string) => Ratio) | ((name: string) => string) | ((name: string) => import("@agoric/time").TimestampRecord) | ((name: string) => import("@agoric/time").RelativeTimeRecord) | ((name: string) => any)>;
|
|
70
|
+
getRelativeTime: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) => import("@agoric/ertp/exported.js").SetAmount<InvitationDetails>) | ((name: string) => globalThis.Amount) | ((name: string) => globalThis.Brand) | ((name: string) => Instance) | ((name: string) => Installation<any>) | ((name: string) => bigint) | ((name: string) => Ratio) | ((name: string) => string) | ((name: string) => import("@agoric/time").TimestampRecord) | ((name: string) => import("@agoric/time").RelativeTimeRecord) | ((name: string) => any)>;
|
|
71
|
+
getUnknown: import("@agoric/swingset-liveslots").PlusContext<never, ((name: string) => import("@agoric/ertp/exported.js").SetAmount<InvitationDetails>) | ((name: string) => globalThis.Amount) | ((name: string) => globalThis.Brand) | ((name: string) => Instance) | ((name: string) => Installation<any>) | ((name: string) => bigint) | ((name: string) => Ratio) | ((name: string) => string) | ((name: string) => import("@agoric/time").TimestampRecord) | ((name: string) => import("@agoric/time").RelativeTimeRecord) | ((name: string) => any)>;
|
|
72
72
|
getSubscription: () => globalThis.StoredSubscription<GovernanceSubscriptionState>;
|
|
73
73
|
getGovernedParams: () => globalThis.ERef<import("./types.js").ParamStateRecord>;
|
|
74
74
|
}>;
|
|
@@ -86,7 +86,7 @@ export function handleParamGovernance<M extends import("./contractGovernance/typ
|
|
|
86
86
|
get: () => import("./contractGovernance/typedParamManager.js").TypedParamManager<M & {
|
|
87
87
|
Electorate: "invitation";
|
|
88
88
|
}>;
|
|
89
|
-
} & import("@endo/eventual-send").RemotableBrand<{}, {
|
|
89
|
+
} & import("@endo/marshal").RemotableObject<`Alleged: ${string}`> & import("@endo/eventual-send").RemotableBrand<{}, {
|
|
90
90
|
get: () => import("./contractGovernance/typedParamManager.js").TypedParamManager<M & {
|
|
91
91
|
Electorate: "invitation";
|
|
92
92
|
}>;
|
package/src/electorateTools.d.ts
CHANGED
|
@@ -38,7 +38,7 @@ export function getQuestion(questionHandleP: ERef<Handle<"Question">>, questionS
|
|
|
38
38
|
*/
|
|
39
39
|
export function getPoserInvitation(zcf: ZCF, addQuestion: AddQuestion): Promise<Invitation<{
|
|
40
40
|
addQuestion: AddQuestion;
|
|
41
|
-
} & import("@endo/eventual-send").RemotableBrand<{}, {
|
|
41
|
+
} & import("@endo/marshal").RemotableObject<`Alleged: ${string}`> & import("@endo/eventual-send").RemotableBrand<{}, {
|
|
42
42
|
addQuestion: AddQuestion;
|
|
43
43
|
}>, undefined>>;
|
|
44
44
|
import type { VoteCounterCreatorFacet } from './types.js';
|
package/src/quorumCounter.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export function makeQuorumCounter(quorumThreshold: any): {
|
|
2
2
|
check: (stats: any) => boolean;
|
|
3
|
-
} & import("@endo/eventual-send").RemotableBrand<{}, {
|
|
3
|
+
} & import("@endo/marshal").RemotableObject<`Alleged: ${string}`> & import("@endo/eventual-send").RemotableBrand<{}, {
|
|
4
4
|
check: (stats: any) => boolean;
|
|
5
5
|
}>;
|
|
6
6
|
//# sourceMappingURL=quorumCounter.d.ts.map
|
package/src/typeGuards.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ export const ChoiceMethodShape: import("@endo/patterns").Matcher;
|
|
|
2
2
|
export const QuorumRuleShape: import("@endo/patterns").Matcher;
|
|
3
3
|
export const ElectionTypeShape: import("@endo/patterns").Matcher;
|
|
4
4
|
export namespace ClosingRuleShape {
|
|
5
|
-
export let timer:
|
|
5
|
+
export let timer: globalThis.Pattern;
|
|
6
6
|
export { TimestampShape as deadline };
|
|
7
7
|
}
|
|
8
8
|
export namespace YesOfferFilterPositionShape {
|