Skip to content

CLN isn't tracking unilateral output correctly? #8347

@grubles

Description

@grubles

Now using v25.05rc1 but this has been happening since before that was tagged.

A relatively long-standing channel had errored with invalid revocation. Now the CLN node seems stuck waiting for an output to be confirmed. The problem is that output has some 12k confirms already.

 "state_changes": [                                                                                                                                                                                   
            {                                                                                                                                                                                                            
               "timestamp": "2024-07-27T00:55:10.767Z",                                                                                                                                                                  
               "old_state": "CHANNELD_AWAITING_LOCKIN",                                                                                                                                                                  
               "new_state": "CHANNELD_NORMAL",                                                                                                                                                                           
               "cause": "remote",                                                                                                                                                                                        
               "message": "Lockin complete"                                                                                                                                                                              
            },                                                                                                                                                                                                           
            {                                                                                                                                                                                                            
               "timestamp": "2025-03-21T21:18:08.717Z",                                                                                                                                                                  
               "old_state": "CHANNELD_NORMAL",                                                                                                                                                                           
               "new_state": "AWAITING_UNILATERAL",                                                                                                                                                                       
               "cause": "protocol",   
               "message": "channeld: received ERROR channel b7b3c2ac79c3f7643ad80c9b23635b1d59019c872906f0315d3b63e8f6078107: invalid revocation"
            },                                   

Ok the channel errored and it looks like CLN is trying to do a unilateral close.

  "status": [                                                                                        
            "ONCHAIN:Tracking our own unilateral close",                                                    
            "ONCHAIN:1 outputs unresolved: waiting confirmation that we spent DELAYED_OUTPUT_TO_US (onchaintxid:0) using OUR_DELAYED_RETURN_TO_WALLET"
         ],                 

The problem is the onchaintxid transaction has a ton of confs already and, strangely, CLN seems aware to some degree?

2025-06-11T17:56:03.286Z DEBUG   0364913d18a19c671bb36dd04d6ad5be0fe8f2894314c36a9db3f03c2d414907e1-onchaind-chan#14575: billboard: 1 outputs unresolved: waiting confirmation that we spent DELAYED_OUTPUT_TO_US (onchaintxid:0) using OUR_DELAYED_RETURN_TO_WALLET                                                                                                                         
2025-06-11T17:56:03.286Z DEBUG   0364913d18a19c671bb36dd04d6ad5be0fe8f2894314c36a9db3f03c2d414907e1-onchaind-chan#14575: Got new message WIRE_ONCHAIND_DEPTH                                                             
2025-06-11T17:56:03.286Z DEBUG   0364913d18a19c671bb36dd04d6ad5be0fe8f2894314c36a9db3f03c2d414907e1-onchaind-chan#14575: FUNDING_TRANSACTION/FUNDING_OUTPUT->OUR_UNILATERAL depth 12002                                  
2025-06-11T17:56:03.286Z DEBUG   0364913d18a19c671bb36dd04d6ad5be0fe8f2894314c36a9db3f03c2d414907e1-onchaind-chan#14575: OUR_UNILATERAL/ANCHOR_TO_US->SELF depth 12002                                                   
2025-06-11T17:56:03.286Z DEBUG   0364913d18a19c671bb36dd04d6ad5be0fe8f2894314c36a9db3f03c2d414907e1-onchaind-chan#14575: OUR_UNILATERAL/ANCHOR_TO_THEM->SELF depth 12002                                                 
2025-06-11T17:56:03.286Z DEBUG   0364913d18a19c671bb36dd04d6ad5be0fe8f2894314c36a9db3f03c2d414907e1-onchaind-chan#14575: OUR_UNILATERAL/OUTPUT_TO_THEM->SELF depth 12002                                                 

Metadata

Metadata

Labels

Type::BugAn error, flaw, or fault that produces an incorrect or unexpected result

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions