dgarage / NBXplorer

NBitcoin Explorer
MIT License
320 stars 210 forks source link

Broken tracking #477

Open gus4rs opened 2 weeks ago

gus4rs commented 2 weeks ago

Added a xpub tracking, matching Derivation scheme in BTCPayServer

curl -XPOST  -v "http://127.0.0.1:24444/v1/cryptos/btc/derivations/xpub[...]"            
< HTTP/1.1 200 OK
< Content-Length: 0
< Date: Sun, 01 Sep 2024 12:26:40
< Server: Kestrel

Rescan:

 curl -v "http://127.0.0.1:24444/v1/cryptos/btc/derivations/xpub[...]/utxos/scan"
< HTTP/1.1 200 OK
< Content-Type: application/json; charset=utf-8
< Date: Sun, 01 Sep 2024 12:31:07
< Server: Kestrel
< Transfer-Encoding: chunked

Get transactions:

 curl -v "http://127.0.0.1:24444/v1/cryptos/btc/derivations/xpub[...]/transactions" 
{
  "height": 859374,
  "confirmedTransactions": {
    "transactions": [ CORRECT] 
  "unconfirmedTransactions": {
    "transactions": []
  },
  "immatureTransactions": {
    "transactions": []
  },
  "replacedTransactions": {
    "transactions": []
  }
}

It correctly detected confirmed transactions, but failed to detect unconfirmedTransactions, there is one transaction sitting in the mempool that was ignored by NBXplorer

gus4rs commented 2 weeks ago

It is not related to the gap either. The wallet had balance at address ../0/0 and the unconfirmed transaction spends it to ../0/9, ../0/10, ../0/11 and ../0/12

Also, node is whitelisted in Bitcoin core