Skip to content

Fullnode RPC crashes if WriteTableItem has no data #13

@ownyrd

Description

@ownyrd

Code Reference

WriteSetChange::WriteTableItem(write_table_item) => {
let data = write_table_item.data.as_ref().unwrap_or_else(|| {
panic!(
"Could not extract data from DecodedTableData '{:?}'",
write_table_item
)
});

Issue

For a Block with only Block Metadata and State Checkpoint (like https://0l.fyi/blocks/10901184) the Fullnode gRPC Endpoint GetTransactionsFromNode works as expected. A User Transaction will most likely crash the gRPC Server because there are (i think always) write_table_item types with data = null (see e.g. https://0l.fyi/transactions/21825188). I am not sure but I think those write_table_items are not as relevant as write_resource elements. So maybe we can consider setting this write_table_item to optional or at least allow null values. Currently this Endpoint is imo not usable.

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