{"record":{"id":"63a75b2d734cb466","repo":"siyuan-note/siyuan","slug":"w-cleanup-failed-v","errorCode":null,"errorMessage":"%w; cleanup failed: %v","messagePattern":"%w; cleanup failed: (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"kernel/model/attribute_view_new_item.go","lineNumber":613,"sourceCode":"}\n\nfunc applyNewItemContentTemplate(templatePath, docID string) error {\n\treturn applyDocContentTemplateAfterIndex(templatePath, docID)\n}\n\nfunc removeCreatedNewItemDoc(docID string) error {\n\tblockTree := treenode.GetBlockTree(docID)\n\tif nil == blockTree {\n\t\treturn nil\n\t}\n\treturn RemoveDoc(blockTree.BoxID, blockTree.Path)\n}\n\nfunc newItemCreationError(createErr, cleanupErr error) error {\n\tif nil == cleanupErr {\n\t\treturn createErr\n\t}\n\treturn fmt.Errorf(\"%w; cleanup failed: %v\", createErr, cleanupErr)\n}\n","sourceCodeStart":595,"sourceCodeEnd":615,"githubUrl":"https://github.com/siyuan-note/siyuan/blob/251596fc0de2f9528c00c224252fd073a99973f4/kernel/model/attribute_view_new_item.go#L595-L615","documentation":"Error \"%w; cleanup failed: %v\" thrown in siyuan-note/siyuan.","triggerScenarios":"Creating an attribute view item failed and the automatic rollback of the partially created row/document also failed.","commonSituations":"Occurs when row creation fails partway and the rollback cleanup of the partially created documents also fails.","solutions":["Address the primary error first (the part before the semicolon); then manually remove any leftover partially-created row or document.","Check the kernel log for both errors and re-run the operation after cleanup."],"exampleFix":"Delete the orphaned row/document left by the failed creation, then retry the original operation.","handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"251596fc0de2f9528c00c224252fd073a99973f4","analyzedAt":"2026-08-12T21:18:37.123Z","schemaVersion":2},"datasetVersion":"2026-08-12T23:17:12.415Z"}