fix Stack deserialization, and change ID -> Id