{"record":{"id":"0f49e2d3a5a3d26e","repo":"apache/flink","slug":"unsupported-page-type","errorCode":null,"errorMessage":"Unsupported page type: {}","messagePattern":"Unsupported page type: (.+?)","errorType":"exception","errorClass":"RuntimeException","httpStatus":null,"severity":"error","filePath":"flink-formats/flink-parquet/src/main/java/org/apache/flink/formats/parquet/vector/reader/AbstractColumnReader.java","lineNumber":160,"sourceCode":"    /** Reads `total` values from this columnReader into column. */\n    @Override\n    public final void readToVector(int readNumber, VECTOR vector) throws IOException {\n        int rowId = 0;\n        WritableIntVector dictionaryIds = null;\n        if (dictionary != null) {\n            dictionaryIds = vector.reserveDictionaryIds(readNumber);\n        }\n        while (readNumber > 0) {\n            // Compute the number of values we want to read in this page.\n            int leftInPage = (int) (endOfPageValueCount - valuesRead);\n            if (leftInPage == 0) {\n                DataPage page = pageReader.readPage();\n                if (page instanceof DataPageV1) {\n                    readPageV1((DataPageV1) page);\n                } else if (page instanceof DataPageV2) {\n                    readPageV2((DataPageV2) page);\n                } else {\n                    throw new RuntimeException(\"Unsupported page type: \" + page.getClass());\n                }\n                leftInPage = (int) (endOfPageValueCount - valuesRead);\n            }\n            int num = Math.min(readNumber, leftInPage);\n            if (isCurrentPageDictionaryEncoded) {\n                // Read and decode dictionary ids.\n                runLenDecoder.readDictionaryIds(\n                        num, dictionaryIds, vector, rowId, maxDefLevel, this.dictionaryIdsDecoder);\n\n                if (vector.hasDictionary() || (rowId == 0 && supportLazyDecode())) {\n                    // Column vector supports lazy decoding of dictionary values so just set the\n                    // dictionary.\n                    // We can't do this if rowId != 0 AND the column doesn't have a dictionary (i.e.\n                    // some\n                    // non-dictionary encoded values have already been added).\n                    vector.setDictionary(new ParquetDictionary(dictionary, descriptor));\n                } else {\n                    readBatchFromDictionaryIds(rowId, num, vector, dictionaryIds);","sourceCodeStart":142,"sourceCodeEnd":178,"githubUrl":"https://github.com/apache/flink/blob/2f3c205e9266cb30240eb7f4fdab15cad629a70f/flink-formats/flink-parquet/src/main/java/org/apache/flink/formats/parquet/vector/reader/AbstractColumnReader.java#L142-L178","documentation":"RuntimeException from the read loop in AbstractColumnReader.readToVector: after finishing a page, pageReader.readPage() returned an object that is neither DataPageV1 nor DataPageV2. parquet-mr's page model has only these two concrete data page formats, so this branch indicates an unexpected page implementation - practically only seen with version-skewed parquet-mr jars on the classpath or corrupt page headers.","triggerScenarios":"readToVector hitting endOfPageValueCount == valuesRead and readPage() yielding an unknown DataPage subclass - e.g. a newer parquet-mr version mixed into the user classpath supplying pages the Flink reader does not recognize.","commonSituations":"User jars bundling a different parquet-mr version than flink-parquet depends on; shaded-dependency leaks in connectors; rarely, corrupted page data parsed into a bogus page object.","solutions":["Check for parquet-mr version conflicts: mvn dependency:tree / classpath scan; exclude extra parquet-mr from user jars so flink-parquet's version wins","Verify the file with an independent reader to rule out corruption; regenerate if broken","Align writer, reader, and bundled parquet-mr versions"],"exampleFix":null,"handlingStrategy":"try-catch","validationCode":"// detect parquet-mr version conflicts before job submission\nClassLoader cl = Thread.currentThread().getContextClassLoader();\nEnumeration<URL> urls = cl.getResources(\"org/apache/parquet/column/page/DataPageV1.class\");\nif (Collections.list(urls).size() > 1) throw new IllegalStateException(\"Multiple parquet-mr jars on classpath\");","typeGuard":null,"tryCatchPattern":"catch (RuntimeException e) { if (e.getMessage() != null && e.getMessage().startsWith(\"Unsupported page type\")) { /* fix parquet-mr version conflict in user jars */ } else throw e; }","preventionTips":["Shade or exclude parquet-mr from connector/user jars","Keep one parquet-mr version across writer, reader, and Flink"],"tags":["parquet","version-conflict","page","classpath","flink"],"backgroundTag":null,"analyzedSha":"2f3c205e9266cb30240eb7f4fdab15cad629a70f","analyzedAt":"2026-08-14T08:48:24.518Z","schemaVersion":2},"datasetVersion":"2026-08-14T10:17:34.591Z"}