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

Commit b35b21b

Browse files
authored
Merge pull request #2594 from w3f/will-v3.0.15
v3.0.15
2 parents c5e2aeb + 11ff0f6 commit b35b21b

File tree

11 files changed

+36
-19
lines changed

11 files changed

+36
-19
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.14
20+
targetRevision: v3.0.15
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.14
20+
targetRevision: v3.0.15
2121
plugin:
2222
env:
2323
- name: HELM_VALUES

apps/1kv-backend/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.14
20+
targetRevision: v3.0.15
2121
plugin:
2222
env:
2323
- name: HELM_VALUES

apps/1kv-backend/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.14
20+
targetRevision: v3.0.15
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.14
4-
appVersion: v3.0.14
3+
version: v3.0.15
4+
appVersion: v3.0.15
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.14",
3+
"version": "3.0.15",
44
"description": "Services for running the Thousand Validator Program.",
55
"main": "build/index.js",
66
"types": "build/index.d.ts",

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.14",
3+
"version": "3.0.15",
44
"description": "Services for running the Thousand Validator Program.",
55
"main": "index.js",
66
"scripts": {

packages/core/src/nominator.ts

Lines changed: 25 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -95,15 +95,21 @@ export default class Nominator {
9595
}
9696

9797
public async stash(): Promise<any> {
98-
const api = this.handler.getApi();
99-
const ledger = await api.query.staking.ledger(this.controller);
100-
if (!ledger.isSome) {
101-
logger.warn(`Account ${this.controller} is not a controller account!`);
102-
return "0x";
103-
}
104-
const { stash } = ledger.unwrap();
98+
try {
99+
const api = this.handler.getApi();
100+
const ledger = await api.query.staking.ledger(this.controller);
101+
if (!ledger.isSome) {
102+
logger.warn(`Account ${this.controller} is not bonded!`);
103+
return "0x";
104+
}
105+
const { stash } = ledger.unwrap();
105106

106-
return stash;
107+
return stash;
108+
} catch (e) {
109+
logger.error(`Error getting stash for ${this.controller}: ${e}`, label);
110+
logger.error(e, label);
111+
return this.controller;
112+
}
107113
}
108114

109115
public async payee(): Promise<any> {
@@ -156,6 +162,17 @@ export default class Nominator {
156162
} else {
157163
const api = this.handler.getApi();
158164

165+
try {
166+
const controller = await api.query.staking.bonded(this.controller);
167+
if (controller.isNone) {
168+
logger.warn(`Account ${this.controller} is not bonded!`);
169+
return false;
170+
}
171+
} catch (e) {
172+
logger.error(`Error checking if ${this.controller} is bonded: ${e}`);
173+
return false;
174+
}
175+
159176
let tx: SubmittableExtrinsic<"promise">;
160177

161178
// Start an announcement for a delayed proxy tx

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.14",
3+
"version": "3.0.15",
44
"description": "Services for running the Thousand Validator Program.",
55
"main": "build/index.js",
66
"types": "build/index.d.ts",

packages/telemetry/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@1kv/telemetry",
3-
"version": "3.0.14",
3+
"version": "3.0.15",
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)