HathorNetwork / hathor-core

Hathor core is the official and reference client for operating a full node in Hathor Network.
https://hathor.network
Apache License 2.0
83 stars 26 forks source link

Refactor `NodeBlockSync` and `SyncMempoolManager` for better dependency injection #1099

Open jansegre opened 3 months ago

jansegre commented 3 months ago
          Should we have this as an `__init__()` dependency instead of manually instantiating it here? It would be easier for unit testing

_Originally posted by @glevco in https://github.com/HathorNetwork/hathor-core/pull/275#discussion_r1271115879_

jansegre commented 1 month ago

Still applies, SyncMempoolManager in the sync-v2 agent, could be externally instantiated and passed down when instantiating a NodeBlockSync.