{"record":{"id":"13ca5ed804536bd6","repo":"apache/hadoop","slug":"unexpected-type-13ca5e","errorCode":null,"errorMessage":"Unexpected: {type}","messagePattern":"Unexpected: (.+?)","errorType":"exception","errorClass":"IOException","httpStatus":null,"severity":"error","filePath":"hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/lib/join/Parser.java","lineNumber":187,"sourceCode":"        case StreamTokenizer.TT_EOF:\n        case StreamTokenizer.TT_EOL:\n          return null;\n        case StreamTokenizer.TT_NUMBER:\n          return new NumToken(tok.nval);\n        case StreamTokenizer.TT_WORD:\n          return new StrToken(TType.IDENT, tok.sval);\n        case '\"':\n          return new StrToken(TType.QUOT, tok.sval);\n        default:\n          switch (type) {\n            case ',':\n              return new Token(TType.COMMA);\n            case '(':\n              return new Token(TType.LPAREN);\n            case ')':\n              return new Token(TType.RPAREN);\n            default:\n              throw new IOException(\"Unexpected: \" + type);\n          }\n      }\n    }\n  }\n\n@SuppressWarnings(\"unchecked\")\n@InterfaceAudience.Public\n@InterfaceStability.Evolving\npublic abstract static class Node extends ComposableInputFormat {\n    /**\n     * Return the node type registered for the particular identifier.\n     * By default, this is a CNode for any composite node and a WNode\n     * for &quot;wrapped&quot; nodes. User nodes will likely be composite\n     * nodes.\n     * @see #addIdentifier(java.lang.String, java.lang.Class[], java.lang.Class, java.lang.Class)\n     * @see CompositeInputFormat#setFormat(org.apache.hadoop.mapred.JobConf)\n     */\n    static Node forIdent(String ident) throws IOException {","sourceCodeStart":169,"sourceCodeEnd":205,"githubUrl":"https://github.com/apache/hadoop/blob/2add9630210752f88ceb1bb74eb65e37bf41da8e/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/lib/join/Parser.java#L169-L205","documentation":"Error \"Unexpected: {type}\" thrown in apache/hadoop.","triggerScenarios":"Thrown by Parser.Token when code reaches an unexpected token type branch that should not occur for a validly lexed expression. Usually indicates a malformed or corrupted join expression string; re-check the expression passed to the join parser.","commonSituations":"Unbalanced parentheses, stray operators, or a malformed identifier in the join expression string.","solutions":["Check the join expression for an unexpected token of the reported type; remove or replace it with a token valid at that position.","Review the composite join grammar and rewrite the expression so tokens appear in a valid order."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"2add9630210752f88ceb1bb74eb65e37bf41da8e","analyzedAt":"2026-08-22T19:55:07.957Z","schemaVersion":2},"datasetVersion":"2026-08-22T20:17:22.307Z"}