{"record":{"id":"a53eac6d6f5b64e6","repo":"elastic/elasticsearch","slug":"path-not-supported-for-getname-path","errorCode":null,"errorMessage":"path not supported for [{getName()}]: {path}","messagePattern":"path not supported for \\[(.+?)\\]: (.+?)","errorType":"exception","errorClass":"IllegalArgumentException","httpStatus":null,"severity":"error","filePath":"modules/aggregations/src/main/java/org/elasticsearch/aggregations/metric/InternalMatrixStats.java","lineNumber":234,"sourceCode":"                default -> throw new IllegalArgumentException(\"Found unknown path element [\" + element + \"] in [\" + getName() + \"]\");\n            };\n        } else if (path.size() == 1) {\n            String element = path.get(0);\n            if (results == null) {\n                return emptyMap();\n            }\n            return switch (element) {\n                case \"counts\" -> results.getFieldCounts();\n                case \"means\" -> results.getMeans();\n                case \"variances\" -> results.getVariances();\n                case \"skewness\" -> results.getSkewness();\n                case \"kurtosis\" -> results.getKurtosis();\n                case \"covariance\" -> results.getCovariances();\n                case \"correlation\" -> results.getCorrelations();\n                default -> throw new IllegalArgumentException(\"Found unknown path element [\" + element + \"] in [\" + getName() + \"]\");\n            };\n        } else {\n            throw new IllegalArgumentException(\"path not supported for [\" + getName() + \"]: \" + path);\n        }\n    }\n\n    @Override\n    protected AggregatorReducer getLeaderReducer(AggregationReduceContext reduceContext, int size) {\n        return new AggregatorReducer() {\n            private RunningStats runningStats;\n\n            @Override\n            public void accept(InternalAggregation aggregation) {\n                final InternalMatrixStats internalMatrixStats = (InternalMatrixStats) aggregation;\n                if (internalMatrixStats.stats != null) {\n                    if (runningStats == null) {\n                        runningStats = new RunningStats();\n                    }\n                    final Set<String> missingFields = runningStats.missingFieldNames(internalMatrixStats.stats);\n                    if (missingFields.isEmpty() == false) {\n                        throw new IllegalArgumentException(","sourceCodeStart":216,"sourceCodeEnd":252,"githubUrl":"https://github.com/elastic/elasticsearch/blob/db6a809a667c081ca1dc7500389d26975573215f/modules/aggregations/src/main/java/org/elasticsearch/aggregations/metric/InternalMatrixStats.java#L216-L252","documentation":"Error \"path not supported for [{getName()}]: {path}\" thrown in elastic/elasticsearch.","triggerScenarios":"Thrown at modules/aggregations/src/main/java/org/elasticsearch/aggregations/metric/InternalMatrixStats.java:234 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"analyzedSha":"db6a809a667c081ca1dc7500389d26975573215f","analyzedAt":"2026-08-12T01:39:14.192Z","schemaVersion":2},"datasetVersion":"2026-08-12T08:17:17.861Z"}