{"record":{"id":"30bc8c9555f3d26d","repo":"CoplayDev/unity-mcp","slug":"could-not-find-external-project-s-validation-resul","errorCode":null,"errorMessage":"Could not find external project's validation results","messagePattern":"Could not find external project's validation results","errorType":"exception","errorClass":"Exception","httpStatus":null,"severity":"error","filePath":"TestProjects/AssetStoreUploads/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/ExternalProjectValidator.cs","lineNumber":165,"sourceCode":"            }\r\n\r\n            if (exitCode != 0)\r\n            {\r\n                result.Status = ValidationStatus.Failed;\r\n                result.Exception = new Exception($\"Validating the temporary project failed (exit code {exitCode})\\n\\nMore information can be found in the log file: {logFilePath}\");\r\n            }\r\n            else\r\n            {\r\n                result.Status = ValidationStatus.RanToCompletion;\r\n            }\r\n\r\n            return result;\r\n        }\r\n\r\n        private ValidationResult ParseValidationResult(string externalProjectPath)\r\n        {\r\n            if (!CachingService.GetCachedValidatorStateData(externalProjectPath, out var validationStateData))\r\n                throw new Exception(\"Could not find external project's validation results\");\r\n\r\n            var cachedResult = validationStateData.GetResults();\r\n            var cachedTestResults = cachedResult.GetResults();\r\n            var tests = GetApplicableTests(ValidationType.Generic, ValidationType.UnityPackage);\r\n\r\n            foreach (var test in tests)\r\n            {\r\n                if (!cachedTestResults.Any(x => x.Key == test.Id))\r\n                    continue;\r\n\r\n                var matchingTest = cachedTestResults.First(x => x.Key == test.Id);\r\n                test.Result = matchingTest.Value;\r\n            }\r\n\r\n            var result = new ValidationResult()\r\n            {\r\n                Status = cachedResult.GetStatus(),\r\n                HadCompilationErrors = cachedResult.GetHadCompilationErrors(),\r","sourceCodeStart":147,"sourceCodeEnd":183,"githubUrl":"https://github.com/CoplayDev/unity-mcp/blob/c21bf496bca87d54e75bad048563c3adb1782081/TestProjects/AssetStoreUploads/Packages/com.unity.asset-store-tools/Editor/Validator/Scripts/ExternalProjectValidator.cs#L147-L183","documentation":"Thrown by ExternalProjectValidator.ParseValidationResult when CachingService.GetCachedValidatorStateData cannot find cached results for the external project path. The external validation flow runs in a temporary project and stores results in a cache keyed by project path; if that cache is missing or was cleared, parsing cannot proceed.","triggerScenarios":"Calling ParseValidationResult(externalProjectPath) when the temporary validation project never completed, the caching service was reset, the cache key (project path) differs from what was written, or the validation run crashed before caching results.","commonSituations":"The temporary project was cleaned up (e.g. by a temp-dir sweep or editor restart) before results were read; the validation run was interrupted; or the externalProjectPath passed to parse differs (absolute vs relative, trailing slash) from the one used during caching.","solutions":["Re-run the full external validation flow so CachingService stores fresh results before parsing.","Ensure the externalProjectPath used for parsing exactly matches the path used during the validation run.","Avoid clearing the caching service temp directory between validation and result parsing."],"exampleFix":"// before\n// parse immediately after a cache wipe\nvar res = validator.ParseValidationResult(projectPath);\n// after\n// run validation first so results are cached, then parse\nawait validator.RunValidation();\nvar res = validator.ParseValidationResult(projectPath);","handlingStrategy":"retry","validationCode":"if (!CachingService.GetCachedValidatorStateData(path, out _))\n    throw new Exception($\"No cached results for {path}; run validation first\");","typeGuard":"static bool HasCachedResults(string path) =>\n    CachingService.GetCachedValidatorStateData(path, out _);","tryCatchPattern":"try { return validator.ParseValidationResult(path); }\ncatch (Exception ex) when (ex.Message.Contains(\"validation results\")) { /* re-run validation */ }","preventionTips":["Run the full validation flow before parsing results.","Keep the cache path stable between run and parse."],"tags":["csharp","unity","asset-store","validator","caching"],"backgroundTag":null,"analyzedSha":"c21bf496bca87d54e75bad048563c3adb1782081","analyzedAt":"2026-08-13T17:36:56.095Z","schemaVersion":2},"datasetVersion":"2026-08-13T19:17:28.613Z"}