@agoric/governance 0.10.4-dev-e2e36cc.0 → 0.10.4-dev-e6cde48.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 +12 -12
- package/src/types.d.ts +474 -5
- package/src/types.d.ts.map +1 -1
- package/src/types.js +3 -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-e6cde48.0+e6cde48",
|
|
4
4
|
"description": "Core governance support",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "src/index.js",
|
|
@@ -31,15 +31,15 @@
|
|
|
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-
|
|
34
|
+
"@agoric/assert": "0.6.1-dev-e6cde48.0+e6cde48",
|
|
35
|
+
"@agoric/ertp": "0.16.3-dev-e6cde48.0+e6cde48",
|
|
36
|
+
"@agoric/internal": "0.3.3-dev-e6cde48.0+e6cde48",
|
|
37
|
+
"@agoric/network": "0.1.1-dev-e6cde48.0+e6cde48",
|
|
38
|
+
"@agoric/notifier": "0.6.3-dev-e6cde48.0+e6cde48",
|
|
39
|
+
"@agoric/store": "0.9.3-dev-e6cde48.0+e6cde48",
|
|
40
|
+
"@agoric/time": "0.3.3-dev-e6cde48.0+e6cde48",
|
|
41
|
+
"@agoric/vat-data": "0.5.3-dev-e6cde48.0+e6cde48",
|
|
42
|
+
"@agoric/zoe": "0.26.3-dev-e6cde48.0+e6cde48",
|
|
43
43
|
"@endo/bundle-source": "^3.2.2",
|
|
44
44
|
"@endo/captp": "^4.1.1",
|
|
45
45
|
"@endo/eventual-send": "^1.2.1",
|
|
@@ -50,7 +50,7 @@
|
|
|
50
50
|
"import-meta-resolve": "^2.2.1"
|
|
51
51
|
},
|
|
52
52
|
"devDependencies": {
|
|
53
|
-
"@agoric/swingset-vat": "0.32.3-dev-
|
|
53
|
+
"@agoric/swingset-vat": "0.32.3-dev-e6cde48.0+e6cde48",
|
|
54
54
|
"@endo/bundle-source": "^3.2.2",
|
|
55
55
|
"@endo/init": "^1.1.1",
|
|
56
56
|
"ava": "^5.3.0",
|
|
@@ -79,5 +79,5 @@
|
|
|
79
79
|
"typeCoverage": {
|
|
80
80
|
"atLeast": 89.25
|
|
81
81
|
},
|
|
82
|
-
"gitHead": "
|
|
82
|
+
"gitHead": "e6cde482e02072514bda74657b7e1a6928b1e8ec"
|
|
83
83
|
}
|
package/src/types.d.ts
CHANGED
|
@@ -503,22 +503,490 @@ export type AssertContractGovernance = (zoe: ERef<ZoeService>, allegedGoverned:
|
|
|
503
503
|
label?: string | undefined;
|
|
504
504
|
};
|
|
505
505
|
}>, privateArgs: {
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
506
|
+
/**
|
|
507
|
+
* @typedef {object} QuorumCounter
|
|
508
|
+
* @property {(stats: VoteStatistics) => boolean} check
|
|
509
|
+
*/
|
|
510
|
+
/**
|
|
510
511
|
* @callback BuildQuestion
|
|
511
512
|
* @param {QuestionSpec} questionSpec
|
|
512
513
|
* @param {Instance} instance - voteCounter instance
|
|
513
514
|
* @returns {Question}
|
|
514
515
|
*/
|
|
516
|
+
/**
|
|
517
|
+
* @typedef {object} VoteCounterCreatorFacet - a facet that the Electorate should
|
|
518
|
+
* hold tightly. submitVote() is the core capability that allows the holder to
|
|
519
|
+
* specify the identity and choice of a voter. The voteCounter is making that
|
|
520
|
+
* available to the Electorate, which should wrap and attenuate it so each
|
|
521
|
+
* voter gets only the ability to cast their own vote at a weight specified by
|
|
522
|
+
* the electorate.
|
|
523
|
+
* @property {SubmitVote} submitVote
|
|
524
|
+
*/
|
|
525
|
+
/**
|
|
526
|
+
* @typedef {object} VoteCounterPublicFacet
|
|
527
|
+
* @property {() => boolean} isOpen
|
|
528
|
+
* @property {() => Question} getQuestion
|
|
529
|
+
* @property {() => Promise<Position>} getOutcome
|
|
530
|
+
* @property {() => QuestionDetails} getDetails
|
|
531
|
+
* @property {() => Promise<VoteStatistics>} getStats
|
|
532
|
+
*/
|
|
533
|
+
/**
|
|
534
|
+
* @typedef {object} MultiVoteCounterPublicFacet
|
|
535
|
+
* @property {() => boolean} isOpen
|
|
536
|
+
* @property {() => Question} getQuestion
|
|
537
|
+
* @property {() => Promise<Position[]>} getOutcome
|
|
538
|
+
* @property {() => QuestionDetails} getDetails
|
|
539
|
+
* @property {() => Promise<VoteStatistics>} getStats
|
|
540
|
+
*/
|
|
541
|
+
/**
|
|
542
|
+
* @typedef {object} VoteCounterCloseFacet
|
|
543
|
+
* TEST ONLY: Should not be allowed to escape from contracts
|
|
544
|
+
* @property {() => void} closeVoting
|
|
545
|
+
*/
|
|
546
|
+
/**
|
|
547
|
+
* @typedef {object} VoteCounterFacets
|
|
548
|
+
* @property {VoteCounterPublicFacet} publicFacet
|
|
549
|
+
* @property {VoteCounterCreatorFacet} creatorFacet
|
|
550
|
+
* @property {VoteCounterCloseFacet} closeFacet
|
|
551
|
+
*/
|
|
552
|
+
/**
|
|
553
|
+
* @typedef {object} MultiVoteCounterFacets
|
|
554
|
+
* @property {MultiVoteCounterPublicFacet} publicFacet
|
|
555
|
+
* @property {VoteCounterCreatorFacet} creatorFacet
|
|
556
|
+
* @property {VoteCounterCloseFacet} closeFacet
|
|
557
|
+
*/
|
|
558
|
+
/**
|
|
559
|
+
* @callback BuildVoteCounter
|
|
560
|
+
* @param {QuestionSpec} questionSpec
|
|
561
|
+
* @param {bigint} threshold - questionSpec includes quorumRule; the electorate
|
|
562
|
+
* converts that to a number that the counter can enforce.
|
|
563
|
+
* @param {Instance} instance
|
|
564
|
+
* @param {ERef<Publisher<OutcomeRecord>>} publisher
|
|
565
|
+
* @returns {VoteCounterFacets}
|
|
566
|
+
*/
|
|
567
|
+
/**
|
|
568
|
+
* @callback BuildMultiVoteCounter
|
|
569
|
+
* @param {QuestionSpec} questionSpec
|
|
570
|
+
* @param {bigint} threshold - questionSpec includes quorumRule; the electorate
|
|
571
|
+
* converts that to a number that the counter can enforce.
|
|
572
|
+
* @param {Instance} instance
|
|
573
|
+
* @param {ERef<Publisher<MultiOutcomeRecord>>} publisher
|
|
574
|
+
* @returns {MultiVoteCounterFacets}
|
|
575
|
+
*/
|
|
576
|
+
/**
|
|
577
|
+
* @typedef {object} CompletedBallet
|
|
578
|
+
* @property {Position} chosen
|
|
579
|
+
* @property {bigint} shares
|
|
580
|
+
*/
|
|
581
|
+
/**
|
|
582
|
+
* @callback SubmitVote
|
|
583
|
+
* @param {Handle<'Voter'>} voterHandle
|
|
584
|
+
* @param {Position[]} chosenPositions
|
|
585
|
+
* @param {bigint} [weight]
|
|
586
|
+
* @returns {CompletedBallet}
|
|
587
|
+
*/
|
|
588
|
+
/**
|
|
589
|
+
* @callback GetOpenQuestions
|
|
590
|
+
* @returns {Promise<Handle<'Question'>[]>}
|
|
591
|
+
*/
|
|
592
|
+
/**
|
|
593
|
+
* @callback GetQuestion
|
|
594
|
+
* @param {Handle<'Question'>} h
|
|
595
|
+
* @returns {Promise<Question>}
|
|
596
|
+
*/
|
|
597
|
+
/**
|
|
598
|
+
* @typedef {object} ElectoratePublic
|
|
599
|
+
* @property {() => Subscriber<QuestionDetails>} getQuestionSubscriber
|
|
600
|
+
* @property {GetOpenQuestions} getOpenQuestions,
|
|
601
|
+
* @property {() => Instance} getInstance
|
|
602
|
+
* @property {GetQuestion} getQuestion
|
|
603
|
+
*/
|
|
604
|
+
/**
|
|
605
|
+
* @typedef { ElectoratePublic & {makeVoterInvitation: () => ERef<Invitation>} } ClaimsElectoratePublic
|
|
606
|
+
* @typedef { ElectoratePublic & {getName: () => string} } CommitteeElectoratePublic
|
|
607
|
+
*/
|
|
608
|
+
/**
|
|
609
|
+
* @typedef {object} PoserFacet
|
|
610
|
+
* @property {AddQuestion} addQuestion
|
|
611
|
+
*/
|
|
612
|
+
/**
|
|
613
|
+
* @typedef {object} ElectorateCreatorFacet
|
|
614
|
+
* @property {AddQuestion} addQuestion can be used directly when the creator doesn't need any
|
|
615
|
+
* reassurance. When someone needs to connect addQuestion to the Electorate
|
|
616
|
+
* instance, getPoserInvitation() lets them get addQuestion with assurance.
|
|
617
|
+
* @property {() => Promise<Invitation>} getPoserInvitation
|
|
618
|
+
* @property {() => Subscriber<QuestionDetails>} getQuestionSubscriber
|
|
619
|
+
* @property {() => ElectoratePublic} getPublicFacet
|
|
620
|
+
*/
|
|
621
|
+
/**
|
|
622
|
+
* @typedef {object} GetVoterInvitations
|
|
623
|
+
* @property {() => Invitation[]} getVoterInvitations
|
|
624
|
+
*/
|
|
625
|
+
/**
|
|
626
|
+
* @typedef {object} VoterFacet - a facet that the Electorate should hold
|
|
627
|
+
* tightly. It allows specification of the vote's weight, so the Electorate
|
|
628
|
+
* should distribute an attenuated wrapper that doesn't make that available!
|
|
629
|
+
* @property {SubmitVote} submitVote
|
|
630
|
+
*/
|
|
631
|
+
/**
|
|
632
|
+
* @typedef {object} ClosingRule
|
|
633
|
+
* @property {ERef<import('@agoric/time').TimerService>} timer
|
|
634
|
+
* @property {import('@agoric/time').Timestamp} deadline
|
|
635
|
+
*/
|
|
636
|
+
/**
|
|
637
|
+
* @callback CloseVoting
|
|
638
|
+
* @param {ClosingRule} closingRule
|
|
639
|
+
* @param {() => void} closeVoting
|
|
640
|
+
*/
|
|
641
|
+
/**
|
|
642
|
+
* @typedef {object} AddQuestionReturn
|
|
643
|
+
* @property {VoteCounterPublicFacet} publicFacet
|
|
644
|
+
* @property {VoteCounterCreatorFacet} creatorFacet
|
|
645
|
+
* @property {import('@agoric/zoe/src/zoeService/utils.js').Instance<typeof import('./binaryVoteCounter.js').start>} instance
|
|
646
|
+
* @property {import('@agoric/time').Timestamp} deadline
|
|
647
|
+
* @property {Handle<'Question'>} questionHandle
|
|
648
|
+
*/
|
|
649
|
+
/**
|
|
650
|
+
* @callback AddQuestion
|
|
651
|
+
* @param {ERef<Installation>} voteCounter
|
|
652
|
+
* @param {QuestionSpec} questionSpec
|
|
653
|
+
* @returns {Promise<AddQuestionReturn>}
|
|
654
|
+
*/
|
|
655
|
+
/**
|
|
656
|
+
* @callback CreateQuestion
|
|
657
|
+
*
|
|
658
|
+
* @param {string} name - The name of the parameter to change
|
|
659
|
+
* @param {ParamValue} proposedValue - the proposed value for the named
|
|
660
|
+
* parameter
|
|
661
|
+
* @param {Installation} voteCounterInstallation - the voteCounter to
|
|
662
|
+
* instantiate to count votes. Expected to be a binaryVoteCounter. Other
|
|
663
|
+
* voteCounters might be added here, or might require separate governors.
|
|
664
|
+
* under management so users can trace it back and see that it would use
|
|
665
|
+
* this electionManager to manage parameters
|
|
666
|
+
* @param {Instance} contractInstance - include the instance of the contract
|
|
667
|
+
* @param {ClosingRule} closingRule - deadline and timer for closing voting
|
|
668
|
+
* @returns {Promise<QuestionDetails>}
|
|
669
|
+
*/
|
|
670
|
+
/**
|
|
671
|
+
* @template [P=StandardParamPath] path for a paramManagerRetriever
|
|
672
|
+
* @typedef {object} ParamChangeIssue
|
|
673
|
+
* @property {ParamChangesSpec<P>} spec
|
|
674
|
+
* @property {import('@agoric/zoe/src/zoeService/utils.js').Instance<(zcf: ZCF<GovernanceTerms<{}>>) => {}>} contract
|
|
675
|
+
*/
|
|
676
|
+
/**
|
|
677
|
+
* @typedef {object} ApiInvocationIssue
|
|
678
|
+
* @property {string} apiMethodName
|
|
679
|
+
* @property {unknown[]} methodArgs
|
|
680
|
+
*/
|
|
681
|
+
/**
|
|
682
|
+
* @typedef {object} OfferFilterIssue
|
|
683
|
+
* @property {string[]} strings
|
|
684
|
+
*/
|
|
685
|
+
/**
|
|
686
|
+
* @typedef {object} ParamChangePositions
|
|
687
|
+
* @property {ChangeParamsPosition} positive
|
|
688
|
+
* @property {NoChangeParamsPosition} negative
|
|
689
|
+
*/
|
|
690
|
+
/**
|
|
691
|
+
* @typedef {object} ParamChangeIssueDetails
|
|
692
|
+
* details for a question that can change a contract parameter
|
|
693
|
+
* @property {ChoiceMethod} method
|
|
694
|
+
* @property {ParamChangeIssue<unknown>} issue
|
|
695
|
+
* @property {ParamChangePositions} positions
|
|
696
|
+
* @property {ElectionType} electionType
|
|
697
|
+
* @property {number} maxChoices
|
|
698
|
+
* @property {ClosingRule} closingRule
|
|
699
|
+
* @property {QuorumRule} quorumRule
|
|
700
|
+
* @property {NoChangeParamsPosition} tieOutcome
|
|
701
|
+
* @property {Instance} counterInstance - instance of the VoteCounter
|
|
702
|
+
* @property {Handle<'Question'>} questionHandle
|
|
703
|
+
*/
|
|
704
|
+
/**
|
|
705
|
+
* @typedef {Record<Keyword, ParamValueTyped>} ParamStateRecord a Record containing
|
|
706
|
+
* keyword pairs with descriptions of parameters under governance.
|
|
707
|
+
*/
|
|
708
|
+
/** @typedef {{current: ParamStateRecord}} GovernanceSubscriptionState */
|
|
709
|
+
/**
|
|
710
|
+
* @typedef {object} ParamManagerBase The base paramManager with typed getters
|
|
711
|
+
* @property {() => ERef<ParamStateRecord>} getParams
|
|
712
|
+
* @property {(name: string) => Amount} getAmount
|
|
713
|
+
* @property {(name: string) => Brand} getBrand
|
|
714
|
+
* @property {(name: string) => Instance} getInstance
|
|
715
|
+
* @property {(name: string) => Installation} getInstallation
|
|
716
|
+
* @property {(name: string) => Amount<'set'>} getInvitationAmount
|
|
717
|
+
* @property {(name: string) => bigint} getNat
|
|
718
|
+
* @property {(name: string) => Ratio} getRatio
|
|
719
|
+
* @property {(name: string) => string} getString
|
|
720
|
+
* @property {(name: string) => import('@agoric/time').TimestampRecord} getTimestamp
|
|
721
|
+
* @property {(name: string) => import('@agoric/time').RelativeTimeRecord} getRelativeTime
|
|
722
|
+
* @property {(name: string) => any} getUnknown
|
|
723
|
+
* @property {(name: string, proposedValue: ParamValue) => ParamValue} getVisibleValue - for
|
|
724
|
+
* most types, the visible value is the same as proposedValue. For Invitations
|
|
725
|
+
* the visible value is the amount of the invitation.
|
|
726
|
+
* @property {(name: string) => Promise<Invitation>} getInternalParamValue
|
|
727
|
+
* @property {() => StoredSubscription<GovernanceSubscriptionState>} getSubscription
|
|
728
|
+
*/
|
|
729
|
+
/**
|
|
730
|
+
* @callback UpdateParams
|
|
731
|
+
* @param {Record<string,ParamValue>} paramChanges
|
|
732
|
+
* @returns {Promise<void>}
|
|
733
|
+
*/
|
|
734
|
+
/**
|
|
735
|
+
* These are typed `any` because the builder pattern of paramManager makes it very
|
|
736
|
+
* complicated for the type system to know the set of param-specific functions
|
|
737
|
+
* returned by `.build()`. Instead we let paramManager create the desired methods
|
|
738
|
+
* and use typedParamManager to create a version that includes the static types.
|
|
739
|
+
*
|
|
740
|
+
* @typedef {Record<string, any>} ParamManagerGettersAndUpdaters
|
|
741
|
+
* @typedef {ParamManagerBase & ParamManagerGettersAndUpdaters & {updateParams: UpdateParams}} AnyParamManager
|
|
742
|
+
*/
|
|
743
|
+
/**
|
|
744
|
+
* @typedef {Record<string, string[]>} ParameterNameList
|
|
745
|
+
*/
|
|
746
|
+
/**
|
|
747
|
+
* @callback AssertParamManagerType
|
|
748
|
+
* @param {ParamType} type
|
|
749
|
+
* @param {ParamValue} value
|
|
750
|
+
* @param {string} name
|
|
751
|
+
*/
|
|
752
|
+
/**
|
|
753
|
+
* @callback BuildParamManager - ParamManager is a facility that governed
|
|
754
|
+
* contracts can use to manage their visible state in a way that allows the
|
|
755
|
+
* ContractGovernor to update values using governance. When paramManager is
|
|
756
|
+
* instantiated inside the contract, the contract has synchronous access to
|
|
757
|
+
* the values, and clients of the contract can verify that a ContractGovernor
|
|
758
|
+
* can change the values in a legible way.
|
|
759
|
+
* @param {Iterable<ParamValueTyped>} paramDescriptions
|
|
760
|
+
* @returns {AnyParamManager}
|
|
761
|
+
*/
|
|
762
|
+
/**
|
|
763
|
+
* @typedef {object} ChangeParamsPosition
|
|
764
|
+
* @property {Record<string,ParamValue>} changes one or more changes to parameters
|
|
765
|
+
*/
|
|
766
|
+
/**
|
|
767
|
+
* @typedef {object} OfferFilterPosition
|
|
768
|
+
* @property {string[]} strings
|
|
769
|
+
*/
|
|
770
|
+
/**
|
|
771
|
+
* @typedef {object} NoChangeOfferFilterPosition
|
|
772
|
+
* @property {string[]} dontUpdate
|
|
773
|
+
*/
|
|
774
|
+
/**
|
|
775
|
+
* @typedef {object} InvokeApiPosition
|
|
776
|
+
* @property {string} apiMethodName
|
|
777
|
+
* @property {unknown[]} methodArgs
|
|
778
|
+
*/
|
|
779
|
+
/**
|
|
780
|
+
* @typedef {object} DontInvokeApiPosition
|
|
781
|
+
* @property {string} dontInvoke
|
|
782
|
+
*/
|
|
783
|
+
/**
|
|
784
|
+
* @typedef {object} NoChangeParamsPosition
|
|
785
|
+
* @property {string[]} noChange Parameters in the proposal that this position
|
|
786
|
+
* is opposed to
|
|
787
|
+
*/
|
|
788
|
+
/**
|
|
789
|
+
* @typedef {object} Governor
|
|
790
|
+
* @property {CreateQuestion} createQuestion
|
|
791
|
+
*/
|
|
792
|
+
/** @typedef {{ [methodName: string]: (...args: any) => unknown }} GovernedApis */
|
|
793
|
+
/**
|
|
794
|
+
* @typedef {object} GovernorPublic
|
|
795
|
+
* @property {() => Promise<Instance>} getElectorate
|
|
796
|
+
* @property {() => Instance} getGovernedContract
|
|
797
|
+
* @property {(voteCounter: Instance) => Promise<void>} validateVoteCounter
|
|
798
|
+
* @property {(regP: ERef<Instance>) => Promise<void>} validateElectorate
|
|
799
|
+
* @property {(closingRule: ClosingRule) => void} validateTimer
|
|
800
|
+
*/
|
|
801
|
+
/**
|
|
802
|
+
* @typedef {object} ParamKey identifier for a paramManager within a contract
|
|
803
|
+
* @property {unknown} key
|
|
804
|
+
*/
|
|
805
|
+
/**
|
|
806
|
+
* Description of a set of coordinated changes for a ParamManager
|
|
807
|
+
*
|
|
808
|
+
* @template P path for a paramManagerRetriever
|
|
809
|
+
* @typedef {object} ParamChangesSpec<P>
|
|
810
|
+
* @property {P} paramPath
|
|
811
|
+
* @property {Record<string, ParamValue>} changes one or more changes to parameters
|
|
812
|
+
*/
|
|
813
|
+
/**
|
|
814
|
+
* @typedef {object} ContractGovernanceVoteResult
|
|
815
|
+
* @property {Instance} instance - instance of the VoteCounter
|
|
816
|
+
* @property {ERef<QuestionDetails>} details
|
|
817
|
+
* @property {Promise<ParamValue>} outcomeOfUpdate - A promise for the result
|
|
818
|
+
* of updating the parameter value. Primarily useful for its behavior on
|
|
819
|
+
* rejection.
|
|
820
|
+
*/
|
|
821
|
+
/**
|
|
822
|
+
* @template {GovernableStartFn} SF Start function of governed contract
|
|
823
|
+
* @typedef {object} GovernorCreatorFacet
|
|
824
|
+
* @property {VoteOnParamChanges} voteOnParamChanges
|
|
825
|
+
* @property {VoteOnApiInvocation} voteOnApiInvocation
|
|
826
|
+
* @property {VoteOnOfferFilter} voteOnOfferFilter
|
|
827
|
+
* @property {() => LimitedCF<SF>} getCreatorFacet facet of the governed contract,
|
|
828
|
+
* with creator-like powers but without the tightly held ability to change
|
|
829
|
+
* param values.
|
|
830
|
+
* @property {(poserInvitation: Invitation) => Promise<void>} replaceElectorate
|
|
831
|
+
* @property {() => AdminFacet} getAdminFacet
|
|
832
|
+
* @property {() => GovernedPublicFacet<Awaited<ReturnType<SF>>['publicFacet']>} getPublicFacet - public facet of the governed contract
|
|
833
|
+
* @property {() => Instance} getInstance - instance of the governed
|
|
834
|
+
* contract
|
|
835
|
+
*/
|
|
836
|
+
/**
|
|
837
|
+
* @typedef GovernedPublicFacetMethods
|
|
838
|
+
* @property {(key?: any) => StoredSubscription<GovernanceSubscriptionState>} getSubscription
|
|
839
|
+
* @property {(key?: any) => ERef<ParamStateRecord>} getGovernedParams - get descriptions of
|
|
840
|
+
* all the governed parameters
|
|
841
|
+
* @property {(name: string) => Amount} getInvitationAmount
|
|
842
|
+
*/
|
|
843
|
+
/**
|
|
844
|
+
* @template {{}} PF Public facet
|
|
845
|
+
* @typedef {PF & GovernedPublicFacetMethods} GovernedPublicFacet
|
|
846
|
+
*/
|
|
847
|
+
/**
|
|
848
|
+
* @template {GovernableStartFn} SF
|
|
849
|
+
* @typedef {ReturnType<Awaited<ReturnType<SF>>['creatorFacet']['getLimitedCreatorFacet']>} LimitedCF
|
|
850
|
+
*/
|
|
851
|
+
/**
|
|
852
|
+
* @template {{}} CF creator facet
|
|
853
|
+
* @typedef GovernedCreatorFacet
|
|
854
|
+
* What a governed contract must return as its creatorFacet in order to be governed
|
|
855
|
+
* @property {() => ParamManagerRetriever} getParamMgrRetriever - allows accessing
|
|
856
|
+
* and updating governed parameters. Should only be directly accessible to the
|
|
857
|
+
* contractGovernor
|
|
858
|
+
* @property {() => ERef<CF>} getLimitedCreatorFacet - the creator
|
|
859
|
+
* facet of the governed contract. Doesn't provide access to any governance
|
|
860
|
+
* functionality
|
|
861
|
+
* @property {(name: string) => Promise<Invitation>} getInvitation
|
|
862
|
+
* @property {() => ERef<GovernedApis>} getGovernedApis
|
|
863
|
+
* @property {() => (string | symbol)[]} getGovernedApiNames
|
|
864
|
+
* @property {(strings: string[]) => void} setOfferFilter
|
|
865
|
+
*/
|
|
866
|
+
/**
|
|
867
|
+
* @typedef {{key: string}} StandardParamPath
|
|
868
|
+
*/
|
|
869
|
+
/**
|
|
870
|
+
* @typedef {object} ParamManagerRetriever
|
|
871
|
+
* @property {(paramKey?: ParamKey) => AnyParamManager} get
|
|
872
|
+
*/
|
|
873
|
+
/**
|
|
874
|
+
* @template [P=StandardParamPath]
|
|
875
|
+
*
|
|
876
|
+
* @callback VoteOnParamChanges
|
|
877
|
+
* @param {Installation} voteCounterInstallation
|
|
878
|
+
* @param {import('@agoric/time').Timestamp} deadline
|
|
879
|
+
* @param {ParamChangesSpec<P>} paramSpec
|
|
880
|
+
* @returns {Promise<ContractGovernanceVoteResult>}
|
|
881
|
+
*/
|
|
882
|
+
/**
|
|
883
|
+
* @callback VoteOnApiInvocation
|
|
884
|
+
* @param {string} apiMethodName
|
|
885
|
+
* @param {unknown[]} methodArgs
|
|
886
|
+
* @param {Installation} voteCounterInstallation
|
|
887
|
+
* @param {import('@agoric/time').Timestamp} deadline
|
|
888
|
+
* @returns {Promise<ContractGovernanceVoteResult>}
|
|
889
|
+
*/
|
|
890
|
+
/**
|
|
891
|
+
* @callback VoteOnOfferFilter
|
|
892
|
+
* @param {Installation} voteCounterInstallation
|
|
893
|
+
* @param {import('@agoric/time').Timestamp} deadline
|
|
894
|
+
* @param {string[]} strings
|
|
895
|
+
* @returns {Promise<ContractGovernanceVoteResult>}
|
|
896
|
+
*/
|
|
897
|
+
/**
|
|
898
|
+
* @typedef {object} ParamGovernor
|
|
899
|
+
* @property {VoteOnParamChanges} voteOnParamChanges
|
|
900
|
+
* @property {CreatedQuestion} createdQuestion
|
|
901
|
+
*/
|
|
902
|
+
/**
|
|
903
|
+
* @typedef {object} ApiGovernor
|
|
904
|
+
* @property {VoteOnApiInvocation} voteOnApiInvocation
|
|
905
|
+
* @property {CreatedQuestion} createdQuestion
|
|
906
|
+
*/
|
|
907
|
+
/**
|
|
908
|
+
* @typedef {object} FilterGovernor
|
|
909
|
+
* @property {VoteOnOfferFilter} voteOnFilter
|
|
910
|
+
* @property {CreatedQuestion} createdQuestion
|
|
911
|
+
*/
|
|
912
|
+
/**
|
|
913
|
+
* @callback CreatedQuestion
|
|
914
|
+
* Was this question created by this ContractGovernor?
|
|
915
|
+
* @param {Instance} questionInstance
|
|
916
|
+
* @returns {boolean}
|
|
917
|
+
*/
|
|
918
|
+
/**
|
|
919
|
+
* @callback PositionIncluded
|
|
920
|
+
* @param {Position[]} positions
|
|
921
|
+
* @param {Position} position
|
|
922
|
+
* @returns {boolean}
|
|
923
|
+
*/
|
|
924
|
+
/**
|
|
925
|
+
* @typedef {object} GovernedContractTerms
|
|
926
|
+
* @property {import('@agoric/time').TimerService} timer
|
|
927
|
+
* @property {IssuerKeywordRecord} issuerKeywordRecord
|
|
928
|
+
* @property {object} privateArgs
|
|
929
|
+
*/
|
|
930
|
+
/**
|
|
931
|
+
* @callback AssertContractGovernance
|
|
932
|
+
*
|
|
933
|
+
* @param {ERef<ZoeService>} zoe
|
|
934
|
+
* @param {import('@agoric/zoe/src/zoeService/utils.js').Instance<(zcf: ZCF<GovernanceTerms<{}>>) => {}>} allegedGoverned
|
|
935
|
+
* @param {Instance} allegedGovernor
|
|
936
|
+
* @param {Installation<import('@agoric/governance/src/contractGovernor.js').start>} contractGovernorInstallation
|
|
937
|
+
* @returns {Promise<GovernancePair>}
|
|
938
|
+
*/
|
|
939
|
+
/**
|
|
940
|
+
* @callback AssertContractElectorate - assert that the contract uses the
|
|
941
|
+
* electorate
|
|
942
|
+
*
|
|
943
|
+
* @param {ERef<ZoeService>} zoe
|
|
944
|
+
* @param {Instance} allegedGovernor
|
|
945
|
+
* @param {Instance} allegedElectorate
|
|
946
|
+
*/
|
|
947
|
+
/**
|
|
948
|
+
* @typedef {ContractStartFunction
|
|
949
|
+
* & ((zcf?: any, pa?: any, baggage?: any) => ERef<{creatorFacet: GovernedCreatorFacet<{}>, publicFacet: GovernedPublicFacet<{}>}>)} GovernableStartFn
|
|
950
|
+
*/
|
|
951
|
+
/**
|
|
952
|
+
* @typedef {import('./contractGovernor.js')['start']} GovernorSF
|
|
953
|
+
*/
|
|
954
|
+
/**
|
|
955
|
+
* @see {StartedInstanceKit}
|
|
956
|
+
* @template {ERef<Installation<GovernableStartFn>>} I
|
|
957
|
+
* @typedef GovernorStartedInstallationKit
|
|
958
|
+
* Same result as StartedInstanceKit but:
|
|
959
|
+
* - typed for contractGovernor installation being started by Zoe. (It in turn starts the governed contract.)
|
|
960
|
+
* - parameterized by Installation instead of StartFunction
|
|
961
|
+
* @property {import('@agoric/zoe/src/zoeService/utils.js').Instance<GovernorSF>} instance
|
|
962
|
+
* @property {AdminFacet} adminFacet
|
|
963
|
+
* @property {GovernorCreatorFacet<InstallationStart<Awaited<I>>>} creatorFacet
|
|
964
|
+
* @property {GovernorPublic} publicFacet
|
|
965
|
+
*/
|
|
966
|
+
/**
|
|
967
|
+
* @see {StartedInstanceKit}
|
|
968
|
+
* @template {GovernableStartFn} SF
|
|
969
|
+
* @typedef GovernanceFacetKit
|
|
970
|
+
* Akin to StartedInstanceKit but designed for the results of starting governed contracts. Used in bootstrap space.
|
|
971
|
+
* @property {AdminFacet} adminFacet of the governed contract
|
|
972
|
+
* @property {LimitedCF<SF>} creatorFacet creator-like facet within the governed contract (without the powers the governor needs)
|
|
973
|
+
* @property {GovernorCreatorFacet<SF>} governorCreatorFacet of the governing contract
|
|
974
|
+
* @property {AdminFacet} governorAdminFacet of the governing contract
|
|
975
|
+
* @property {Awaited<ReturnType<SF>>['publicFacet']} publicFacet
|
|
976
|
+
* @property {Instance} instance
|
|
977
|
+
* @property {Instance} governor
|
|
978
|
+
*/
|
|
979
|
+
governed: Record<string, unknown>;
|
|
980
|
+
}, baggage: import("@agoric/vat-data").Baggage) => Promise<{
|
|
981
|
+
creatorFacet: GovernorCreatorFacet<SF>;
|
|
982
|
+
publicFacet: GovernorPublic;
|
|
515
983
|
}>)>) => Promise<GovernancePair>;
|
|
516
984
|
/**
|
|
517
985
|
* - assert that the contract uses the
|
|
518
986
|
* electorate
|
|
519
987
|
*/
|
|
520
988
|
export type AssertContractElectorate = (zoe: ERef<ZoeService>, allegedGovernor: Instance, allegedElectorate: Instance) => any;
|
|
521
|
-
export type GovernableStartFn =
|
|
989
|
+
export type GovernableStartFn = ContractStartFunction & ((zcf?: any, pa?: any, baggage?: any) => ERef<{
|
|
522
990
|
creatorFacet: GovernedCreatorFacet<{}>;
|
|
523
991
|
publicFacet: GovernedPublicFacet<{}>;
|
|
524
992
|
}>);
|
|
@@ -559,4 +1027,5 @@ export type GovernanceFacetKit<SF extends GovernableStartFn> = {
|
|
|
559
1027
|
governor: Instance;
|
|
560
1028
|
};
|
|
561
1029
|
import type { ParamType } from './constants.js';
|
|
1030
|
+
import type { ContractStartFunction } from '@agoric/zoe/src/zoeService/utils.js';
|
|
562
1031
|
//# sourceMappingURL=types.d.ts.map
|
package/src/types.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["types.js"],"names":[],"mappings":";;;;;;;;;
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["types.js"],"names":[],"mappings":";;;;;;;;;2BAKc,UAAU,GAAG,OAAO,GAAG,WAAW;;;;;;;2BAWlC,cAAc,GAAG,UAAU,GAAG,QAAQ,GAAG,gBAAgB,GACtE,cAAkB;yBAUL,UAAU,GAAG,KAAK,GAAG,WAAW;;UAKhC,MAAM;;yBAIN,MAAM,GAAG,KAAK,GAAG,YAAY,GAAG,QAAQ,GAAG,MAAM,GAC9D,KAAS,GAAG,MAAM,GAAG,OAAO,cAAc,EAAE,eAAe,GAC3D,OAAW,cAAc,EAAE,kBAAkB,GAAG,OAAO;qDAQ3C,CAAC,SAAS,QAAQ,GAAG,OAAO,GAAG,CAAC,GAC5C,CAAG,SAAS,OAAO,GAAG,KAAK,GAC3B,CAAG,SAAS,cAAc,GAAG,YAAY,GACzC,CAAG,SAAS,UAAU,GAAG,QAAQ,GACjC,CAAG,SAAS,YAAY,GAAG,OAAO,KAAK,CAAC,GACxC,CAAG,SAAS,KAAK,GAAG,MAAM,GAC1B,CAAG,SAAS,OAAO,GAAG,KAAK,GAC3B,CAAG,SAAS,QAAQ,GAAG,MAAM,GAC7B,CAAG,SAAS,WAAW,GAAG,OAAO,cAAc,EAAE,SAAS,GAC1D,CAAG,SAAS,cAAc,GAAG,OAAO,cA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ality' } ChoiceMethod
|
|
5
7
|
* * UNRANKED: "unranked voting" means that the voter specifies some number of
|
|
@@ -696,7 +698,7 @@ export {};
|
|
|
696
698
|
*/
|
|
697
699
|
|
|
698
700
|
/**
|
|
699
|
-
* @typedef {
|
|
701
|
+
* @typedef {ContractStartFunction
|
|
700
702
|
* & ((zcf?: any, pa?: any, baggage?: any) => ERef<{creatorFacet: GovernedCreatorFacet<{}>, publicFacet: GovernedPublicFacet<{}>}>)} GovernableStartFn
|
|
701
703
|
*/
|
|
702
704
|
|