carving: fix missing import; fix de-serialization