{"record":{"id":"a53279f0fa4ed0cb","repo":"CoplayDev/unity-mcp","slug":"the-selected-uvx-executable-does-not-exist","errorCode":null,"errorMessage":"The selected uvx executable does not exist","messagePattern":"The selected uvx executable does not exist","errorType":"exception","errorClass":"ArgumentException","httpStatus":null,"severity":"error","filePath":"MCPForUnity/Editor/Services/PathResolverService.cs","lineNumber":142,"sourceCode":"                2000);\n        }\n\n        public bool IsClaudeCliDetected()\n        {\n            return !string.IsNullOrEmpty(GetClaudeCliPath());\n        }\n\n        public void SetUvxPathOverride(string path)\n        {\n            if (string.IsNullOrEmpty(path))\n            {\n                ClearUvxPathOverride();\n                return;\n            }\n\n            if (!File.Exists(path))\n            {\n                throw new ArgumentException(\"The selected uvx executable does not exist\");\n            }\n\n            EditorPrefs.SetString(EditorPrefKeys.UvxPathOverride, path);\n        }\n\n        public void SetClaudeCliPathOverride(string path)\n        {\n            if (string.IsNullOrEmpty(path))\n            {\n                ClearClaudeCliPathOverride();\n                return;\n            }\n\n            if (!File.Exists(path))\n            {\n                throw new ArgumentException(\"The selected Claude CLI executable does not exist\");\n            }\n","sourceCodeStart":124,"sourceCodeEnd":160,"githubUrl":"https://github.com/CoplayDev/unity-mcp/blob/c21bf496bca87d54e75bad048563c3adb1782081/MCPForUnity/Editor/Services/PathResolverService.cs#L124-L160","documentation":"Thrown by PathResolverService.SetUvxPathOverride when the given path does not exist as a file (File.Exists is false). uvx (the uv tool runner) must be a real executable on disk before it is stored as the override in EditorPrefs. An empty path is treated as 'clear override' and does not throw; only a non-empty, non-existent path throws.","triggerScenarios":"User picked a uvx path that is a directory, a stale shortcut, or a typo; the uv install was moved/uninstalled after selection; a bare command name ('uvx') passed instead of a full path.","commonSituations":"uv installed via a method that moved/removed the binary; Windows path without .exe; user typed a name instead of browsing; PATH changed since selection.","solutions":["Locate the real uvx/uv executable (run 'which uvx' on macOS/Linux or 'where uvx' on Windows).","On Windows pass the full path including .exe (e.g. C:\\Users\\you\\.local\\bin\\uvx.exe).","If unsure, clear the override (pass empty) and let auto-detection find uvx on PATH."],"exampleFix":"// before\nresolver.SetUvxPathOverride(typedPath); // throws if file missing\n\n// after\nif (!string.IsNullOrEmpty(typedPath) && File.Exists(typedPath))\n    resolver.SetUvxPathOverride(typedPath);\nelse\n    resolver.ClearUvxPathOverride(); // fall back to auto-detection","handlingStrategy":"validation","validationCode":"if (string.IsNullOrEmpty(path)) { resolver.ClearUvxPathOverride(); return; }\nif (!File.Exists(path)) return ErrorResponse($\"uvx executable not found: {path}\");\nresolver.SetUvxPathOverride(path);","typeGuard":"static bool IsExistingExecutable(string p) => !string.IsNullOrEmpty(p) && File.Exists(p);","tryCatchPattern":"try { resolver.SetUvxPathOverride(path); }\ncatch (ArgumentException ex) when (ex.Message.Contains(\"uvx\"))\n{ /* locate the real uvx/uv binary; or clear override to use auto-detection */ }","preventionTips":["Browse to the real uvx/uv binary; on Windows include .exe.","If unsure, clear the override and let auto-detection find uvx on PATH.","Re-detect after moving/uninstalling uv."],"tags":["path-resolver","uvx","validation","config","filesystem"],"backgroundTag":null,"analyzedSha":"c21bf496bca87d54e75bad048563c3adb1782081","analyzedAt":"2026-08-13T17:36:56.095Z","schemaVersion":2},"datasetVersion":"2026-08-13T19:17:28.613Z"}