{"record":{"id":"ea1f311c8761c4a8","repo":"AlistGo/alist","slug":"failed-to-delete-blob-s-v","errorCode":null,"errorMessage":"failed to delete blob %s: %v","messagePattern":"failed to delete blob (.+?): (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"drivers/azure_blob/util.go","lineNumber":123,"sourceCode":"\t\t\t\treturn fmt.Errorf(\"failed to add delete operation for %s: %w\", blobPath, err)\n\t\t\t}\n\t\t}\n\n\t\t// Submit batch\n\t\tresponses, err := d.containerClient.SubmitBatch(ctx, batchBuilder, nil)\n\t\tif err != nil {\n\t\t\treturn fmt.Errorf(\"batch delete request failed: %w\", err)\n\t\t}\n\n\t\t// Check responses\n\t\tfor _, resp := range responses.Responses {\n\t\t\tif resp.Error != nil && !isNotFoundError(resp.Error) {\n\t\t\t\t// 获取 blob 名称以提供更好的错误信息\n\t\t\t\tblobName := \"unknown\"\n\t\t\t\tif resp.BlobName != nil {\n\t\t\t\t\tblobName = *resp.BlobName\n\t\t\t\t}\n\t\t\t\treturn fmt.Errorf(\"failed to delete blob %s: %v\", blobName, resp.Error)\n\t\t\t}\n\t\t}\n\t}\n\n\treturn nil\n}\n\n// deleteFolder recursively deletes a directory and all its contents\nfunc (d *AzureBlob) deleteFolder(ctx context.Context, prefix string) error {\n\t// Ensure directory path ends with slash\n\tprefix = ensureTrailingSlash(prefix)\n\n\t// Get all blobs under the directory using flattenListBlobs\n\tglobs, err := d.flattenListBlobs(ctx, prefix)\n\tif err != nil {\n\t\treturn fmt.Errorf(\"failed to list blobs for deletion: %w\", err)\n\t}\n","sourceCodeStart":105,"sourceCodeEnd":141,"githubUrl":"https://github.com/AlistGo/alist/blob/843d9dc8149126976b2625911e45a4d3ffd6f2f5/drivers/azure_blob/util.go#L105-L141","documentation":"Error \"failed to delete blob %s: %v\" thrown in AlistGo/alist.","triggerScenarios":"Thrown at drivers/azure_blob/util.go:123 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Inspect the underlying error details in the message, fix the indicated cause (credentials, network, or provider-side failure), and retry."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"843d9dc8149126976b2625911e45a4d3ffd6f2f5","analyzedAt":"2026-08-15T12:14:11.722Z","schemaVersion":2},"datasetVersion":"2026-08-15T17:31:12.345Z"}