Skip to content
This repository was archived by the owner on Mar 18, 2025. It is now read-only.

Commit 8a3cc83

Browse files
authored
Merge pull request #2614 from w3f/will-v3.0.20
v3.0.20
2 parents ce25b97 + 3341c41 commit 8a3cc83

File tree

12 files changed

+19
-17
lines changed

12 files changed

+19
-17
lines changed

apps/1kv-backend-staging/templates/kusama-otv-backend.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ spec:
1717
source:
1818
repoURL: https://w3f.github.io/helm-charts/
1919
chart: otv-backend
20-
targetRevision: v3.0.19
20+
targetRevision: v3.0.20
2121
plugin:
2222
env:
2323
- name: HELM_VALUES

apps/1kv-backend-staging/templates/polkadot-otv-backend.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ spec:
1717
source:
1818
repoURL: https://w3f.github.io/helm-charts/
1919
chart: otv-backend
20-
targetRevision: v3.0.19
20+
targetRevision: v3.0.20
2121
plugin:
2222
env:
2323
- name: HELM_VALUES

charts/otv-backend/Chart.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
description: 1K Validators Backend
22
name: otv-backend
3-
version: v3.0.19
4-
appVersion: v3.0.19
3+
version: v3.0.20
4+
appVersion: v3.0.20
55
apiVersion: v2

packages/common/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@1kv/common",
3-
"version": "3.0.19",
3+
"version": "3.0.20",
44
"description": "Services for running the Thousand Validator Program.",
55
"main": "build/index.js",
66
"types": "build/index.d.ts",

packages/common/src/db/queries/Nominator.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,8 @@ export const addNominator = async (nominator: Nominator): Promise<boolean> => {
6969
);
7070
} catch (e) {
7171
logger.info(JSON.stringify(e));
72+
logger.error(`Could not add nominator: ${e}`);
73+
logger.error(`Could not add nominator: ${JSON.stringify(nominator)}`);
7274
}
7375
};
7476

packages/core/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@1kv/core",
3-
"version": "3.0.19",
3+
"version": "3.0.20",
44
"description": "Services for running the Thousand Validator Program.",
55
"main": "index.js",
66
"scripts": {

packages/core/src/nominator.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ export default class Nominator {
9090
return this._proxyDelay;
9191
}
9292

93-
public async stash(): Promise<any> {
93+
public async stash(): Promise<string> {
9494
try {
9595
const api = this.handler.getApi();
9696
const ledger = await api.query.staking.ledger(this.bondedAddress);
@@ -100,7 +100,7 @@ export default class Nominator {
100100
}
101101
const { stash } = ledger.unwrap();
102102

103-
return stash;
103+
return stash.toString();
104104
} catch (e) {
105105
logger.error(
106106
`Error getting stash for ${this.bondedAddress}: ${e}`,
@@ -111,7 +111,7 @@ export default class Nominator {
111111
}
112112
}
113113

114-
public async payee(): Promise<any> {
114+
public async payee(): Promise<string> {
115115
const api = this.handler.getApi();
116116
try {
117117
const ledger = await api.query.staking.ledger(this.bondedAddress);

packages/core/src/scorekeeper/Round.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,12 +55,12 @@ export const endRound = async (
5555
// Gets adds candidates we nominated to the list
5656
for (const nomGroup of nominatorGroups) {
5757
for (const nominator of nomGroup) {
58-
const current = await queries.getCurrentTargets(nominator.controller);
58+
const current = await queries.getCurrentTargets(nominator.bondedAddress);
5959

6060
// If not nominating any... then return.
6161
if (!current.length) {
6262
logger.info(
63-
`${nominator.controller} is not nominating any targets.`,
63+
`${nominator.bondedAddress} is not nominating any targets.`,
6464
scorekeeperLabel,
6565
);
6666
continue;

packages/core/src/scorekeeper/scorekeeper.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ export default class ScoreKeeper {
109109
address: nom.bondedAddress,
110110
stash: stash,
111111
proxy: proxy,
112-
bonded: bonded,
112+
bonded: Number(bonded),
113113
now: now,
114114
proxyDelay: proxyDelay,
115115
rewardDestination: payee,
@@ -138,7 +138,7 @@ export default class ScoreKeeper {
138138
group.map(async (n) => {
139139
const stash = await n.stash();
140140
const proxy = (await n._isProxy) ? `/ ${n.address}` : "";
141-
return `- ${n.controller} / ${stash} ${proxy}`;
141+
return `- ${n.bondedAddress} / ${stash} ${proxy}`;
142142
}),
143143
)
144144
).join("\n");
@@ -163,7 +163,7 @@ export default class ScoreKeeper {
163163
)
164164
).join("<br>");
165165
logger.info(
166-
`Nominator group added! Nominator addresses (Controller / Stash / Proxy):\n${nominatorGroupString}`,
166+
`Nominator group added! Nominator addresses (Bonded Address / Stash / Proxy):\n${nominatorGroupString}`,
167167
scorekeeperLabel,
168168
);
169169

packages/gateway/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@1kv/gateway",
3-
"version": "3.0.19",
3+
"version": "3.0.20",
44
"description": "Services for running the Thousand Validator Program.",
55
"main": "build/index.js",
66
"types": "build/index.d.ts",

0 commit comments

Comments
 (0)