{"record":{"id":"8d6af4d61528a8fd","repo":"goharbor/harbor","slug":"tcr-only-support-repo-in-format-namespace-name","errorCode":null,"errorMessage":"tcr only support repo in format <namespace>/<name>, but got: %s","messagePattern":"tcr only support repo in format <namespace>/<name>, but got: (.+?)","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"src/pkg/reg/adapter/tencentcr/artifact_registry.go","lineNumber":182,"sourceCode":"\t\t\t\t}\n\t\t\t\tnamespaces = append(namespaces, nms...)\n\t\t\t}\n\t\t}\n\t}\n\n\tif len(namespaces) > 0 {\n\t\tlog.Debugf(\"[tencent-tcr.listCandidateNamespaces] pattern=%s, namespaces=%v\", namespacePattern, namespaces)\n\t\treturn namespaces, nil\n\t}\n\n\t// list all\n\treturn a.listNamespaces()\n}\n\nfunc (a *adapter) DeleteManifest(repository, reference string) (err error) {\n\tparts := strings.Split(repository, \"/\")\n\tif len(parts) != 2 {\n\t\treturn fmt.Errorf(\"tcr only support repo in format <namespace>/<name>, but got: %s\", repository)\n\t}\n\tlog.Warningf(\"[tencent-tcr.DeleteManifest] namespace=%s, repository=%s, tag=%s\", parts[0], parts[1], reference)\n\n\treturn a.deleteImage(parts[0], parts[1], reference)\n}\n","sourceCodeStart":164,"sourceCodeEnd":188,"githubUrl":"https://github.com/goharbor/harbor/blob/7b2fd08cc568955cca339afeefab27372840d936/src/pkg/reg/adapter/tencentcr/artifact_registry.go#L164-L188","documentation":"Returned by DeleteManifest when the repository string is not exactly '<namespace>/<name>' — i.e. splitting on '/' does not yield exactly two parts. Tencent TCR requires this two-segment layout to derive the namespace and repo name for deletion. The input at fault is the repository argument passed by the caller.","triggerScenarios":"Thrown at src/pkg/reg/adapter/tencentcr/artifact_registry.go:182 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Pass the repository in the exact <namespace>/<name> form required by TCR","Reject or normalize repository names containing extra or missing path segments upstream","Validate the repository format before invoking DeleteManifest"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"7b2fd08cc568955cca339afeefab27372840d936","analyzedAt":"2026-08-16T00:00:10.961Z","contentChangedAt":"2026-08-16T00:00:10.961Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}