def was_htlc_failed(self, *, htlc_id: int, htlc_proposer: HTLCOwner) -> bool:
        """Returns whether an HTLC has been (or will be if we already know) failed."""
        fails = self.log[htlc_proposer]['fails']
        if htlc_id not in fails:
            return False
        return fails[htlc_id][htlc_proposer] is not None
Returns whether an HTLC has been (or will be if we already know) failed.
electrum/lnhtlc.py