{"record":{"id":"fcab284dbff3fe7f","repo":"juanfont/headscale","slug":"resolving-destination-q-w","errorCode":null,"errorMessage":"resolving destination %q: %w","messagePattern":"resolving destination %q: %w","errorType":"validation","errorClass":null,"httpStatus":400,"severity":"error","filePath":"hscontrol/policy/v2/sshtest.go","lineNumber":470,"sourceCode":"\n\t\t\t\tif _, dup := seen[n.ID()]; dup {\n\t\t\t\t\tcontinue\n\t\t\t\t}\n\n\t\t\t\tseen[n.ID()] = struct{}{}\n\t\t\t\tout = append(out, n)\n\t\t\t}\n\n\t\t\tif !matched {\n\t\t\t\temptyDsts = append(emptyDsts, dstLabel)\n\t\t\t}\n\n\t\t\tcontinue\n\t\t}\n\n\t\tips, err := alias.Resolve(pol, users, nodes)\n\t\tif err != nil {\n\t\t\treturn nil, nil, fmt.Errorf(\"resolving destination %q: %w\", dstLabel, err)\n\t\t}\n\n\t\tif ips == nil || ips.Empty() {\n\t\t\temptyDsts = append(emptyDsts, dstLabel)\n\n\t\t\tcontinue\n\t\t}\n\n\t\tset, err := prefixesToIPSet(ips.Prefixes())\n\t\tif err != nil {\n\t\t\treturn nil, nil, fmt.Errorf(\"building IPSet for %q: %w\", dstLabel, err)\n\t\t}\n\n\t\tfor _, n := range nodes.All() {\n\t\t\tif !n.InIPSet(set) {\n\t\t\t\tcontinue\n\t\t\t}\n","sourceCodeStart":452,"sourceCodeEnd":488,"githubUrl":"https://github.com/juanfont/headscale/blob/565fd254d06c4c7f9a8cad1714a43445c79ba420/hscontrol/policy/v2/sshtest.go#L452-L488","documentation":"Error \"resolving destination %q: %w\" thrown in juanfont/headscale.","triggerScenarios":"Thrown at hscontrol/policy/v2/sshtest.go:470 when the library encounters an invalid state.","commonSituations":"The named SSH test destination could not be resolved. Check the destination alias, tag, or user exists in the policy.","solutions":["Inspect the wrapped error for the underlying cause and correct the failing condition (resolving destination); retry the operation after fixing the input, configuration, or environment."],"exampleFix":"Inspect the wrapped error for the underlying cause and correct the failing condition (resolving destination); retry the operation after fixing the input, configuration, or environment.","handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"565fd254d06c4c7f9a8cad1714a43445c79ba420","analyzedAt":"2026-08-15T13:12:30.133Z","schemaVersion":2},"datasetVersion":"2026-08-15T17:31:12.345Z"}