Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions Cargo.lock

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

Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "mithril-cardano-node-internal-database"
version = "0.1.6"
version = "0.1.7"
description = "Mechanisms that allow Mithril nodes to read the files of a Cardano node internal database and compute digests from them"
authors.workspace = true
documentation.workspace = true
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ pub(super) struct Progress {
impl Progress {
pub(super) fn report(&mut self, ix: usize) -> bool {
self.index = ix;
(20 * ix) % self.total == 0
(20 * ix).is_multiple_of(self.total)
}

pub(super) fn percent(&self) -> f64 {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ impl DummyCardanoDbBuilder {
/// Note: by default, the size of the produced files is less than 1 kb.
pub fn set_immutable_trio_file_size(&mut self, trio_file_size: u64) -> &mut Self {
assert!(
trio_file_size % 3 == 0,
trio_file_size.is_multiple_of(3),
"'trio_file_size' must be a multiple of 3"
);

Expand Down
2 changes: 1 addition & 1 deletion mithril-aggregator/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "mithril-aggregator"
version = "0.7.84"
version = "0.7.85"
description = "A Mithril Aggregator server"
authors = { workspace = true }
edition = { workspace = true }
Expand Down
8 changes: 4 additions & 4 deletions mithril-aggregator/src/database/record/signer_registration.rs
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,8 @@ impl From<SignerRegistrationRecord> for Signer {
verification_key: other.verification_key.try_into().unwrap(),
verification_key_signature: other
.verification_key_signature
.map(|k| (k.try_into().unwrap())),
operational_certificate: other.operational_certificate.map(|o| (o.try_into().unwrap())),
.map(|k| k.try_into().unwrap()),
operational_certificate: other.operational_certificate.map(|o| o.try_into().unwrap()),
kes_period: other.kes_period,
}
}
Expand All @@ -75,8 +75,8 @@ impl From<SignerRegistrationRecord> for SignerWithStake {
verification_key: other.verification_key.try_into().unwrap(),
verification_key_signature: other
.verification_key_signature
.map(|k| (k.try_into().unwrap())),
operational_certificate: other.operational_certificate.map(|o| (o.try_into().unwrap())),
.map(|k| k.try_into().unwrap()),
operational_certificate: other.operational_certificate.map(|o| o.try_into().unwrap()),
kes_period: other.kes_period,
stake: other.stake.unwrap_or_default(),
}
Expand Down
2 changes: 1 addition & 1 deletion mithril-aggregator/src/services/epoch_service.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1019,7 +1019,7 @@ mod tests {

let stake_store = {
assert!(
self.total_stake % self.total_spo as u64 == 0,
self.total_stake.is_multiple_of(self.total_spo as u64),
"'total_stake' must be a multiple of 'total_spo' to create a uniform stake distribution"
);
let stake_per_spo = self.total_stake / self.total_spo as u64;
Expand Down
2 changes: 1 addition & 1 deletion mithril-common/Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "mithril-common"
version = "0.6.17"
version = "0.6.18"
description = "Common types, interfaces, and utilities for Mithril nodes."
authors = { workspace = true }
edition = { workspace = true }
Expand Down
4 changes: 2 additions & 2 deletions mithril-common/src/messages/message_parts/signer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ impl From<SignerWithStake> for SignerWithStakeMessagePart {
.map(|k| k.try_into().unwrap()),
operational_certificate: value
.operational_certificate
.map(|op_cert| (op_cert.try_into().unwrap())),
.map(|op_cert| op_cert.try_into().unwrap()),
kes_period: value.kes_period,
stake: value.stake,
}
Expand Down Expand Up @@ -230,7 +230,7 @@ impl From<Signer> for SignerMessagePart {
.map(|k| k.try_into().unwrap()),
operational_certificate: value
.operational_certificate
.map(|op_cert| (op_cert.try_into().unwrap())),
.map(|op_cert| op_cert.try_into().unwrap()),
kes_period: value.kes_period,
}
}
Expand Down
Loading