bitcoindevkit / rust-electrum-client

Bitcoin Electrum client library. Supports plaintext, TLS and Onion servers.
MIT License
72 stars 54 forks source link

`ScriptStatus` should be also `Serializable` #98

Closed RCasatta closed 1 year ago

RCasatta commented 1 year ago

Implementors should persist the ScriptStatus to compare for changes between runs

RCasatta commented 1 year ago

Not necessarily, I now think it's better to recompute the status from the transactions in the cache

RCasatta commented 1 year ago

Thinking again, it makes sense to Serialize ScriptStatus otherwise the cache should also store the order of received transactions (you can order txs if they are at different height, but if they are in the same block you can't in edge cases...) but it's more convenient to simply cache the ScriptStatus