exception serialization improvements