Skip to content

Commit

Permalink
Revert to single validator info fetch. Some clippy fixes.
Browse files Browse the repository at this point in the history
  • Loading branch information
kukabi committed Mar 6, 2025
1 parent 3c9efde commit e1bc637
Show file tree
Hide file tree
Showing 39 changed files with 100 additions and 73 deletions.
56 changes: 28 additions & 28 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion _docker/compose/.env.sample
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
VERSION=0.22.4
VERSION=0.22.5
ENV=production
LOG_LEVEL=debug

Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1 @@
ALTER TABLE sub_extrinsic_payout_stakers ADD COLUMN IF NOT EXISTS page_index INTEGER;
ALTER TABLE sub_extrinsic_payout_stakers ADD COLUMN IF NOT EXISTS page_index INTEGER;
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
{{ validator_display }}
⬇️ lost a nomination{% if notification_period_type %} in the last {% if notification_period > 1 %}{{ notification_period }} {% endif %}{{ notification_period_type }}{% if notification_period > 1 %}s{% endif %}{% endif %}.
Nominator: {{ nominator_display }}{% if is_onekv %} (1KV){% endif %}
Nominator: {{ nominator_display }}{% if is_onekv %} (DN){% endif %}
Amount: {{ nomination_amount }} {{ token_ticker }}
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{{ validator_display }}
⭐️ received a new nomination{% if notification_period_type %} in the last {% if notification_period > 1 %}{{ notification_period }} {% endif %}{{ notification_period_type }}{% if notification_period > 1 %}s{% endif %}{% endif %}!
Nominator: {{ nominator_display }}{% if is_onekv %} (1KV){% endif %}
Nominator: {{ nominator_display }}{% if is_onekv %} (DN){% endif %}
Amount: {{ nomination_amount }} {{ token_ticker }}
Nominee Count: {{ nominee_count }}
2 changes: 1 addition & 1 deletion _template/telegram/chain_validator_lost_nomination.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<strong>{{ validator_display }}</strong>
⬇️ lost a nomination{% if notification_period_type %} in the last {% if notification_period > 1 %}{{ notification_period }} {% endif %}{{ notification_period_type }}{% if notification_period > 1 %}s{% endif %}{% endif %}.
Nominator: <a href="https://{{ chain }}.subscan.io/account/{{ nominator_address }}">{{ nominator_display }}</a>{% if is_onekv %} (1KV){% endif %}
Nominator: <a href="https://{{ chain }}.subscan.io/account/{{ nominator_address }}">{{ nominator_display }}</a>{% if is_onekv %} (DN){% endif %}
Amount: <strong>{{ nomination_amount }} {{ token_ticker }}</strong>
2 changes: 1 addition & 1 deletion _template/telegram/chain_validator_new_nomination.html
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<strong>{{ validator_display }}</strong>
⭐️ received a new nomination{% if notification_period_type %} in the last {% if notification_period > 1 %}{{ notification_period }} {% endif %}{{ notification_period_type }}{% if notification_period > 1 %}s{% endif %}{% endif %}!
Nominator: <a href="https://{{ chain }}.subscan.io/account/{{ nominator_address }}">{{ nominator_display }}</a>{% if is_onekv %} (1KV){% endif %}
Nominator: <a href="https://{{ chain }}.subscan.io/account/{{ nominator_address }}">{{ nominator_display }}</a>{% if is_onekv %} (DN){% endif %}
Amount: <strong>{{ nomination_amount }} {{ token_ticker }}</strong>
Nominee Count: <strong>{{ nominee_count }}</strong>
2 changes: 1 addition & 1 deletion subvt-app-service/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "subvt-app-service"
version = "0.22.4"
version = "0.22.5"
edition = "2021"
rust-version = "1.67.0"

Expand Down
2 changes: 1 addition & 1 deletion subvt-block-processor/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "subvt-block-processor"
version = "0.22.4"
version = "0.22.5"
edition = "2021"
rust-version = "1.67.0"

Expand Down
2 changes: 1 addition & 1 deletion subvt-config/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "subvt-config"
version = "0.22.4"
version = "0.22.5"
edition = "2021"
rust-version = "1.67.0"

Expand Down
2 changes: 1 addition & 1 deletion subvt-governance/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "subvt-governance"
version = "0.22.4"
version = "0.22.5"
edition = "2021"
rust-version = "1.67.0"

Expand Down
2 changes: 1 addition & 1 deletion subvt-kline-updater/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "subvt-kline-updater"
version = "0.22.4"
version = "0.22.5"
edition = "2021"
rust-version = "1.67.0"

Expand Down
2 changes: 1 addition & 1 deletion subvt-logging/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "subvt-logging"
version = "0.22.4"
version = "0.22.5"
edition = "2021"
rust-version = "1.67.0"

Expand Down
2 changes: 1 addition & 1 deletion subvt-metrics/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "subvt-metrics"
version = "0.22.4"
version = "0.22.5"
edition = "2021"
rust-version = "1.67.0"

Expand Down
2 changes: 1 addition & 1 deletion subvt-network-status-server/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "subvt-network-status-server"
version = "0.22.4"
version = "0.22.5"
edition = "2021"
rust-version = "1.67.0"

Expand Down
2 changes: 1 addition & 1 deletion subvt-network-status-updater/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "subvt-network-status-updater"
version = "0.22.4"
version = "0.22.5"
edition = "2021"
rust-version = "1.67.0"

Expand Down
2 changes: 1 addition & 1 deletion subvt-nft/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "subvt-nft"
version = "0.22.4"
version = "0.22.5"
edition = "2021"
rust-version = "1.67.0"

Expand Down
2 changes: 1 addition & 1 deletion subvt-notification-generator/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "subvt-notification-generator"
version = "0.22.4"
version = "0.22.5"
edition = "2021"
rust-version = "1.67.0"

Expand Down
6 changes: 1 addition & 5 deletions subvt-notification-generator/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -96,11 +96,7 @@ impl NotificationGenerator {
sent_at: None,
delivered_at: None,
read_at: None,
data_json: if let Ok(data_json) = serde_json::to_string(&notification_data) {
Some(data_json)
} else {
None
},
data_json: serde_json::to_string(&notification_data).ok(),
};
let _ = app_postgres.save_notification(&notification).await?;
metrics::notification_counter(
Expand Down
Loading

0 comments on commit e1bc637

Please sign in to comment.