Add properties to keep stack trace and previous exception