@agoric/cosmos 0.35.0-u20.0 → 0.35.0-u21.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 (113) hide show
  1. package/.clang-format +116 -0
  2. package/CHANGELOG.md +14 -2
  3. package/Makefile +38 -67
  4. package/ante/ante.go +2 -2
  5. package/ante/inbound_test.go +1 -1
  6. package/app/app.go +173 -142
  7. package/app/export.go +6 -6
  8. package/app/genesis.go +4 -0
  9. package/app/sim_test.go +299 -50
  10. package/app/upgrade.go +125 -24
  11. package/app/upgrade_test.go +1 -1
  12. package/cmd/agd/agvm.go +1 -1
  13. package/cmd/agd/main.go +1 -1
  14. package/cmd/libdaemon/main.go +34 -1
  15. package/daemon/cmd/root.go +26 -35
  16. package/daemon/cmd/root_test.go +5 -4
  17. package/daemon/cmd/testnet.go +221 -95
  18. package/daemon/main.go +1 -0
  19. package/git-revision.txt +1 -1
  20. package/go.mod +93 -58
  21. package/go.sum +148 -95
  22. package/package.json +6 -3
  23. package/proto/agoric/swingset/genesis.proto +7 -11
  24. package/proto/agoric/swingset/msgs.proto +56 -75
  25. package/proto/agoric/swingset/query.proto +7 -10
  26. package/proto/agoric/swingset/swingset.proto +79 -108
  27. package/proto/agoric/vbank/genesis.proto +5 -5
  28. package/proto/agoric/vbank/msgs.proto +1 -2
  29. package/proto/agoric/vbank/vbank.proto +42 -52
  30. package/proto/agoric/vibc/msgs.proto +8 -11
  31. package/proto/agoric/vstorage/genesis.proto +6 -9
  32. package/proto/agoric/vstorage/query.proto +19 -48
  33. package/proto/agoric/vstorage/vstorage.proto +4 -10
  34. package/proto/agoric/vtransfer/genesis.proto +7 -7
  35. package/proto/buf.gen.gogo.yaml +8 -0
  36. package/proto/buf.gen.pulsar.yaml +17 -0
  37. package/proto/buf.gen.swagger.yaml +5 -0
  38. package/proto/buf.yaml +10 -0
  39. package/scripts/protocgen.sh +14 -21
  40. package/third_party/proto/amino/amino.proto +79 -0
  41. package/third_party/proto/cosmos/base/v1beta1/coin.proto +7 -2
  42. package/third_party/proto/cosmos/ics23/v1/proofs.proto +243 -0
  43. package/third_party/proto/cosmos/msg/v1/msg.proto +30 -0
  44. package/third_party/proto/cosmos/upgrade/v1beta1/upgrade.proto +17 -5
  45. package/third_party/proto/cosmos_proto/cosmos.proto +16 -1
  46. package/third_party/proto/gogoproto/gogo.proto +2 -2
  47. package/third_party/proto/google/protobuf/any.proto +6 -3
  48. package/third_party/proto/ibc/core/channel/v1/channel.proto +1 -1
  49. package/third_party/proto/ibc/core/client/v1/client.proto +4 -2
  50. package/types/address_hooks.go +2 -2
  51. package/types/address_hooks_test.go +3 -3
  52. package/types/ibc_packet.go +3 -3
  53. package/types/ibc_packet_test.go +3 -3
  54. package/vm/client.go +32 -7
  55. package/vm/proto_json.go +2 -2
  56. package/x/swingset/abci.go +1 -1
  57. package/x/swingset/alias.go +0 -1
  58. package/x/swingset/config.go +1 -1
  59. package/x/swingset/keeper/extension_snapshotter.go +1 -1
  60. package/x/swingset/keeper/extension_snapshotter_test.go +1 -1
  61. package/x/swingset/keeper/keeper.go +1 -1
  62. package/x/swingset/keeper/keeper_test.go +1 -1
  63. package/x/swingset/keeper/querier.go +1 -30
  64. package/x/swingset/keeper/swing_store_exports_handler.go +1 -1
  65. package/x/swingset/keeper/swing_store_exports_handler_test.go +1 -1
  66. package/x/swingset/module.go +1 -14
  67. package/x/swingset/types/default-params.go +24 -16
  68. package/x/swingset/types/genesis.pb.go +2 -2
  69. package/x/swingset/types/msgs.pb.go +4 -3
  70. package/x/swingset/types/msgs_test.go +1 -1
  71. package/x/swingset/types/query.pb.go +4 -3
  72. package/x/swingset/types/swingset.pb.go +2 -2
  73. package/x/vbank/genesis.go +1 -1
  74. package/x/vbank/keeper/querier.go +1 -21
  75. package/x/vbank/module.go +1 -16
  76. package/x/vbank/types/genesis.pb.go +2 -2
  77. package/x/vbank/types/msgs.pb.go +3 -2
  78. package/x/vbank/types/query.pb.go +4 -3
  79. package/x/vbank/types/vbank.pb.go +2 -2
  80. package/x/vbank/vbank_test.go +95 -16
  81. package/x/vibc/keeper/keeper.go +8 -5
  82. package/x/vibc/keeper/migrations.go +36 -0
  83. package/x/vibc/keeper/triggers.go +1 -1
  84. package/x/vibc/module.go +9 -17
  85. package/x/vibc/types/expected_keepers.go +5 -10
  86. package/x/vibc/types/ibc_module.go +4 -4
  87. package/x/vibc/types/msgs.go +1 -1
  88. package/x/vibc/types/msgs.pb.go +5 -4
  89. package/x/vibc/types/receiver.go +2 -2
  90. package/x/vlocalchain/keeper/keeper.go +3 -3
  91. package/x/vlocalchain/types/vlocalchain.pb.go +1 -1
  92. package/x/vlocalchain/vlocalchain_test.go +6 -6
  93. package/x/vstorage/alias.go +0 -1
  94. package/x/vstorage/client/cli/query.go +1 -1
  95. package/x/vstorage/genesis.go +1 -1
  96. package/x/vstorage/keeper/keeper.go +6 -5
  97. package/x/vstorage/keeper/keeper_test.go +24 -24
  98. package/x/vstorage/keeper/querier.go +1 -32
  99. package/x/vstorage/keeper/querier_test.go +41 -6
  100. package/x/vstorage/module.go +1 -14
  101. package/x/vstorage/types/genesis.pb.go +2 -2
  102. package/x/vstorage/types/query.pb.go +8 -5
  103. package/x/vstorage/types/vstorage.pb.go +2 -2
  104. package/x/vstorage/vstorage_test.go +3 -3
  105. package/x/vtransfer/genesis.go +1 -1
  106. package/x/vtransfer/ibc_middleware.go +4 -4
  107. package/x/vtransfer/ibc_middleware_test.go +10 -11
  108. package/x/vtransfer/keeper/keeper.go +5 -5
  109. package/x/vtransfer/module.go +1 -14
  110. package/x/vtransfer/types/expected_keepers.go +2 -18
  111. package/x/vtransfer/types/genesis.pb.go +2 -2
  112. package/x/vtransfer/utils_test.go +15 -15
  113. package/daemon/cmd/genaccounts.go +0 -195
package/package.json CHANGED
@@ -1,13 +1,13 @@
1
1
  {
2
2
  "name": "@agoric/cosmos",
3
- "version": "0.35.0-u20.0",
3
+ "version": "0.35.0-u21.0",
4
4
  "description": "Connect JS to the Cosmos blockchain SDK",
5
5
  "parsers": {
6
6
  "js": "mjs"
7
7
  },
8
8
  "main": "index.cjs",
9
9
  "engines": {
10
- "node": "^18.12 || ^20.9"
10
+ "node": "^20.9 || ^22.11"
11
11
  },
12
12
  "scripts": {
13
13
  "test": "exit 0",
@@ -26,6 +26,9 @@
26
26
  "napi-thread-safe-callback": "0.0.6",
27
27
  "node-addon-api": "^1.7.1"
28
28
  },
29
+ "devDependencies": {
30
+ "node-gyp": "^10.2.0"
31
+ },
29
32
  "author": "Agoric",
30
33
  "license": "Apache-2.0",
31
34
  "bugs": {
@@ -38,5 +41,5 @@
38
41
  "typeCoverage": {
39
42
  "atLeast": 0
40
43
  },
41
- "gitHead": "8e4207fa19dabf76c1f91f8779b5b5b93570ecea"
44
+ "gitHead": "e4dd46857133403d584bcf822a81817b355532f9"
42
45
  }
@@ -8,23 +8,19 @@ option go_package = "github.com/Agoric/agoric-sdk/golang/cosmos/x/swingset/types
8
8
 
9
9
  // The initial or exported state.
10
10
  message GenesisState {
11
- option (gogoproto.equal) = false;
11
+ option (gogoproto.equal) = false;
12
12
 
13
- Params params = 2 [(gogoproto.nullable) = false];
13
+ Params params = 2 [(gogoproto.nullable) = false];
14
14
 
15
- State state = 3 [(gogoproto.nullable) = false];
15
+ State state = 3 [(gogoproto.nullable) = false];
16
16
 
17
- repeated SwingStoreExportDataEntry swing_store_export_data = 4 [
18
- (gogoproto.jsontag) = "swingStoreExportData"
19
- ];
17
+ repeated SwingStoreExportDataEntry swing_store_export_data = 4 [(gogoproto.jsontag) = "swingStoreExportData"];
20
18
 
21
- string swing_store_export_data_hash = 5 [
22
- (gogoproto.jsontag) = "swingStoreExportDataHash"
23
- ];
19
+ string swing_store_export_data_hash = 5 [(gogoproto.jsontag) = "swingStoreExportDataHash"];
24
20
  }
25
21
 
26
22
  // A SwingStore "export data" entry.
27
23
  message SwingStoreExportDataEntry {
28
- string key = 1;
29
- string value = 2;
24
+ string key = 1;
25
+ string value = 2;
30
26
  }
@@ -21,25 +21,16 @@ service Msg {
21
21
 
22
22
  // MsgDeliverInbound defines an SDK message for delivering an eventual send
23
23
  message MsgDeliverInbound {
24
- option (gogoproto.equal) = false;
25
-
26
- repeated string messages = 1 [
27
- (gogoproto.jsontag) = "messages",
28
- (gogoproto.moretags) = "yaml:\"messages\""
29
- ];
30
- repeated uint64 nums = 2 [
31
- (gogoproto.jsontag) = "nums",
32
- (gogoproto.moretags) = "yaml:\"nums\""
33
- ];
34
- uint64 ack = 3 [
35
- (gogoproto.jsontag) = "ack",
36
- (gogoproto.moretags) = "yaml:\"ack\""
37
- ];
38
- bytes submitter = 4 [
39
- (gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.AccAddress",
40
- (gogoproto.jsontag) = "submitter",
41
- (gogoproto.moretags) = "yaml:\"submitter\""
42
- ];
24
+ option (gogoproto.equal) = false;
25
+
26
+ repeated string messages = 1 [(gogoproto.jsontag) = "messages", (gogoproto.moretags) = "yaml:\"messages\""];
27
+ repeated uint64 nums = 2 [(gogoproto.jsontag) = "nums", (gogoproto.moretags) = "yaml:\"nums\""];
28
+ uint64 ack = 3 [(gogoproto.jsontag) = "ack", (gogoproto.moretags) = "yaml:\"ack\""];
29
+ bytes submitter = 4 [
30
+ (gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.AccAddress",
31
+ (gogoproto.jsontag) = "submitter",
32
+ (gogoproto.moretags) = "yaml:\"submitter\""
33
+ ];
43
34
  }
44
35
 
45
36
  // MsgDeliverInboundResponse is an empty reply.
@@ -49,16 +40,16 @@ message MsgDeliverInboundResponse {}
49
40
  // action that *does not* spend any assets (other than gas fees/stamps). This
50
41
  // message type is typically protected by feegrant budgets.
51
42
  message MsgWalletAction {
52
- option (gogoproto.equal) = false;
43
+ option (gogoproto.equal) = false;
53
44
 
54
- bytes owner = 1 [
55
- (gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.AccAddress",
56
- (gogoproto.jsontag) = "owner",
57
- (gogoproto.moretags) = "yaml:\"owner\""
58
- ];
45
+ bytes owner = 1 [
46
+ (gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.AccAddress",
47
+ (gogoproto.jsontag) = "owner",
48
+ (gogoproto.moretags) = "yaml:\"owner\""
49
+ ];
59
50
 
60
- // The action to perform, as JSON-stringified marshalled data.
61
- string action = 2;
51
+ // The action to perform, as JSON-stringified marshalled data.
52
+ string action = 2;
62
53
  }
63
54
 
64
55
  // MsgWalletActionResponse is an empty reply.
@@ -68,16 +59,16 @@ message MsgWalletActionResponse {}
68
59
  // perform an action that *does spend the owner's assets.* This message type is
69
60
  // typically protected by explicit confirmation by the user.
70
61
  message MsgWalletSpendAction {
71
- option (gogoproto.equal) = false;
62
+ option (gogoproto.equal) = false;
72
63
 
73
- bytes owner = 1 [
74
- (gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.AccAddress",
75
- (gogoproto.jsontag) = "owner",
76
- (gogoproto.moretags) = "yaml:\"owner\""
77
- ];
64
+ bytes owner = 1 [
65
+ (gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.AccAddress",
66
+ (gogoproto.jsontag) = "owner",
67
+ (gogoproto.moretags) = "yaml:\"owner\""
68
+ ];
78
69
 
79
- // The action to perform, as JSON-stringified marshalled data.
80
- string spend_action = 2;
70
+ // The action to perform, as JSON-stringified marshalled data.
71
+ string spend_action = 2;
81
72
  }
82
73
 
83
74
  // MsgWalletSpendActionResponse is an empty reply.
@@ -85,27 +76,24 @@ message MsgWalletSpendActionResponse {}
85
76
 
86
77
  // MsgProvision defines an SDK message for provisioning a client to the chain
87
78
  message MsgProvision {
88
- option (gogoproto.equal) = false;
89
-
90
- string nickname = 1 [
91
- (gogoproto.jsontag) = "nickname",
92
- (gogoproto.moretags) = "yaml:\"nickname\""
93
- ];
94
- bytes address = 2 [
95
- (gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.AccAddress",
96
- (gogoproto.jsontag) = "address",
97
- (gogoproto.moretags) = "yaml:\"address\""
98
- ];
99
- repeated string power_flags = 3 [
100
- (gogoproto.customname) = "PowerFlags",
101
- (gogoproto.jsontag) = "powerFlags",
102
- (gogoproto.moretags) = "yaml:\"powerFlags\""
103
- ];
104
- bytes submitter = 4 [
105
- (gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.AccAddress",
106
- (gogoproto.jsontag) = "submitter",
107
- (gogoproto.moretags) = "yaml:\"submitter\""
108
- ];
79
+ option (gogoproto.equal) = false;
80
+
81
+ string nickname = 1 [(gogoproto.jsontag) = "nickname", (gogoproto.moretags) = "yaml:\"nickname\""];
82
+ bytes address = 2 [
83
+ (gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.AccAddress",
84
+ (gogoproto.jsontag) = "address",
85
+ (gogoproto.moretags) = "yaml:\"address\""
86
+ ];
87
+ repeated string power_flags = 3 [
88
+ (gogoproto.customname) = "PowerFlags",
89
+ (gogoproto.jsontag) = "powerFlags",
90
+ (gogoproto.moretags) = "yaml:\"powerFlags\""
91
+ ];
92
+ bytes submitter = 4 [
93
+ (gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.AccAddress",
94
+ (gogoproto.jsontag) = "submitter",
95
+ (gogoproto.moretags) = "yaml:\"submitter\""
96
+ ];
109
97
  }
110
98
 
111
99
  // MsgProvisionResponse is an empty reply.
@@ -113,25 +101,18 @@ message MsgProvisionResponse {}
113
101
 
114
102
  // MsgInstallBundle carries a signed bundle to SwingSet.
115
103
  message MsgInstallBundle {
116
- string bundle = 1 [
117
- (gogoproto.jsontag) = "bundle",
118
- (gogoproto.moretags) = "yaml:\"bundle\""
119
- ];
120
- bytes submitter = 2 [
121
- (gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.AccAddress",
122
- (gogoproto.jsontag) = "submitter",
123
- (gogoproto.moretags) = "yaml:\"submitter\""
124
- ];
125
- // Either bundle or compressed_bundle will be set.
126
- // Default compression algorithm is gzip.
127
- bytes compressed_bundle = 3 [
128
- (gogoproto.jsontag) = "compressedBundle",
129
- (gogoproto.moretags) = "yaml:\"compressedBundle\""
130
- ];
131
- // Size in bytes of uncompression of compressed_bundle.
132
- int64 uncompressed_size = 4 [
133
- (gogoproto.jsontag) = "uncompressedSize"
134
- ];
104
+ string bundle = 1 [(gogoproto.jsontag) = "bundle", (gogoproto.moretags) = "yaml:\"bundle\""];
105
+ bytes submitter = 2 [
106
+ (gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.AccAddress",
107
+ (gogoproto.jsontag) = "submitter",
108
+ (gogoproto.moretags) = "yaml:\"submitter\""
109
+ ];
110
+ // Either bundle or compressed_bundle will be set.
111
+ // Default compression algorithm is gzip.
112
+ bytes compressed_bundle = 3
113
+ [(gogoproto.jsontag) = "compressedBundle", (gogoproto.moretags) = "yaml:\"compressedBundle\""];
114
+ // Size in bytes of uncompression of compressed_bundle.
115
+ int64 uncompressed_size = 4 [(gogoproto.jsontag) = "uncompressedSize"];
135
116
  }
136
117
 
137
118
  // MsgInstallBundleResponse is an empty acknowledgement that an install bundle
@@ -37,9 +37,9 @@ message QueryParamsResponse {
37
37
  // QueryEgressRequest is the request type for the Query/Egress RPC method
38
38
  message QueryEgressRequest {
39
39
  bytes peer = 1 [
40
- (gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.AccAddress",
41
- (gogoproto.jsontag) = "peer",
42
- (gogoproto.moretags) = "yaml:\"peer\""
40
+ (gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.AccAddress",
41
+ (gogoproto.jsontag) = "peer",
42
+ (gogoproto.moretags) = "yaml:\"peer\""
43
43
  ];
44
44
  }
45
45
 
@@ -51,16 +51,13 @@ message QueryEgressResponse {
51
51
  // QueryMailboxRequest is the mailbox query.
52
52
  message QueryMailboxRequest {
53
53
  bytes peer = 1 [
54
- (gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.AccAddress",
55
- (gogoproto.jsontag) = "peer",
56
- (gogoproto.moretags) = "yaml:\"peer\""
54
+ (gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.AccAddress",
55
+ (gogoproto.jsontag) = "peer",
56
+ (gogoproto.moretags) = "yaml:\"peer\""
57
57
  ];
58
58
  }
59
59
 
60
60
  // QueryMailboxResponse is the mailbox response.
61
61
  message QueryMailboxResponse {
62
- string value = 1 [
63
- (gogoproto.jsontag) = "value",
64
- (gogoproto.moretags) = "yaml:\"value\""
65
- ];
62
+ string value = 1 [(gogoproto.jsontag) = "value", (gogoproto.moretags) = "yaml:\"value\""];
66
63
  }
@@ -12,12 +12,12 @@ option go_package = "github.com/Agoric/agoric-sdk/golang/cosmos/x/swingset/types
12
12
  message CoreEvalProposal {
13
13
  option (gogoproto.goproto_getters) = false;
14
14
 
15
- string title = 1;
16
- string description = 2;
15
+ string title = 1;
16
+ string description = 2;
17
17
 
18
18
  // Although evals are sequential, they may run concurrently, since they each
19
19
  // can return a Promise.
20
- repeated CoreEval evals = 3 [(gogoproto.nullable) = false];
20
+ repeated CoreEval evals = 3 [(gogoproto.nullable) = false];
21
21
  }
22
22
 
23
23
  // CoreEval defines an individual SwingSet core evaluation, for use in
@@ -29,80 +29,68 @@ message CoreEval {
29
29
 
30
30
  // Evaluate this JavaScript code in a Compartment endowed with `powers` as
31
31
  // well as some powerless helpers.
32
- string js_code = 2 [(gogoproto.moretags) = "yaml:\"js_code\""];
32
+ string js_code = 2 [(gogoproto.moretags) = "yaml:\"js_code\""];
33
33
  }
34
34
 
35
35
  // Params are the swingset configuration/governance parameters.
36
36
  message Params {
37
- option (gogoproto.equal) = true;
38
- option (gogoproto.goproto_stringer) = false;
39
-
40
- // Map from unit name to a value in SwingSet "beans".
41
- // Must not be negative.
42
- //
43
- // These values are used by SwingSet to normalize named per-resource charges
44
- // (maybe rent) in a single Nat usage unit, the "bean".
45
- //
46
- // There is no required order to this list of entries, but all the chain
47
- // nodes must all serialize and deserialize the existing order without
48
- // permuting it.
49
- repeated StringBeans beans_per_unit = 1 [
50
- (gogoproto.nullable) = false
51
- ];
52
-
53
- // The price in Coins per the unit named "fee". This value is used by
54
- // cosmic-swingset JS code to decide how many tokens to charge.
55
- //
56
- // cost = beans_used * fee_unit_price / beans_per_unit["fee"]
57
- repeated cosmos.base.v1beta1.Coin fee_unit_price = 2 [
58
- (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins",
59
- (gogoproto.nullable) = false
60
- ];
61
-
62
- // The SwingSet bootstrap vat configuration file. Not usefully modifiable
63
- // via governance as it is only referenced by the chain's initial
64
- // construction.
65
- string bootstrap_vat_config = 3;
66
-
67
- // If the provision submitter doesn't hold a provisionpass, their requested
68
- // power flags are looked up in this fee menu (first match wins) and the sum
69
- // is charged. If any power flag is not found in this menu, the request is
70
- // rejected.
71
- repeated PowerFlagFee power_flag_fees = 4 [
72
- (gogoproto.nullable) = false
73
- ];
74
-
75
- // Maximum sizes for queues.
76
- // These values are used by SwingSet to compute how many messages should be
77
- // accepted in a block.
78
- //
79
- // There is no required order to this list of entries, but all the chain
80
- // nodes must all serialize and deserialize the existing order without
81
- // permuting it.
82
- repeated QueueSize queue_max = 5 [
83
- (gogoproto.nullable) = false
84
- ];
85
-
86
- // Vat cleanup budget values.
87
- // These values are used by SwingSet to control the pace of removing data
88
- // associated with a terminated vat as described at
89
- // https://github.com/Agoric/agoric-sdk/blob/master/packages/SwingSet/docs/run-policy.md#terminated-vat-cleanup
90
- //
91
- // There is no required order to this list of entries, but all the chain
92
- // nodes must all serialize and deserialize the existing order without
93
- // permuting it.
94
- repeated UintMapEntry vat_cleanup_budget = 6 [
95
- (gogoproto.nullable) = false
96
- ];
37
+ option (gogoproto.equal) = true;
38
+ option (gogoproto.goproto_stringer) = false;
39
+
40
+ // Map from unit name to a value in SwingSet "beans".
41
+ // Must not be negative.
42
+ //
43
+ // These values are used by SwingSet to normalize named per-resource charges
44
+ // (maybe rent) in a single Nat usage unit, the "bean".
45
+ //
46
+ // There is no required order to this list of entries, but all the chain
47
+ // nodes must all serialize and deserialize the existing order without
48
+ // permuting it.
49
+ repeated StringBeans beans_per_unit = 1 [(gogoproto.nullable) = false];
50
+
51
+ // The price in Coins per the unit named "fee". This value is used by
52
+ // cosmic-swingset JS code to decide how many tokens to charge.
53
+ //
54
+ // cost = beans_used * fee_unit_price / beans_per_unit["fee"]
55
+ repeated cosmos.base.v1beta1.Coin fee_unit_price = 2
56
+ [(gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins", (gogoproto.nullable) = false];
57
+
58
+ // The SwingSet bootstrap vat configuration file. Not usefully modifiable
59
+ // via governance as it is only referenced by the chain's initial
60
+ // construction.
61
+ string bootstrap_vat_config = 3;
62
+
63
+ // If the provision submitter doesn't hold a provisionpass, their requested
64
+ // power flags are looked up in this fee menu (first match wins) and the sum
65
+ // is charged. If any power flag is not found in this menu, the request is
66
+ // rejected.
67
+ repeated PowerFlagFee power_flag_fees = 4 [(gogoproto.nullable) = false];
68
+
69
+ // Maximum sizes for queues.
70
+ // These values are used by SwingSet to compute how many messages should be
71
+ // accepted in a block.
72
+ //
73
+ // There is no required order to this list of entries, but all the chain
74
+ // nodes must all serialize and deserialize the existing order without
75
+ // permuting it.
76
+ repeated QueueSize queue_max = 5 [(gogoproto.nullable) = false];
77
+
78
+ // Vat cleanup budget values.
79
+ // These values are used by SwingSet to control the pace of removing data
80
+ // associated with a terminated vat as described at
81
+ // https://github.com/Agoric/agoric-sdk/blob/master/packages/SwingSet/docs/run-policy.md#terminated-vat-cleanup
82
+ //
83
+ // There is no required order to this list of entries, but all the chain
84
+ // nodes must all serialize and deserialize the existing order without
85
+ // permuting it.
86
+ repeated UintMapEntry vat_cleanup_budget = 6 [(gogoproto.nullable) = false];
97
87
  }
98
88
 
99
89
  // The current state of the module.
100
90
  message State {
101
91
  // The allowed number of items to add to queues, as determined by SwingSet.
102
92
  // Transactions which attempt to enqueue more should be rejected.
103
- repeated QueueSize queue_allowed = 1 [
104
- (gogoproto.nullable) = false
105
- ];
93
+ repeated QueueSize queue_allowed = 1 [(gogoproto.nullable) = false];
106
94
  }
107
95
 
108
96
  // Map element of a string key to a Nat bean count.
@@ -113,21 +101,16 @@ message StringBeans {
113
101
  string key = 1;
114
102
 
115
103
  // The actual bean value.
116
- string beans = 2 [
117
- (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Uint",
118
- (gogoproto.nullable) = false
119
- ];
104
+ string beans = 2 [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Uint", (gogoproto.nullable) = false];
120
105
  }
121
106
 
122
107
  // Map a provisioning power flag to its corresponding fee.
123
108
  message PowerFlagFee {
124
109
  option (gogoproto.equal) = true;
125
110
 
126
- string power_flag = 1;
127
- repeated cosmos.base.v1beta1.Coin fee = 2 [
128
- (gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins",
129
- (gogoproto.nullable) = false
130
- ];
111
+ string power_flag = 1;
112
+ repeated cosmos.base.v1beta1.Coin fee = 2
113
+ [(gogoproto.castrepeated) = "github.com/cosmos/cosmos-sdk/types.Coins", (gogoproto.nullable) = false];
131
114
  }
132
115
 
133
116
  // Map element of a string key to a size.
@@ -147,32 +130,26 @@ message QueueSize {
147
130
  // zeroes survive "omitempty" JSON serialization.
148
131
  message UintMapEntry {
149
132
  option (gogoproto.equal) = true;
150
- string key = 1;
151
- string value = 2 [
152
- (gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Uint",
153
- (gogoproto.nullable) = false
154
- ];
133
+ string key = 1;
134
+ string value = 2 [(gogoproto.customtype) = "github.com/cosmos/cosmos-sdk/types.Uint", (gogoproto.nullable) = false];
155
135
  }
156
136
 
157
137
  // Egress is the format for a swingset egress.
158
138
  message Egress {
159
- option (gogoproto.equal) = false;
160
-
161
- string nickname = 1 [
162
- (gogoproto.jsontag) = "nickname",
163
- (gogoproto.moretags) = "yaml:\"nickname\""
164
- ];
165
- bytes peer = 2 [
166
- (gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.AccAddress",
167
- (gogoproto.jsontag) = "peer",
168
- (gogoproto.moretags) = "yaml:\"peer\""
169
- ];
170
- // TODO: Remove these power flags as they are deprecated and have no effect.
171
- repeated string power_flags = 3 [
172
- (gogoproto.customname) = "PowerFlags",
173
- (gogoproto.jsontag) = "powerFlags",
174
- (gogoproto.moretags) = "yaml:\"powerFlags\""
175
- ];
139
+ option (gogoproto.equal) = false;
140
+
141
+ string nickname = 1 [(gogoproto.jsontag) = "nickname", (gogoproto.moretags) = "yaml:\"nickname\""];
142
+ bytes peer = 2 [
143
+ (gogoproto.casttype) = "github.com/cosmos/cosmos-sdk/types.AccAddress",
144
+ (gogoproto.jsontag) = "peer",
145
+ (gogoproto.moretags) = "yaml:\"peer\""
146
+ ];
147
+ // TODO: Remove these power flags as they are deprecated and have no effect.
148
+ repeated string power_flags = 3 [
149
+ (gogoproto.customname) = "PowerFlags",
150
+ (gogoproto.jsontag) = "powerFlags",
151
+ (gogoproto.moretags) = "yaml:\"powerFlags\""
152
+ ];
176
153
  }
177
154
 
178
155
  // SwingStoreArtifact encodes an artifact of a swing-store export.
@@ -180,14 +157,8 @@ message Egress {
180
157
  // maintain the artifact order from their original source as an effect of how
181
158
  // they handle the artifacts.
182
159
  message SwingStoreArtifact {
183
- option (gogoproto.equal) = false;
184
- string name = 1 [
185
- (gogoproto.jsontag) = "name",
186
- (gogoproto.moretags) = "yaml:\"name\""
187
- ];
188
-
189
- bytes data = 2 [
190
- (gogoproto.jsontag) = "data",
191
- (gogoproto.moretags) = "yaml:\"data\""
192
- ];
160
+ option (gogoproto.equal) = false;
161
+ string name = 1 [(gogoproto.jsontag) = "name", (gogoproto.moretags) = "yaml:\"name\""];
162
+
163
+ bytes data = 2 [(gogoproto.jsontag) = "data", (gogoproto.moretags) = "yaml:\"data\""];
193
164
  }
@@ -8,11 +8,11 @@ option go_package = "github.com/Agoric/agoric-sdk/golang/cosmos/x/vbank/types";
8
8
 
9
9
  // The initial and exported module state.
10
10
  message GenesisState {
11
- option (gogoproto.equal) = false;
11
+ option (gogoproto.equal) = false;
12
12
 
13
- // parms defines all the parameters of the module.
14
- Params params = 1 [(gogoproto.nullable) = false];
13
+ // parms defines all the parameters of the module.
14
+ Params params = 1 [(gogoproto.nullable) = false];
15
15
 
16
- // state is the current operation state.
17
- State state = 2 [(gogoproto.nullable) = false];
16
+ // state is the current operation state.
17
+ State state = 2 [(gogoproto.nullable) = false];
18
18
  }
@@ -4,5 +4,4 @@ package agoric.vbank;
4
4
  option go_package = "github.com/Agoric/agoric-sdk/golang/cosmos/x/vbank/types";
5
5
 
6
6
  // No transactions.
7
- service Msg {
8
- }
7
+ service Msg {}