Skip to content

Commit 42f4432

Browse files
authored
Merge pull request #1608 from input-output-hk/jpraynaud/1577-fix-transaction-parsing-conway
Fix Conway transactions parsing
2 parents 733d002 + 42b42e3 commit 42f4432

File tree

7 files changed

+29
-29
lines changed

7 files changed

+29
-29
lines changed

Cargo.lock

Lines changed: 15 additions & 15 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

mithril-aggregator/src/dependency_injection/builder.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -741,8 +741,8 @@ impl DependenciesBuilder {
741741
}
742742

743743
async fn build_transaction_parser(&mut self) -> Result<Arc<dyn TransactionParser>> {
744-
// TODO: 'allow_unparsable_block' parameter should be configurable and its default value set to false
745-
let allow_unparsable_block = true;
744+
// TODO: 'allow_unparsable_block' parameter should be configurable
745+
let allow_unparsable_block = false;
746746
let transaction_parser =
747747
CardanoTransactionParser::new(self.get_logger().await?, allow_unparsable_block);
748748

mithril-common/Cargo.toml

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "mithril-common"
3-
version = "0.3.26"
3+
version = "0.3.27"
44
description = "Common types, interfaces, and utilities for Mithril nodes."
55
authors = { workspace = true }
66
edition = { workspace = true }
@@ -44,12 +44,12 @@ kes-summed-ed25519 = { version = "0.2.1", features = [
4444
"sk_clone_enabled",
4545
] }
4646
nom = "7.1.3"
47-
pallas-addresses = { version = "0.24.0", optional = true }
48-
pallas-codec = { version = "0.24.0", optional = true }
49-
pallas-hardano = { version = "0.24.0", optional = true }
50-
pallas-network = { version = "0.24.0", optional = true }
51-
pallas-primitives = { version = "0.24.0", optional = true }
52-
pallas-traverse = { version = "0.24.0", optional = true }
47+
pallas-addresses = { version = "0.25.0", optional = true }
48+
pallas-codec = { version = "0.25.0", optional = true }
49+
pallas-hardano = { version = "0.25.0", optional = true }
50+
pallas-network = { version = "0.25.0", optional = true }
51+
pallas-primitives = { version = "0.25.0", optional = true }
52+
pallas-traverse = { version = "0.25.0", optional = true }
5353
rand_chacha = "0.3.1"
5454
rand_core = "0.6.4"
5555
rayon = "1.8.1"
@@ -89,7 +89,7 @@ wasm-bindgen = "0.2.90"
8989
[dev-dependencies]
9090
criterion = { version = "0.5.1", features = ["html_reports", "async_tokio"] }
9191
mockall = "0.12.1"
92-
pallas-crypto = "0.24.0"
92+
pallas-crypto = "0.25.0"
9393
rand_core = { version = "0.6.4", features = ["getrandom"] }
9494
reqwest = { version = "0.12.0", features = ["json"] }
9595
slog-async = "2.8.0"

mithril-common/src/cardano_transaction_parser.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -326,7 +326,7 @@ mod tests {
326326
cardano_transaction_parser
327327
.parse(db_path, &beacon)
328328
.await
329-
.unwrap();
329+
.expect_err("parse should have failed");
330330
}
331331

332332
let log_file = std::fs::read_to_string(&filepath).unwrap();

mithril-signer/src/runtime/signer_services.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -266,8 +266,8 @@ impl<'a> ServiceBuilder for ProductionServiceBuilder<'a> {
266266
));
267267
let mithril_stake_distribution_signable_builder =
268268
Arc::new(MithrilStakeDistributionSignableBuilder::default());
269-
// TODO: 'allow_unparsable_block' parameter should be configurable and its default value set to false
270-
let allow_unparsable_block = true;
269+
// TODO: 'allow_unparsable_block' parameter should be configurable
270+
let allow_unparsable_block = false;
271271
let transaction_parser = Arc::new(CardanoTransactionParser::new(
272272
slog_scope::logger(),
273273
allow_unparsable_block,

mithril-test-lab/test_data/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,5 +7,5 @@
77
> [!NOTE]
88
> The immutable files (`.chunk`, `.primary` and `.secondary`) files are data that are the result of
99
> the `mithril-end-to-end` test command execution.
10-
> The `parsing_error/` directory contains the `04831` and `04832` immutable files with some unparsable blocks in the first one (`04831` have been produced by the Sanchonet network, and `04832` created manually).
10+
> The `parsing_error/` directory contains the `04831` and `04832` immutable files with some unparsable blocks in the first one (`04831` have been produced by the Sanchonet network and altered manually with the command `echo " $(cat immutable/04831.chunk)" > immutable/04831.chunk`, and `04832` created manually).
1111
> They are needed for testing of the Cardano transactions parser.
Binary file not shown.

0 commit comments

Comments
 (0)