1
0

regtests: extend "extract_preimage" to cover both types of extracts

This commit is contained in:
SomberNight
2025-03-07 17:06:55 +00:00
parent c146321924
commit a7c634b1ab
2 changed files with 49 additions and 19 deletions

View File

@@ -1376,7 +1376,8 @@ class Channel(AbstractChannel):
return
if self.lnworker.get_preimage(payment_hash) is not None:
return
self.logger.info(f'found preimage for {payment_hash.hex()} in witness of length {len(witness)}')
self.logger.info(f"found preimage in witness of length {len(witness)}, for {payment_hash.hex()}")
# ^ note: log message text grepped for in regtests
self.lnworker.save_preimage(payment_hash, preimage)
for htlc, is_sent in found.values():
if is_sent: