{"record":{"id":"21d55241bbaa289b","repo":"stanfordnlp/CoreNLP","slug":"not-a-valid-ellipses-style-value-21d552","errorCode":null,"errorMessage":"Not a valid ellipses style: ${value}","messagePattern":"Not a valid ellipses style: (.+?)","errorType":"validation","errorClass":"IllegalArgumentException","httpStatus":null,"severity":"error","filePath":"src/edu/stanford/nlp/process/PTBLexer.java","lineNumber":61135,"sourceCode":"          } else if (\"normalizeOtherBrackets\".equals(key)) {\n            normalizeOtherBrackets = val;\n          } else if (\"quotes\".equals(key)) {\n            try {\n              quoteStyle = LexerUtils.QuotesEnum.valueOf(value.trim().toUpperCase(Locale.ROOT));\n            } catch (IllegalArgumentException iae) {\n              throw new IllegalArgumentException (\"Not a valid quotes style: \" + value);\n            }\n          } else if (\"splitAssimilations\".equals(key)) {\n            splitAssimilations = val;\n          } else if (\"splitHyphenated\".equals(key)) {\n            splitHyphenated = val;\n          } else if (\"splitForwardSlash\".equals(key)) {\n            splitForwardSlash = val;\n          } else if (\"ellipses\".equals(key)) {\n            try {\n              ellipsisStyle = LexerUtils.EllipsesEnum.valueOf(value.trim().toUpperCase(Locale.ROOT));\n            } catch (IllegalArgumentException iae) {\n              throw new IllegalArgumentException (\"Not a valid ellipses style: \" + value);\n            }\n          } else if (\"dashes\".equals(key)) {\n            try {\n              dashesStyle = LexerUtils.DashesEnum.valueOf(value.trim().toUpperCase(Locale.ROOT));\n            } catch (IllegalArgumentException iae) {\n              throw new IllegalArgumentException (\"Not a valid dashes style: \" + value);\n            }\n          } else if (\"escapeForwardSlashAsterisk\".equals(key)) {\n            escapeForwardSlashAsterisk = val;\n          } else if (\"untokenizable\".equals(key)) {\n            switch (value) {\n              case \"noneDelete\":\n                untokenizable = UntokenizableOptions.NONE_DELETE;\n                break;\n              case \"firstDelete\":\n                untokenizable = UntokenizableOptions.FIRST_DELETE;\n                break;\n              case \"allDelete\":","sourceCodeStart":61117,"sourceCodeEnd":61153,"githubUrl":"https://github.com/stanfordnlp/CoreNLP/blob/1b7edd19c4d0d7b1f13a2591425b9b60a0b1af7a/src/edu/stanford/nlp/process/PTBLexer.java#L61117-L61153","documentation":"Same option-parsing path as the quotes style: the \"ellipses\" option value must be a LexerUtils.EllipsesEnum constant (e.g. UNICODE, UTF8, ASCII). An unrecognized value fails valueOf() and the lexer throws this IllegalArgumentException.","triggerScenarios":"Option map with key=\"ellipses\" and a value not in EllipsesEnum, e.g. ellipses=dots, ellipses=three-dots, or ellipses=unicode with trailing punctuation that trim() does not remove.","commonSituations":"Hand-written tokenize.options strings where the author guesses a style name; copying options from documentation of a different library; combining several options and mis-splitting them so a fragment lands in the value.","solutions":["Use an exact LexerUtils.EllipsesEnum name (case-insensitive), e.g. ellipses=unicode or ellipses=ascii.","Verify the options string is split correctly on commas/whitespace so the value is a single token.","Cross-check the enum constants in the CoreNLP version you run against."],"exampleFix":"// before\nString[] opts = {\"ellipses\", \"three-dots\"};\n// after\nString[] opts = {\"ellipses\", \"unicode\"};","handlingStrategy":"validation","validationCode":"boolean ok = Arrays.stream(LexerUtils.EllipsesEnum.values()).anyMatch(e -> e.name().equalsIgnoreCase(value.trim()));\nif (!ok) throw new IllegalArgumentException(\"ellipses must be a LexerUtils.EllipsesEnum name\");","typeGuard":null,"tryCatchPattern":"try { new PTBTokenizer<>(reader, factory, \"ellipses=\" + style); } catch (IllegalArgumentException e) { if (e.getMessage().contains(\"ellipses style\")) { /* fall back to unicode */ } else throw e; }","preventionTips":["Use EllipsesEnum.valueOf(userInput.trim().toUpperCase()) yourself first to fail fast with a better message.","Whitelist option values in configuration parsing.","Document accepted values next to the config file."],"tags":["tokenizer","enum","configuration"],"backgroundTag":"invalid-enum-value","analyzedSha":"1b7edd19c4d0d7b1f13a2591425b9b60a0b1af7a","analyzedAt":"2026-09-10T02:24:07.274Z","contentChangedAt":"2026-09-10T02:24:07.274Z","schemaVersion":2},"datasetVersion":"2026-09-17T15:17:12.973Z"}