There is a race condition in the network transaction builder's startup.
The ntxb subscribes to mempool events which might be at block N. It then fetches the chain tip from the store, lets call it N'. N' != N if a block was committed after the subscription, but before the store call.
The result is a panic since the next block committed event will conflict with the chain_tip from the store.
Some solutions.
Process mempool events until we arrive at N', and only then proceed with proper startup.
Alternatively, wait until the first block committed event and use that to fetch the chain MMR from the store.
There is a race condition in the network transaction builder's startup.
The ntxb subscribes to mempool events which might be at block
N. It then fetches the chain tip from the store, lets call itN'.N' != Nif a block was committed after the subscription, but before the store call.The result is a panic since the next block committed event will conflict with the
chain_tipfrom the store.Some solutions.
Process mempool events until we arrive at
N', and only then proceed with proper startup.Alternatively, wait until the first block committed event and use that to fetch the chain MMR from the store.