You can deduct the unpaid principal if you can show that the debt is fully worthless. The fact that the borrower filed for bankruptcy does not automatically establish worthlessness. However, even if you can establish worthlessness, you can only deduct the unpaid principal. As a cash basis taxpayer, the interest you were to receive was never reported as income so no bad debt deduction is allowed for this amount.
Debt on which a person is not personally liable. In case of nonpayment, the creditor must foreclose on property securing the debt. At-risk rules generally bar losses where there is nonrecourse financing, but an exception applies to certain nonrecourse financing for real estate.