The problem is either could be correct.
It would depend on a few factors.
1. Was it an investment?
If yes, then E is out.
Are you in Chap 11?
Are you insolvent.
This is the trickiest one, you can be bankrupt but not insolvent.
Insolvency is usually set by state law.
Here is the law:
(a) Exclusion from gross income
(1) In general
Gross income does not include any amount which (but for this subsection) would be includible in gross income by reason of the discharge (in whole or in part) of indebtedness of the taxpayer if—
(A) the discharge occurs in a title 11 case,
(B) the discharge occurs when the taxpayer is insolvent,
(C) the indebtedness discharged is qualified farm indebtedness,
(D) in the case of a taxpayer other than a C corporation, the indebtedness discharged is qualified real property business indebtedness, or
(E) the indebtedness discharged is qualified principal residence indebtedness which is discharged before January 1, 2013.
This communication does not establish an attorney client relationship, which can only be established by a signed retainer agreement.