{"record":{"id":"383491fad6290727","repo":"babalae/better-genshin-impact","slug":"leylineoutcropdata-json","errorCode":null,"errorMessage":"LeyLineOutcropData.json 未找到","messagePattern":"LeyLineOutcropData\\.json 未找到","errorType":"exception","errorClass":"FileNotFoundException","httpStatus":null,"severity":"critical","filePath":"BetterGenshinImpact/GameTask/AutoLeyLineOutcrop/AutoLeyLineOutcropTask.cs","lineNumber":759,"sourceCode":"    private static PathingPartyConfig BuildLeyLinePathingPartyConfig()\n    {\n        var partyConfig = PathingPartyConfig.BuildDefault();\n        partyConfig.SkipPartySwitch = true;\n        return partyConfig;\n    }\n\n    private async Task<NodeData> LoadNodeData()\n    {\n        if (_nodeData != null)\n        {\n            return _nodeData;\n        }\n\n        var workDir = Global.Absolute(@\"GameTask\\AutoLeyLineOutcrop\");\n        var nodePath = Path.Combine(workDir, \"Assets\", \"LeyLineOutcropData.json\");\n        if (!File.Exists(nodePath))\n        {\n            throw new FileNotFoundException(\"LeyLineOutcropData.json 未找到\", nodePath);\n        }\n\n        var raw = JsonSerializer.Deserialize<RawNodeData>(File.ReadAllText(nodePath))\n                  ?? throw new Exception(\"节点数据解析失败\");\n        _nodeData = AdaptNodeData(raw);\n        return _nodeData;\n    }\n\n    private static NodeData AdaptNodeData(RawNodeData raw)\n    {\n        var nodes = new List<Node>();\n        foreach (var teleport in raw.Teleports)\n        {\n            nodes.Add(new Node\n            {\n                Id = teleport.Id,\n                Region = teleport.Region,\n                Position = teleport.Position,","sourceCodeStart":741,"sourceCodeEnd":777,"githubUrl":"https://github.com/babalae/better-genshin-impact/blob/a7cb36712dcb409be610257d877fcea3597e9d6b/BetterGenshinImpact/GameTask/AutoLeyLineOutcrop/AutoLeyLineOutcropTask.cs#L741-L777","documentation":"Thrown as a FileNotFoundException by LoadNodeData when the file GameTask/AutoLeyLineOutcrop/Assets/LeyLineOutcropData.json does not exist. This file contains the teleport/blossom node graph (nodes, positions, and edges with route references) that the path-finding logic (FindPathsToTarget, FindReversePathsIfNeeded) uses to compute navigation routes. It is a bundled asset; its absence means the entire node-based navigation system cannot function.","triggerScenarios":"LoadNodeData (called from ExecutePathsUsingNodeData via ExecuteMatchingStrategy) resolves the path via Global.Absolute and checks File.Exists. Fires when the deployment is missing Assets/LeyLineOutcropData.json. The method caches the result in _nodeData so this only fires once per task run.","commonSituations":"Incomplete installation missing the node data file; antivirus quarantine; a refactor moved/renamed the file without updating the path; a build/packaging step excluded the JSON from output; running from source without the Assets directory populated.","solutions":["Reinstall the application to restore the bundled Assets/LeyLineOutcropData.json file.","If building from source, verify the file is marked as CopyToOutputDirectory in the .csproj.","Check antivirus quarantine history and restore/exclude the file.","Verify the file exists at Global.Absolute(@\"GameTask\\AutoLeyLineOutcrop\\Assets\\LeyLineOutcropData.json\")."],"exampleFix":null,"handlingStrategy":"validation","validationCode":"// Before loading node data, verify the file exists\nvar nodePath = Path.Combine(Global.Absolute(@\"GameTask\\AutoLeyLineOutcrop\"), \"Assets\", \"LeyLineOutcropData.json\");\nif (!File.Exists(nodePath))\n{\n    Logger.LogError(\"LeyLineOutcropData.json 不存在，请重新安装程序: {Path}\", nodePath);\n    return;\n}","typeGuard":null,"tryCatchPattern":"catch (FileNotFoundException ex) when (ex.Message.Contains(\"LeyLineOutcropData.json 未找到\"))\n{\n    logger.LogError(\"节点数据文件缺失，请重新安装程序: {Path}\", ex.FileName);\n    ThemedMessageBox.Error(\"节点数据文件缺失，请重新安装程序\", \"文件未找到\");\n}","preventionTips":["Use a complete application installation with all bundled assets.","If building from source, verify LeyLineOutcropData.json has CopyToOutputDirectory set.","Do not delete or move files under the Assets directory.","Add antivirus exclusions for the application directory."],"tags":["ley-line","file-not-found","assets","node-graph","navigation"],"backgroundTag":null,"analyzedSha":"a7cb36712dcb409be610257d877fcea3597e9d6b","analyzedAt":"2026-08-13T16:44:57.548Z","schemaVersion":2},"datasetVersion":"2026-08-13T19:17:28.613Z"}