Revert first attempt at fix of warning_code

Using mainline commit instead.
Fix errors raised on reports which use --separate-models option

* warning_code was missing, and the fingerprint method on warning relies
on it always existing