Description
The current implementation of Transaction.to_bytes() and Transaction.from_bytes() only properly serializes and restores a single node transaction, even when the transaction itself contains multiple node IDs internally.
As a result:
- Transactions frozen with multiple node IDs lose information after
to_bytes()
from_bytes() cannot correctly restore all node contexts
Proposed Solution
Additional Notes
Potential considerations for the implementation:
Description
The current implementation of
Transaction.to_bytes()andTransaction.from_bytes()only properly serializes and restores a single node transaction, even when the transaction itself contains multiple node IDs internally.As a result:
to_bytes()from_bytes()cannot correctly restore all node contextsProposed Solution
Transaction.to_bytes()to serialize each transactions for node_ids using the protobufTransactionListtype instead of serializing only a singleTransaction.Transaction.from_bytes()to parse theTransactionListand reconstruct all node-specific transaction bodies.Additional Notes
Potential considerations for the implementation: