{"record":{"id":"ba5dfdf3703af63b","repo":"AlistGo/alist","slug":"create-upload-of-s-failed-w","errorCode":null,"errorMessage":"create upload of %s failed: %w","messagePattern":"create upload of (.+?) failed: %w","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"drivers/123_open/upload.go","lineNumber":60,"sourceCode":"\t// the create call needs the whole file MD5; reuse the stream's own hash\n\t// when it has one, otherwise cache the stream and hash it on the way\n\tetag := file.GetHash().GetHash(utils.MD5)\n\tif len(etag) != utils.MD5.Width {\n\t\t_, etag, err = stream.CacheFullInTempFileAndHash(file, utils.MD5)\n\t\tif err != nil {\n\t\t\treturn nil, fmt.Errorf(\"calculate md5 of %s failed: %w\", file.GetName(), err)\n\t\t}\n\t}\n\n\tsize := file.GetSize()\n\tcreated, err := d.client.Upload.Create(ctx, &pan123.UploadCreateRequest{\n\t\tParentFileID: parentFileID,\n\t\tFilename:     file.GetName(),\n\t\tEtag:         etag,\n\t\tSize:         size,\n\t})\n\tif err != nil {\n\t\treturn nil, fmt.Errorf(\"create upload of %s failed: %w\", file.GetName(), err)\n\t}\n\t// instant upload: the server already holds this content\n\tif created.Reuse {\n\t\tup(100)\n\t\treturn uploadedObj(created.FileID, file, etag), nil\n\t}\n\tif created.PreuploadID == \"\" {\n\t\treturn nil, errors.New(\"the server returned no preuploadID\")\n\t}\n\n\tservers := created.Servers\n\tif len(servers) == 0 {\n\t\tservers, err = d.client.Upload.Domains(ctx)\n\t\tif err != nil {\n\t\t\treturn nil, fmt.Errorf(\"get upload domains failed: %w\", err)\n\t\t}\n\t}\n\tif len(servers) == 0 {","sourceCodeStart":42,"sourceCodeEnd":78,"githubUrl":"https://github.com/AlistGo/alist/blob/843d9dc8149126976b2625911e45a4d3ffd6f2f5/drivers/123_open/upload.go#L42-L78","documentation":"Error \"create upload of %s failed: %w\" thrown in AlistGo/alist.","triggerScenarios":"Thrown at drivers/123_open/upload.go:60 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"}