lndg icon indicating copy to clipboard operation
lndg copied to clipboard

add time_stamp to closures model

Open nullcount opened this issue 2 years ago • 3 comments

the closures model currently only has a block height in which the closing transaction was confirmed. It should also include the timestamp of the mined block. Onchain txs model includes a timestamp so this model should as well.

It would greatly simplify my usecase. Today, I have to query the node for the timestamp of the block for every closure.

nullcount avatar Dec 12 '22 18:12 nullcount

We may be able to attempt to get the timestamp from API data and have it populate if the API is working (similar to close fees). Unfortunately LND is not passing the timestamp back so we are unable to get it directly from the node.

cryptosharks131 avatar Dec 12 '22 21:12 cryptosharks131

My thought was to cross reference with the timestamp from onchain api, but only some channel closures have a corresponding onchain event. I thought every channel closure would have an onchain event. Why is that?

nullcount avatar Dec 12 '22 23:12 nullcount

I believe only the channels you open yourself will show a tx in the LND onchain events.

cryptosharks131 avatar Dec 13 '22 01:12 cryptosharks131