fixes importing logic and initialization

doesn't yet test serialization or deserialization.