@sparkdreamnft/sparkdreamjs 0.0.23 → 0.0.25
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/esm/sparkdream/forum/v1/hide_record.js +13 -1
- package/esm/sparkdream/forum/v1/params.js +50 -2
- package/esm/sparkdream/forum/v1/sentinel_activity.js +112 -1
- package/esm/sparkdream/forum/v1/thread_lock_record.js +13 -1
- package/esm/sparkdream/forum/v1/thread_metadata.js +24 -0
- package/esm/sparkdream/forum/v1/thread_move_record.js +13 -1
- package/esm/sparkdream/forum/v1/types.js +13 -1
- package/esm/sparkdream/rep/v1/accountability.js +12 -0
- package/esm/sparkdream/rep/v1/params.js +24 -0
- package/package.json +1 -1
- package/sparkdream/bundle.d.ts +12 -0
- package/sparkdream/forum/v1/hide_record.d.ts +14 -0
- package/sparkdream/forum/v1/hide_record.js +13 -1
- package/sparkdream/forum/v1/params.d.ts +48 -0
- package/sparkdream/forum/v1/params.js +50 -2
- package/sparkdream/forum/v1/sentinel_activity.d.ts +129 -0
- package/sparkdream/forum/v1/sentinel_activity.js +113 -2
- package/sparkdream/forum/v1/thread_lock_record.d.ts +12 -0
- package/sparkdream/forum/v1/thread_lock_record.js +13 -1
- package/sparkdream/forum/v1/thread_metadata.d.ts +32 -0
- package/sparkdream/forum/v1/thread_metadata.js +24 -0
- package/sparkdream/forum/v1/thread_move_record.d.ts +12 -0
- package/sparkdream/forum/v1/thread_move_record.js +13 -1
- package/sparkdream/forum/v1/types.d.ts +12 -0
- package/sparkdream/forum/v1/types.js +13 -1
- package/sparkdream/rep/v1/accountability.d.ts +2 -0
- package/sparkdream/rep/v1/accountability.js +12 -0
- package/sparkdream/rep/v1/params.d.ts +24 -0
- package/sparkdream/rep/v1/params.js +24 -0
|
@@ -1,8 +1,104 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.SentinelActivity = void 0;
|
|
3
|
+
exports.SentinelActivity = exports.AccuracyEpochBucket = void 0;
|
|
4
4
|
//@ts-nocheck
|
|
5
5
|
const binary_1 = require("../../../binary");
|
|
6
|
+
function createBaseAccuracyEpochBucket() {
|
|
7
|
+
return {
|
|
8
|
+
epoch: BigInt(0),
|
|
9
|
+
upheld: BigInt(0),
|
|
10
|
+
overturned: BigInt(0)
|
|
11
|
+
};
|
|
12
|
+
}
|
|
13
|
+
/**
|
|
14
|
+
* AccuracyEpochBucket holds one reward-epoch's resolved-appeal tally for a
|
|
15
|
+
* sentinel. Stored in a fixed-size ring on SentinelActivity (slot index =
|
|
16
|
+
* epoch % SentinelAccuracyRingSize); the `epoch` stamp disambiguates a live
|
|
17
|
+
* slot from a stale one left behind by an inactive epoch.
|
|
18
|
+
* @name AccuracyEpochBucket
|
|
19
|
+
* @package sparkdream.forum.v1
|
|
20
|
+
* @see proto type: sparkdream.forum.v1.AccuracyEpochBucket
|
|
21
|
+
*/
|
|
22
|
+
exports.AccuracyEpochBucket = {
|
|
23
|
+
typeUrl: "/sparkdream.forum.v1.AccuracyEpochBucket",
|
|
24
|
+
encode(message, writer = binary_1.BinaryWriter.create()) {
|
|
25
|
+
if (message.epoch !== BigInt(0)) {
|
|
26
|
+
writer.uint32(8).uint64(message.epoch);
|
|
27
|
+
}
|
|
28
|
+
if (message.upheld !== BigInt(0)) {
|
|
29
|
+
writer.uint32(16).uint64(message.upheld);
|
|
30
|
+
}
|
|
31
|
+
if (message.overturned !== BigInt(0)) {
|
|
32
|
+
writer.uint32(24).uint64(message.overturned);
|
|
33
|
+
}
|
|
34
|
+
return writer;
|
|
35
|
+
},
|
|
36
|
+
decode(input, length) {
|
|
37
|
+
const reader = input instanceof binary_1.BinaryReader ? input : new binary_1.BinaryReader(input);
|
|
38
|
+
let end = length === undefined ? reader.len : reader.pos + length;
|
|
39
|
+
const message = createBaseAccuracyEpochBucket();
|
|
40
|
+
while (reader.pos < end) {
|
|
41
|
+
const tag = reader.uint32();
|
|
42
|
+
switch (tag >>> 3) {
|
|
43
|
+
case 1:
|
|
44
|
+
message.epoch = reader.uint64();
|
|
45
|
+
break;
|
|
46
|
+
case 2:
|
|
47
|
+
message.upheld = reader.uint64();
|
|
48
|
+
break;
|
|
49
|
+
case 3:
|
|
50
|
+
message.overturned = reader.uint64();
|
|
51
|
+
break;
|
|
52
|
+
default:
|
|
53
|
+
reader.skipType(tag & 7);
|
|
54
|
+
break;
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
return message;
|
|
58
|
+
},
|
|
59
|
+
fromPartial(object) {
|
|
60
|
+
const message = createBaseAccuracyEpochBucket();
|
|
61
|
+
message.epoch = object.epoch !== undefined && object.epoch !== null ? BigInt(object.epoch.toString()) : BigInt(0);
|
|
62
|
+
message.upheld = object.upheld !== undefined && object.upheld !== null ? BigInt(object.upheld.toString()) : BigInt(0);
|
|
63
|
+
message.overturned = object.overturned !== undefined && object.overturned !== null ? BigInt(object.overturned.toString()) : BigInt(0);
|
|
64
|
+
return message;
|
|
65
|
+
},
|
|
66
|
+
fromAmino(object) {
|
|
67
|
+
const message = createBaseAccuracyEpochBucket();
|
|
68
|
+
if (object.epoch !== undefined && object.epoch !== null) {
|
|
69
|
+
message.epoch = BigInt(object.epoch);
|
|
70
|
+
}
|
|
71
|
+
if (object.upheld !== undefined && object.upheld !== null) {
|
|
72
|
+
message.upheld = BigInt(object.upheld);
|
|
73
|
+
}
|
|
74
|
+
if (object.overturned !== undefined && object.overturned !== null) {
|
|
75
|
+
message.overturned = BigInt(object.overturned);
|
|
76
|
+
}
|
|
77
|
+
return message;
|
|
78
|
+
},
|
|
79
|
+
toAmino(message) {
|
|
80
|
+
const obj = {};
|
|
81
|
+
obj.epoch = message.epoch !== BigInt(0) ? message.epoch?.toString() : undefined;
|
|
82
|
+
obj.upheld = message.upheld !== BigInt(0) ? message.upheld?.toString() : undefined;
|
|
83
|
+
obj.overturned = message.overturned !== BigInt(0) ? message.overturned?.toString() : undefined;
|
|
84
|
+
return obj;
|
|
85
|
+
},
|
|
86
|
+
fromAminoMsg(object) {
|
|
87
|
+
return exports.AccuracyEpochBucket.fromAmino(object.value);
|
|
88
|
+
},
|
|
89
|
+
fromProtoMsg(message) {
|
|
90
|
+
return exports.AccuracyEpochBucket.decode(message.value);
|
|
91
|
+
},
|
|
92
|
+
toProto(message) {
|
|
93
|
+
return exports.AccuracyEpochBucket.encode(message).finish();
|
|
94
|
+
},
|
|
95
|
+
toProtoMsg(message) {
|
|
96
|
+
return {
|
|
97
|
+
typeUrl: "/sparkdream.forum.v1.AccuracyEpochBucket",
|
|
98
|
+
value: exports.AccuracyEpochBucket.encode(message).finish()
|
|
99
|
+
};
|
|
100
|
+
}
|
|
101
|
+
};
|
|
6
102
|
function createBaseSentinelActivity() {
|
|
7
103
|
return {
|
|
8
104
|
address: "",
|
|
@@ -32,7 +128,8 @@ function createBaseSentinelActivity() {
|
|
|
32
128
|
totalProposals: BigInt(0),
|
|
33
129
|
confirmedProposals: BigInt(0),
|
|
34
130
|
rejectedProposals: BigInt(0),
|
|
35
|
-
epochCurations: BigInt(0)
|
|
131
|
+
epochCurations: BigInt(0),
|
|
132
|
+
accuracyWindow: []
|
|
36
133
|
};
|
|
37
134
|
}
|
|
38
135
|
/**
|
|
@@ -130,6 +227,9 @@ exports.SentinelActivity = {
|
|
|
130
227
|
if (message.epochCurations !== BigInt(0)) {
|
|
131
228
|
writer.uint32(224).uint64(message.epochCurations);
|
|
132
229
|
}
|
|
230
|
+
for (const v of message.accuracyWindow) {
|
|
231
|
+
exports.AccuracyEpochBucket.encode(v, writer.uint32(234).fork()).ldelim();
|
|
232
|
+
}
|
|
133
233
|
return writer;
|
|
134
234
|
},
|
|
135
235
|
decode(input, length) {
|
|
@@ -223,6 +323,9 @@ exports.SentinelActivity = {
|
|
|
223
323
|
case 28:
|
|
224
324
|
message.epochCurations = reader.uint64();
|
|
225
325
|
break;
|
|
326
|
+
case 29:
|
|
327
|
+
message.accuracyWindow.push(exports.AccuracyEpochBucket.decode(reader, reader.uint32()));
|
|
328
|
+
break;
|
|
226
329
|
default:
|
|
227
330
|
reader.skipType(tag & 7);
|
|
228
331
|
break;
|
|
@@ -260,6 +363,7 @@ exports.SentinelActivity = {
|
|
|
260
363
|
message.confirmedProposals = object.confirmedProposals !== undefined && object.confirmedProposals !== null ? BigInt(object.confirmedProposals.toString()) : BigInt(0);
|
|
261
364
|
message.rejectedProposals = object.rejectedProposals !== undefined && object.rejectedProposals !== null ? BigInt(object.rejectedProposals.toString()) : BigInt(0);
|
|
262
365
|
message.epochCurations = object.epochCurations !== undefined && object.epochCurations !== null ? BigInt(object.epochCurations.toString()) : BigInt(0);
|
|
366
|
+
message.accuracyWindow = object.accuracyWindow?.map(e => exports.AccuracyEpochBucket.fromPartial(e)) || [];
|
|
263
367
|
return message;
|
|
264
368
|
},
|
|
265
369
|
fromAmino(object) {
|
|
@@ -348,6 +452,7 @@ exports.SentinelActivity = {
|
|
|
348
452
|
if (object.epoch_curations !== undefined && object.epoch_curations !== null) {
|
|
349
453
|
message.epochCurations = BigInt(object.epoch_curations);
|
|
350
454
|
}
|
|
455
|
+
message.accuracyWindow = object.accuracy_window?.map(e => exports.AccuracyEpochBucket.fromAmino(e)) || [];
|
|
351
456
|
return message;
|
|
352
457
|
},
|
|
353
458
|
toAmino(message) {
|
|
@@ -380,6 +485,12 @@ exports.SentinelActivity = {
|
|
|
380
485
|
obj.confirmed_proposals = message.confirmedProposals !== BigInt(0) ? message.confirmedProposals?.toString() : undefined;
|
|
381
486
|
obj.rejected_proposals = message.rejectedProposals !== BigInt(0) ? message.rejectedProposals?.toString() : undefined;
|
|
382
487
|
obj.epoch_curations = message.epochCurations !== BigInt(0) ? message.epochCurations?.toString() : undefined;
|
|
488
|
+
if (message.accuracyWindow) {
|
|
489
|
+
obj.accuracy_window = message.accuracyWindow.map(e => e ? exports.AccuracyEpochBucket.toAmino(e) : undefined);
|
|
490
|
+
}
|
|
491
|
+
else {
|
|
492
|
+
obj.accuracy_window = message.accuracyWindow;
|
|
493
|
+
}
|
|
383
494
|
return obj;
|
|
384
495
|
},
|
|
385
496
|
fromAminoMsg(object) {
|
|
@@ -15,6 +15,12 @@ export interface ThreadLockRecord {
|
|
|
15
15
|
lockReason: string;
|
|
16
16
|
appealPending: boolean;
|
|
17
17
|
initiativeId: bigint;
|
|
18
|
+
/**
|
|
19
|
+
* committed_amount is the sentinel bond (udream, as a string) reserved at lock
|
|
20
|
+
* time. Released on self-unlock or an upheld appeal, and the amount slashed
|
|
21
|
+
* basis on an overturn. Empty for governance-authority locks (no bond).
|
|
22
|
+
*/
|
|
23
|
+
committedAmount: string;
|
|
18
24
|
}
|
|
19
25
|
export interface ThreadLockRecordProtoMsg {
|
|
20
26
|
typeUrl: "/sparkdream.forum.v1.ThreadLockRecord";
|
|
@@ -35,6 +41,12 @@ export interface ThreadLockRecordAmino {
|
|
|
35
41
|
lock_reason?: string;
|
|
36
42
|
appeal_pending?: boolean;
|
|
37
43
|
initiative_id?: string;
|
|
44
|
+
/**
|
|
45
|
+
* committed_amount is the sentinel bond (udream, as a string) reserved at lock
|
|
46
|
+
* time. Released on self-unlock or an upheld appeal, and the amount slashed
|
|
47
|
+
* basis on an overturn. Empty for governance-authority locks (no bond).
|
|
48
|
+
*/
|
|
49
|
+
committed_amount?: string;
|
|
38
50
|
}
|
|
39
51
|
export interface ThreadLockRecordAminoMsg {
|
|
40
52
|
type: "/sparkdream.forum.v1.ThreadLockRecord";
|
|
@@ -12,7 +12,8 @@ function createBaseThreadLockRecord() {
|
|
|
12
12
|
sentinelBackingSnapshot: "",
|
|
13
13
|
lockReason: "",
|
|
14
14
|
appealPending: false,
|
|
15
|
-
initiativeId: BigInt(0)
|
|
15
|
+
initiativeId: BigInt(0),
|
|
16
|
+
committedAmount: ""
|
|
16
17
|
};
|
|
17
18
|
}
|
|
18
19
|
/**
|
|
@@ -48,6 +49,9 @@ exports.ThreadLockRecord = {
|
|
|
48
49
|
if (message.initiativeId !== BigInt(0)) {
|
|
49
50
|
writer.uint32(64).uint64(message.initiativeId);
|
|
50
51
|
}
|
|
52
|
+
if (message.committedAmount !== "") {
|
|
53
|
+
writer.uint32(74).string(message.committedAmount);
|
|
54
|
+
}
|
|
51
55
|
return writer;
|
|
52
56
|
},
|
|
53
57
|
decode(input, length) {
|
|
@@ -81,6 +85,9 @@ exports.ThreadLockRecord = {
|
|
|
81
85
|
case 8:
|
|
82
86
|
message.initiativeId = reader.uint64();
|
|
83
87
|
break;
|
|
88
|
+
case 9:
|
|
89
|
+
message.committedAmount = reader.string();
|
|
90
|
+
break;
|
|
84
91
|
default:
|
|
85
92
|
reader.skipType(tag & 7);
|
|
86
93
|
break;
|
|
@@ -98,6 +105,7 @@ exports.ThreadLockRecord = {
|
|
|
98
105
|
message.lockReason = object.lockReason ?? "";
|
|
99
106
|
message.appealPending = object.appealPending ?? false;
|
|
100
107
|
message.initiativeId = object.initiativeId !== undefined && object.initiativeId !== null ? BigInt(object.initiativeId.toString()) : BigInt(0);
|
|
108
|
+
message.committedAmount = object.committedAmount ?? "";
|
|
101
109
|
return message;
|
|
102
110
|
},
|
|
103
111
|
fromAmino(object) {
|
|
@@ -126,6 +134,9 @@ exports.ThreadLockRecord = {
|
|
|
126
134
|
if (object.initiative_id !== undefined && object.initiative_id !== null) {
|
|
127
135
|
message.initiativeId = BigInt(object.initiative_id);
|
|
128
136
|
}
|
|
137
|
+
if (object.committed_amount !== undefined && object.committed_amount !== null) {
|
|
138
|
+
message.committedAmount = object.committed_amount;
|
|
139
|
+
}
|
|
129
140
|
return message;
|
|
130
141
|
},
|
|
131
142
|
toAmino(message) {
|
|
@@ -138,6 +149,7 @@ exports.ThreadLockRecord = {
|
|
|
138
149
|
obj.lock_reason = message.lockReason === "" ? undefined : message.lockReason;
|
|
139
150
|
obj.appeal_pending = message.appealPending === false ? undefined : message.appealPending;
|
|
140
151
|
obj.initiative_id = message.initiativeId !== BigInt(0) ? message.initiativeId?.toString() : undefined;
|
|
152
|
+
obj.committed_amount = message.committedAmount === "" ? undefined : message.committedAmount;
|
|
141
153
|
return obj;
|
|
142
154
|
},
|
|
143
155
|
fromAminoMsg(object) {
|
|
@@ -15,6 +15,22 @@ export interface ThreadMetadata {
|
|
|
15
15
|
proposedReplyId: bigint;
|
|
16
16
|
proposedBy: string;
|
|
17
17
|
proposedAt: bigint;
|
|
18
|
+
/**
|
|
19
|
+
* proposal_extended is set true once the auto-confirm EndBlocker has granted
|
|
20
|
+
* the one-time inactivity extension to a pending proposal (author appeared
|
|
21
|
+
* inactive when the timeout first elapsed). Prevents an indefinite extension
|
|
22
|
+
* loop — the next timeout auto-confirms regardless. Cleared when the proposal
|
|
23
|
+
* resolves (confirm/reject/auto-confirm).
|
|
24
|
+
*/
|
|
25
|
+
proposalExtended: boolean;
|
|
26
|
+
/**
|
|
27
|
+
* proposal_fire_at is the exact ProposalAutoConfirmQueue key (unix seconds)
|
|
28
|
+
* under which the current pending proposal is enqueued. Stored so the manual
|
|
29
|
+
* confirm/reject paths can remove the precise queue entry, and so the
|
|
30
|
+
* EndBlocker can detect-and-drop stale entries (a key whose fire_at no longer
|
|
31
|
+
* matches the live proposal). 0 = no pending proposal.
|
|
32
|
+
*/
|
|
33
|
+
proposalFireAt: bigint;
|
|
18
34
|
pinnedReplyIds: bigint[];
|
|
19
35
|
pinnedRecords: PinnedReplyRecord[];
|
|
20
36
|
}
|
|
@@ -36,6 +52,22 @@ export interface ThreadMetadataAmino {
|
|
|
36
52
|
proposed_reply_id?: string;
|
|
37
53
|
proposed_by?: string;
|
|
38
54
|
proposed_at?: string;
|
|
55
|
+
/**
|
|
56
|
+
* proposal_extended is set true once the auto-confirm EndBlocker has granted
|
|
57
|
+
* the one-time inactivity extension to a pending proposal (author appeared
|
|
58
|
+
* inactive when the timeout first elapsed). Prevents an indefinite extension
|
|
59
|
+
* loop — the next timeout auto-confirms regardless. Cleared when the proposal
|
|
60
|
+
* resolves (confirm/reject/auto-confirm).
|
|
61
|
+
*/
|
|
62
|
+
proposal_extended?: boolean;
|
|
63
|
+
/**
|
|
64
|
+
* proposal_fire_at is the exact ProposalAutoConfirmQueue key (unix seconds)
|
|
65
|
+
* under which the current pending proposal is enqueued. Stored so the manual
|
|
66
|
+
* confirm/reject paths can remove the precise queue entry, and so the
|
|
67
|
+
* EndBlocker can detect-and-drop stale entries (a key whose fire_at no longer
|
|
68
|
+
* matches the live proposal). 0 = no pending proposal.
|
|
69
|
+
*/
|
|
70
|
+
proposal_fire_at?: string;
|
|
39
71
|
pinned_reply_ids?: string[];
|
|
40
72
|
pinned_records?: PinnedReplyRecordAmino[];
|
|
41
73
|
}
|
|
@@ -13,6 +13,8 @@ function createBaseThreadMetadata() {
|
|
|
13
13
|
proposedReplyId: BigInt(0),
|
|
14
14
|
proposedBy: "",
|
|
15
15
|
proposedAt: BigInt(0),
|
|
16
|
+
proposalExtended: false,
|
|
17
|
+
proposalFireAt: BigInt(0),
|
|
16
18
|
pinnedReplyIds: [],
|
|
17
19
|
pinnedRecords: []
|
|
18
20
|
};
|
|
@@ -47,6 +49,12 @@ exports.ThreadMetadata = {
|
|
|
47
49
|
if (message.proposedAt !== BigInt(0)) {
|
|
48
50
|
writer.uint32(56).int64(message.proposedAt);
|
|
49
51
|
}
|
|
52
|
+
if (message.proposalExtended === true) {
|
|
53
|
+
writer.uint32(64).bool(message.proposalExtended);
|
|
54
|
+
}
|
|
55
|
+
if (message.proposalFireAt !== BigInt(0)) {
|
|
56
|
+
writer.uint32(72).int64(message.proposalFireAt);
|
|
57
|
+
}
|
|
50
58
|
writer.uint32(82).fork();
|
|
51
59
|
for (const v of message.pinnedReplyIds) {
|
|
52
60
|
writer.uint64(v);
|
|
@@ -85,6 +93,12 @@ exports.ThreadMetadata = {
|
|
|
85
93
|
case 7:
|
|
86
94
|
message.proposedAt = reader.int64();
|
|
87
95
|
break;
|
|
96
|
+
case 8:
|
|
97
|
+
message.proposalExtended = reader.bool();
|
|
98
|
+
break;
|
|
99
|
+
case 9:
|
|
100
|
+
message.proposalFireAt = reader.int64();
|
|
101
|
+
break;
|
|
88
102
|
case 10:
|
|
89
103
|
if ((tag & 7) === 2) {
|
|
90
104
|
const end2 = reader.uint32() + reader.pos;
|
|
@@ -115,6 +129,8 @@ exports.ThreadMetadata = {
|
|
|
115
129
|
message.proposedReplyId = object.proposedReplyId !== undefined && object.proposedReplyId !== null ? BigInt(object.proposedReplyId.toString()) : BigInt(0);
|
|
116
130
|
message.proposedBy = object.proposedBy ?? "";
|
|
117
131
|
message.proposedAt = object.proposedAt !== undefined && object.proposedAt !== null ? BigInt(object.proposedAt.toString()) : BigInt(0);
|
|
132
|
+
message.proposalExtended = object.proposalExtended ?? false;
|
|
133
|
+
message.proposalFireAt = object.proposalFireAt !== undefined && object.proposalFireAt !== null ? BigInt(object.proposalFireAt.toString()) : BigInt(0);
|
|
118
134
|
message.pinnedReplyIds = object.pinnedReplyIds?.map(e => BigInt(e.toString())) || [];
|
|
119
135
|
message.pinnedRecords = object.pinnedRecords?.map(e => types_1.PinnedReplyRecord.fromPartial(e)) || [];
|
|
120
136
|
return message;
|
|
@@ -142,6 +158,12 @@ exports.ThreadMetadata = {
|
|
|
142
158
|
if (object.proposed_at !== undefined && object.proposed_at !== null) {
|
|
143
159
|
message.proposedAt = BigInt(object.proposed_at);
|
|
144
160
|
}
|
|
161
|
+
if (object.proposal_extended !== undefined && object.proposal_extended !== null) {
|
|
162
|
+
message.proposalExtended = object.proposal_extended;
|
|
163
|
+
}
|
|
164
|
+
if (object.proposal_fire_at !== undefined && object.proposal_fire_at !== null) {
|
|
165
|
+
message.proposalFireAt = BigInt(object.proposal_fire_at);
|
|
166
|
+
}
|
|
145
167
|
message.pinnedReplyIds = object.pinned_reply_ids?.map(e => BigInt(e)) || [];
|
|
146
168
|
message.pinnedRecords = object.pinned_records?.map(e => types_1.PinnedReplyRecord.fromAmino(e)) || [];
|
|
147
169
|
return message;
|
|
@@ -155,6 +177,8 @@ exports.ThreadMetadata = {
|
|
|
155
177
|
obj.proposed_reply_id = message.proposedReplyId !== BigInt(0) ? message.proposedReplyId?.toString() : undefined;
|
|
156
178
|
obj.proposed_by = message.proposedBy === "" ? undefined : message.proposedBy;
|
|
157
179
|
obj.proposed_at = message.proposedAt !== BigInt(0) ? message.proposedAt?.toString() : undefined;
|
|
180
|
+
obj.proposal_extended = message.proposalExtended === false ? undefined : message.proposalExtended;
|
|
181
|
+
obj.proposal_fire_at = message.proposalFireAt !== BigInt(0) ? message.proposalFireAt?.toString() : undefined;
|
|
158
182
|
if (message.pinnedReplyIds) {
|
|
159
183
|
obj.pinned_reply_ids = message.pinnedReplyIds.map(e => e.toString());
|
|
160
184
|
}
|
|
@@ -17,6 +17,12 @@ export interface ThreadMoveRecord {
|
|
|
17
17
|
moveReason: string;
|
|
18
18
|
appealPending: boolean;
|
|
19
19
|
initiativeId: bigint;
|
|
20
|
+
/**
|
|
21
|
+
* committed_amount is the sentinel bond (udream, as a string) reserved at move
|
|
22
|
+
* time. Released on an upheld appeal; the slash basis on an overturn. Empty
|
|
23
|
+
* for governance-authority moves (no bond).
|
|
24
|
+
*/
|
|
25
|
+
committedAmount: string;
|
|
20
26
|
}
|
|
21
27
|
export interface ThreadMoveRecordProtoMsg {
|
|
22
28
|
typeUrl: "/sparkdream.forum.v1.ThreadMoveRecord";
|
|
@@ -39,6 +45,12 @@ export interface ThreadMoveRecordAmino {
|
|
|
39
45
|
move_reason?: string;
|
|
40
46
|
appeal_pending?: boolean;
|
|
41
47
|
initiative_id?: string;
|
|
48
|
+
/**
|
|
49
|
+
* committed_amount is the sentinel bond (udream, as a string) reserved at move
|
|
50
|
+
* time. Released on an upheld appeal; the slash basis on an overturn. Empty
|
|
51
|
+
* for governance-authority moves (no bond).
|
|
52
|
+
*/
|
|
53
|
+
committed_amount?: string;
|
|
42
54
|
}
|
|
43
55
|
export interface ThreadMoveRecordAminoMsg {
|
|
44
56
|
type: "/sparkdream.forum.v1.ThreadMoveRecord";
|
|
@@ -14,7 +14,8 @@ function createBaseThreadMoveRecord() {
|
|
|
14
14
|
sentinelBackingSnapshot: "",
|
|
15
15
|
moveReason: "",
|
|
16
16
|
appealPending: false,
|
|
17
|
-
initiativeId: BigInt(0)
|
|
17
|
+
initiativeId: BigInt(0),
|
|
18
|
+
committedAmount: ""
|
|
18
19
|
};
|
|
19
20
|
}
|
|
20
21
|
/**
|
|
@@ -56,6 +57,9 @@ exports.ThreadMoveRecord = {
|
|
|
56
57
|
if (message.initiativeId !== BigInt(0)) {
|
|
57
58
|
writer.uint32(80).uint64(message.initiativeId);
|
|
58
59
|
}
|
|
60
|
+
if (message.committedAmount !== "") {
|
|
61
|
+
writer.uint32(90).string(message.committedAmount);
|
|
62
|
+
}
|
|
59
63
|
return writer;
|
|
60
64
|
},
|
|
61
65
|
decode(input, length) {
|
|
@@ -95,6 +99,9 @@ exports.ThreadMoveRecord = {
|
|
|
95
99
|
case 10:
|
|
96
100
|
message.initiativeId = reader.uint64();
|
|
97
101
|
break;
|
|
102
|
+
case 11:
|
|
103
|
+
message.committedAmount = reader.string();
|
|
104
|
+
break;
|
|
98
105
|
default:
|
|
99
106
|
reader.skipType(tag & 7);
|
|
100
107
|
break;
|
|
@@ -114,6 +121,7 @@ exports.ThreadMoveRecord = {
|
|
|
114
121
|
message.moveReason = object.moveReason ?? "";
|
|
115
122
|
message.appealPending = object.appealPending ?? false;
|
|
116
123
|
message.initiativeId = object.initiativeId !== undefined && object.initiativeId !== null ? BigInt(object.initiativeId.toString()) : BigInt(0);
|
|
124
|
+
message.committedAmount = object.committedAmount ?? "";
|
|
117
125
|
return message;
|
|
118
126
|
},
|
|
119
127
|
fromAmino(object) {
|
|
@@ -148,6 +156,9 @@ exports.ThreadMoveRecord = {
|
|
|
148
156
|
if (object.initiative_id !== undefined && object.initiative_id !== null) {
|
|
149
157
|
message.initiativeId = BigInt(object.initiative_id);
|
|
150
158
|
}
|
|
159
|
+
if (object.committed_amount !== undefined && object.committed_amount !== null) {
|
|
160
|
+
message.committedAmount = object.committed_amount;
|
|
161
|
+
}
|
|
151
162
|
return message;
|
|
152
163
|
},
|
|
153
164
|
toAmino(message) {
|
|
@@ -162,6 +173,7 @@ exports.ThreadMoveRecord = {
|
|
|
162
173
|
obj.move_reason = message.moveReason === "" ? undefined : message.moveReason;
|
|
163
174
|
obj.appeal_pending = message.appealPending === false ? undefined : message.appealPending;
|
|
164
175
|
obj.initiative_id = message.initiativeId !== BigInt(0) ? message.initiativeId?.toString() : undefined;
|
|
176
|
+
obj.committed_amount = message.committedAmount === "" ? undefined : message.committedAmount;
|
|
165
177
|
return obj;
|
|
166
178
|
},
|
|
167
179
|
fromAminoMsg(object) {
|
|
@@ -110,6 +110,12 @@ export interface PinnedReplyRecord {
|
|
|
110
110
|
isSentinelPin: boolean;
|
|
111
111
|
disputed: boolean;
|
|
112
112
|
initiativeId: bigint;
|
|
113
|
+
/**
|
|
114
|
+
* committed_amount is the sentinel bond (in udream, as a string) reserved at
|
|
115
|
+
* pin time, released on an upheld dispute and available to slash on an
|
|
116
|
+
* overturn. Empty for governance-authority pins (no bond reserved).
|
|
117
|
+
*/
|
|
118
|
+
committedAmount: string;
|
|
113
119
|
}
|
|
114
120
|
export interface PinnedReplyRecordProtoMsg {
|
|
115
121
|
typeUrl: "/sparkdream.forum.v1.PinnedReplyRecord";
|
|
@@ -128,6 +134,12 @@ export interface PinnedReplyRecordAmino {
|
|
|
128
134
|
is_sentinel_pin?: boolean;
|
|
129
135
|
disputed?: boolean;
|
|
130
136
|
initiative_id?: string;
|
|
137
|
+
/**
|
|
138
|
+
* committed_amount is the sentinel bond (in udream, as a string) reserved at
|
|
139
|
+
* pin time, released on an upheld dispute and available to slash on an
|
|
140
|
+
* overturn. Empty for governance-authority pins (no bond reserved).
|
|
141
|
+
*/
|
|
142
|
+
committed_amount?: string;
|
|
131
143
|
}
|
|
132
144
|
export interface PinnedReplyRecordAminoMsg {
|
|
133
145
|
type: "/sparkdream.forum.v1.PinnedReplyRecord";
|
|
@@ -430,7 +430,8 @@ function createBasePinnedReplyRecord() {
|
|
|
430
430
|
pinnedAt: BigInt(0),
|
|
431
431
|
isSentinelPin: false,
|
|
432
432
|
disputed: false,
|
|
433
|
-
initiativeId: BigInt(0)
|
|
433
|
+
initiativeId: BigInt(0),
|
|
434
|
+
committedAmount: ""
|
|
434
435
|
};
|
|
435
436
|
}
|
|
436
437
|
/**
|
|
@@ -460,6 +461,9 @@ exports.PinnedReplyRecord = {
|
|
|
460
461
|
if (message.initiativeId !== BigInt(0)) {
|
|
461
462
|
writer.uint32(48).uint64(message.initiativeId);
|
|
462
463
|
}
|
|
464
|
+
if (message.committedAmount !== "") {
|
|
465
|
+
writer.uint32(58).string(message.committedAmount);
|
|
466
|
+
}
|
|
463
467
|
return writer;
|
|
464
468
|
},
|
|
465
469
|
decode(input, length) {
|
|
@@ -487,6 +491,9 @@ exports.PinnedReplyRecord = {
|
|
|
487
491
|
case 6:
|
|
488
492
|
message.initiativeId = reader.uint64();
|
|
489
493
|
break;
|
|
494
|
+
case 7:
|
|
495
|
+
message.committedAmount = reader.string();
|
|
496
|
+
break;
|
|
490
497
|
default:
|
|
491
498
|
reader.skipType(tag & 7);
|
|
492
499
|
break;
|
|
@@ -502,6 +509,7 @@ exports.PinnedReplyRecord = {
|
|
|
502
509
|
message.isSentinelPin = object.isSentinelPin ?? false;
|
|
503
510
|
message.disputed = object.disputed ?? false;
|
|
504
511
|
message.initiativeId = object.initiativeId !== undefined && object.initiativeId !== null ? BigInt(object.initiativeId.toString()) : BigInt(0);
|
|
512
|
+
message.committedAmount = object.committedAmount ?? "";
|
|
505
513
|
return message;
|
|
506
514
|
},
|
|
507
515
|
fromAmino(object) {
|
|
@@ -524,6 +532,9 @@ exports.PinnedReplyRecord = {
|
|
|
524
532
|
if (object.initiative_id !== undefined && object.initiative_id !== null) {
|
|
525
533
|
message.initiativeId = BigInt(object.initiative_id);
|
|
526
534
|
}
|
|
535
|
+
if (object.committed_amount !== undefined && object.committed_amount !== null) {
|
|
536
|
+
message.committedAmount = object.committed_amount;
|
|
537
|
+
}
|
|
527
538
|
return message;
|
|
528
539
|
},
|
|
529
540
|
toAmino(message) {
|
|
@@ -534,6 +545,7 @@ exports.PinnedReplyRecord = {
|
|
|
534
545
|
obj.is_sentinel_pin = message.isSentinelPin === false ? undefined : message.isSentinelPin;
|
|
535
546
|
obj.disputed = message.disputed === false ? undefined : message.disputed;
|
|
536
547
|
obj.initiative_id = message.initiativeId !== BigInt(0) ? message.initiativeId?.toString() : undefined;
|
|
548
|
+
obj.committed_amount = message.committedAmount === "" ? undefined : message.committedAmount;
|
|
537
549
|
return obj;
|
|
538
550
|
},
|
|
539
551
|
fromAminoMsg(object) {
|
|
@@ -8,6 +8,8 @@ export declare enum GovActionType {
|
|
|
8
8
|
GOV_ACTION_TYPE_FORUM_PAUSE = 5,
|
|
9
9
|
GOV_ACTION_TYPE_THREAD_LOCK = 6,
|
|
10
10
|
GOV_ACTION_TYPE_THREAD_MOVE = 7,
|
|
11
|
+
GOV_ACTION_TYPE_REPLY_PIN = 8,
|
|
12
|
+
GOV_ACTION_TYPE_POST_HIDE = 9,
|
|
11
13
|
UNRECOGNIZED = -1
|
|
12
14
|
}
|
|
13
15
|
export declare const GovActionTypeAmino: typeof GovActionType;
|
|
@@ -19,6 +19,8 @@ var GovActionType;
|
|
|
19
19
|
GovActionType[GovActionType["GOV_ACTION_TYPE_FORUM_PAUSE"] = 5] = "GOV_ACTION_TYPE_FORUM_PAUSE";
|
|
20
20
|
GovActionType[GovActionType["GOV_ACTION_TYPE_THREAD_LOCK"] = 6] = "GOV_ACTION_TYPE_THREAD_LOCK";
|
|
21
21
|
GovActionType[GovActionType["GOV_ACTION_TYPE_THREAD_MOVE"] = 7] = "GOV_ACTION_TYPE_THREAD_MOVE";
|
|
22
|
+
GovActionType[GovActionType["GOV_ACTION_TYPE_REPLY_PIN"] = 8] = "GOV_ACTION_TYPE_REPLY_PIN";
|
|
23
|
+
GovActionType[GovActionType["GOV_ACTION_TYPE_POST_HIDE"] = 9] = "GOV_ACTION_TYPE_POST_HIDE";
|
|
22
24
|
GovActionType[GovActionType["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
23
25
|
})(GovActionType || (exports.GovActionType = GovActionType = {}));
|
|
24
26
|
exports.GovActionTypeAmino = GovActionType;
|
|
@@ -48,6 +50,12 @@ function govActionTypeFromJSON(object) {
|
|
|
48
50
|
case 7:
|
|
49
51
|
case "GOV_ACTION_TYPE_THREAD_MOVE":
|
|
50
52
|
return GovActionType.GOV_ACTION_TYPE_THREAD_MOVE;
|
|
53
|
+
case 8:
|
|
54
|
+
case "GOV_ACTION_TYPE_REPLY_PIN":
|
|
55
|
+
return GovActionType.GOV_ACTION_TYPE_REPLY_PIN;
|
|
56
|
+
case 9:
|
|
57
|
+
case "GOV_ACTION_TYPE_POST_HIDE":
|
|
58
|
+
return GovActionType.GOV_ACTION_TYPE_POST_HIDE;
|
|
51
59
|
case -1:
|
|
52
60
|
case "UNRECOGNIZED":
|
|
53
61
|
default:
|
|
@@ -72,6 +80,10 @@ function govActionTypeToJSON(object) {
|
|
|
72
80
|
return "GOV_ACTION_TYPE_THREAD_LOCK";
|
|
73
81
|
case GovActionType.GOV_ACTION_TYPE_THREAD_MOVE:
|
|
74
82
|
return "GOV_ACTION_TYPE_THREAD_MOVE";
|
|
83
|
+
case GovActionType.GOV_ACTION_TYPE_REPLY_PIN:
|
|
84
|
+
return "GOV_ACTION_TYPE_REPLY_PIN";
|
|
85
|
+
case GovActionType.GOV_ACTION_TYPE_POST_HIDE:
|
|
86
|
+
return "GOV_ACTION_TYPE_POST_HIDE";
|
|
75
87
|
case GovActionType.UNRECOGNIZED:
|
|
76
88
|
default:
|
|
77
89
|
return "UNRECOGNIZED";
|
|
@@ -335,6 +335,13 @@ export interface Params {
|
|
|
335
335
|
* Minimum appeal rate (appeals / actions) to qualify for a reward (default 0.05).
|
|
336
336
|
*/
|
|
337
337
|
minAppealRate: string;
|
|
338
|
+
/**
|
|
339
|
+
* Rolling window (in reward epochs) over which sentinel reward accuracy is
|
|
340
|
+
* measured. Recent overturns move the ratio; inactivity ages a sentinel out.
|
|
341
|
+
* Bounded 1 <= W <= MaxSentinelAccuracyWindowEpochs (== the forum
|
|
342
|
+
* SentinelAccuracyRingSize). Default 6.
|
|
343
|
+
*/
|
|
344
|
+
sentinelAccuracyWindowEpochs: bigint;
|
|
338
345
|
/**
|
|
339
346
|
* Per-member active work caps (anti-monopolization). 0 = unbounded.
|
|
340
347
|
*/
|
|
@@ -618,6 +625,13 @@ export interface ParamsAmino {
|
|
|
618
625
|
* Minimum appeal rate (appeals / actions) to qualify for a reward (default 0.05).
|
|
619
626
|
*/
|
|
620
627
|
min_appeal_rate?: string;
|
|
628
|
+
/**
|
|
629
|
+
* Rolling window (in reward epochs) over which sentinel reward accuracy is
|
|
630
|
+
* measured. Recent overturns move the ratio; inactivity ages a sentinel out.
|
|
631
|
+
* Bounded 1 <= W <= MaxSentinelAccuracyWindowEpochs (== the forum
|
|
632
|
+
* SentinelAccuracyRingSize). Default 6.
|
|
633
|
+
*/
|
|
634
|
+
sentinel_accuracy_window_epochs?: string;
|
|
621
635
|
/**
|
|
622
636
|
* Per-member active work caps (anti-monopolization). 0 = unbounded.
|
|
623
637
|
*/
|
|
@@ -830,6 +844,11 @@ export interface RepOperationalParams {
|
|
|
830
844
|
* Minimum appeal rate (appeals / actions) to qualify for a reward (default 0.05).
|
|
831
845
|
*/
|
|
832
846
|
minAppealRate: string;
|
|
847
|
+
/**
|
|
848
|
+
* Rolling window (in reward epochs) for sentinel reward accuracy (mirrors
|
|
849
|
+
* Params.sentinel_accuracy_window_epochs). Default 6.
|
|
850
|
+
*/
|
|
851
|
+
sentinelAccuracyWindowEpochs: bigint;
|
|
833
852
|
/**
|
|
834
853
|
* Per-member active work caps (mirrors Params.max_active_{initiatives,interims}_per_member). 0 = unbounded.
|
|
835
854
|
*/
|
|
@@ -1025,6 +1044,11 @@ export interface RepOperationalParamsAmino {
|
|
|
1025
1044
|
* Minimum appeal rate (appeals / actions) to qualify for a reward (default 0.05).
|
|
1026
1045
|
*/
|
|
1027
1046
|
min_appeal_rate?: string;
|
|
1047
|
+
/**
|
|
1048
|
+
* Rolling window (in reward epochs) for sentinel reward accuracy (mirrors
|
|
1049
|
+
* Params.sentinel_accuracy_window_epochs). Default 6.
|
|
1050
|
+
*/
|
|
1051
|
+
sentinel_accuracy_window_epochs?: string;
|
|
1028
1052
|
/**
|
|
1029
1053
|
* Per-member active work caps (mirrors Params.max_active_{initiatives,interims}_per_member). 0 = unbounded.
|
|
1030
1054
|
*/
|