When a channel is in CHANNELD_AWAITING_LOCKIN ,listpeers does not return scid. I made this change locally to fix it:
channels = list(filter(lambda channel: channel['state'] == 'CHANNELD_NORMAL' and channel['short_channel_id'] != scid,
channels))
Also had to comment out these lines:
if len(channels) != channels_length-1: # We should have one less channel
return { 'code': -1,
'message': f'Short channel id {scid} is not valid' }
It works for me locally now but creating issue just to let you and others know if they encounter it.
When a channel is in CHANNELD_AWAITING_LOCKIN ,listpeers does not return scid. I made this change locally to fix it: channels = list(filter(lambda channel: channel['state'] == 'CHANNELD_NORMAL' and channel['short_channel_id'] != scid, channels))
Also had to comment out these lines: if len(channels) != channels_length-1: # We should have one less channel return { 'code': -1, 'message': f'Short channel id {scid} is not valid' }
It works for me locally now but creating issue just to let you and others know if they encounter it.