{"record":{"id":"39da0626a393d611","repo":"apache/druid","slug":"non-primitive-supplied-to-primitive-conversion-s","errorCode":null,"errorMessage":"Non-primitive supplied to primitive conversion: %s (this should never happen)","messagePattern":"Non-primitive supplied to primitive conversion: (.+?) \\(this should never happen\\)","errorType":"exception","errorClass":"RE","httpStatus":null,"severity":"error","filePath":"extensions-core/parquet-extensions/src/main/java/org/apache/druid/data/input/parquet/simple/ParquetGroupConverter.java","lineNumber":455,"sourceCode":"              case BINARY:\n                Binary value = g.getBinary(fieldIndex, index);\n                return convertBinaryToDecimal(value, precision, scale);\n              default:\n                throw new RE(\n                    \"Unknown 'DECIMAL' type supplied to primitive conversion: %s (this should never happen)\",\n                    pt.getPrimitiveTypeName()\n                );\n            }\n          case UTF8:\n          case ENUM:\n          case JSON:\n            return g.getString(fieldIndex, index);\n          case LIST:\n          case MAP:\n          case MAP_KEY_VALUE:\n          case BSON:\n          default:\n            throw new RE(\n                \"Non-primitive supplied to primitive conversion: %s (this should never happen)\",\n                ot.name()\n            );\n        }\n      } else {\n        // fallback to handling the raw primitive type if no logical type mapping\n        switch (pt.getPrimitiveTypeName()) {\n          case BOOLEAN:\n            return g.getBoolean(fieldIndex, index);\n          case INT32:\n            return g.getInteger(fieldIndex, index);\n          case INT64:\n            return g.getLong(fieldIndex, index);\n          case FLOAT:\n            return g.getFloat(fieldIndex, index);\n          case DOUBLE:\n            return g.getDouble(fieldIndex, index);\n          case INT96:","sourceCodeStart":437,"sourceCodeEnd":473,"githubUrl":"https://github.com/apache/druid/blob/9b90983fd291f26935af934383ce360473179e4d/extensions-core/parquet-extensions/src/main/java/org/apache/druid/data/input/parquet/simple/ParquetGroupConverter.java#L437-L473","documentation":"Type-guard in ParquetGroupConverter.convertPrimitiveField: a logical type (e.g. LIST, MAP, or another group-based type) reached the primitive-conversion switch, meaning a non-primitive field was dispatched where only primitives are expected — 'this should never happen' per the schema, so it indicates a schema-handling bug or unexpected parquet schema.","triggerScenarios":"Thrown at extensions-core/parquet-extensions/src/main/java/org/apache/druid/data/input/parquet/simple/ParquetGroupConverter.java:455 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Inspect the parquet schema for the field hitting this path; it may use an unusual logical/annotated type.","Update parquet-extensions to a version supporting that schema shape.","Flatten or re-write the data to use standard primitive types."],"exampleFix":null,"handlingStrategy":"type-guard","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"9b90983fd291f26935af934383ce360473179e4d","analyzedAt":"2026-09-07T13:32:30.957Z","contentChangedAt":"2026-09-07T13:32:30.957Z","schemaVersion":2},"datasetVersion":"2026-09-17T15:17:12.973Z"}