Skip to content

zmigrate fails when discovering a transaction with an invalid consensus branch id #2

@nuttycom

Description

@nuttycom

I got the following error when attempting to dump a current testnet wallet:

λ cargo run --features zcashd -- zcashd ./wallet.dat.20250327 > testnet_wallet.txt
   Compiling pqcrypto-internals v0.2.10
   Compiling secp256k1-sys v0.10.1
   Compiling secp256k1 v0.30.0
   Compiling bc-crypto v0.6.0
   Compiling bc-shamir v0.5.0
   Compiling sskr v0.5.0
   Compiling pqcrypto-mlkem v0.1.0
   Compiling pqcrypto-mldsa v0.1.1
   Compiling bc-components v0.17.0
   Compiling bc-envelope v0.24.0
   Compiling zewif v0.1.0 (https://github.com/nuttycom/zewif?rev=61c988fbfb6c3e74c5b98ba3da1cbc521b3967bd#61c988fb)
   Compiling zewif-zcashd v0.1.0 (https://github.com/nuttycom/zewif-zcashd?rev=dc7825b03e413596fcf301d9918df24dc012c22c#dc7825b0)
   Compiling zmigrate v0.1.0 (/home/nuttycom/work/zmigrate)
    Finished `dev` profile [unoptimized + debuginfo] target(s) in 7.01s
     Running `target/debug/zmigrate zcashd ./wallet.dat.20250327`
[src/zcashd_cmd.rs:32:38] file = "./wallet.dat.20250327"
---
🔴 Error: Parsing Zcashd dump

Caused by: Parsing transaction
Caused by: Parsing consensus_branch_id
Caused by: Unknown consensus branch ID: 928093729

This can be avoided by using the consensus branch IDs from the zcash_protocol crate, or using the transaction parser from the zcash_primitives crate.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions