[bisq-network/bisq] Improve handling of failed trades and offers (#3566)
chimp1984
notifications at github.com
Wed Nov 6 15:32:08 UTC 2019
chimp1984 commented on this pull request.
> - log.warn("We found a closed trade with locked up funds. " +
- "That should never happen. trade ID=" + e.getId());
- return e.getId();
+ tradesIdSet.addAll(closedTradableManager.getTradesStreamWithFundsLockedIn()
+ .map(trade -> {
+ Transaction depositTx = trade.getDepositTx();
+ if (depositTx != null) {
+ TransactionConfidence confidence = btcWalletService.getConfidenceForTxId(depositTx.getHashAsString());
+ if (confidence != null && confidence.getConfidenceType() != TransactionConfidence.ConfidenceType.BUILDING) {
+ tradeTxException.set(new TradeTxException(Res.get("error.closedTradeWithUnconfirmedDepositTx", trade.getShortId())));
+ } else {
+ log.warn("We found a closed trade with locked up funds. " +
+ "That should never happen. trade ID=" + trade.getId());
+ }
+ } else {
+ tradeTxException.set(new TradeTxException(Res.get("error.closedTradeWithNoDepositTx", trade.getShortId())));
Hm... Not sure. But after the pending trade has been moved to failed trade I think the tradesIdSet is correct again. All those cases are very hard to reproduce/test...
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/bisq-network/bisq/pull/3566#discussion_r343161594
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.bisq.network/pipermail/bisq-github/attachments/20191106/12cd533d/attachment.html>
More information about the bisq-github
mailing list