You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We need the block time when a tx is confirmed.
The code in Transaction.setBlockAppearance does not set the updatedAt if it was set before.
As Wallet.commit sets the updatedAt the update never happes.
I am not familiar enough with BitcoinJ to feel comfortable to make a PR. My assumptions are described in the comments but would be great if you could have a look to it to make sure it covers the re-org cases correctly.
Here is what I changed in our fork.
// We removed for the checks to not overwrite updatedAt in cases for re-orgs.
// updatedAt is set by wallet.commit and thus the new block would never set the value.
// If there is a re-org the best block is called last as stated in the doc above so the values will be correct.
if (bestChain) {
updatedAt = new Date(blockTime);
}
Here is the current version:
if (bestChain && (updatedAt == null || updatedAt.getTime() == 0 || updatedAt.getTime() > blockTime)) {
updatedAt = new Date(blockTime);
}
We need the block time when a tx is confirmed.
The code in Transaction.setBlockAppearance does not set the updatedAt if it was set before.
As Wallet.commit sets the updatedAt the update never happes.
See: https://groups.google.com/d/msg/bitcoinj/05TJbxAwKXs/D6CYV1byAgAJ
See also: bisq-network#11
The text was updated successfully, but these errors were encountered: