Fixes for deserialization of complete environments