Skip to content

Remove ForkName from witness #208

Description

@roynalnaruto

After #164 is merged, we will no longer require fork_name: ForkName in the witness. Instead, the hardfork can be derived from the version byte, which is available in the witness.

This also means that the implementation of From<Witness> for LegacyWitness will change slightly:

impl From<ChunkWitness> for LegacyChunkWitness {
    fn from(value: ChunkWitness) -> Self {
        let version = Version::from(value.version);
        Self {
            /* ... */
            fork_name: version.fork,
            /* ... */
        }
    }
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions