{"record":{"id":"68b7c5e6a1228fc1","repo":"alibaba/spring-ai-alibaba","slug":"unsupported-logical-operator-type-value","errorCode":null,"errorMessage":"Unsupported logical operator type: ${value}","messagePattern":"Unsupported logical operator type: (.+?)","errorType":"validation","errorClass":"IllegalArgumentException","httpStatus":null,"severity":"error","filePath":"spring-ai-alibaba-admin/spring-ai-alibaba-admin-server-start/src/main/java/com/alibaba/cloud/ai/studio/admin/builder/generator/model/workflow/LogicalOperatorType.java","lineNumber":38,"sourceCode":"\n\tAND(\"and\", \"&&\"), OR(\"or\", \"||\");\n\n\tprivate final String value;\n\n\tprivate final String codeValue;\n\n\tLogicalOperatorType(String value, String codeValue) {\n\t\tthis.value = value;\n\t\tthis.codeValue = codeValue;\n\t}\n\n\tpublic static LogicalOperatorType fromValue(String value) {\n\t\tfor (LogicalOperatorType logicalOperatorType : LogicalOperatorType.values()) {\n\t\t\tif (logicalOperatorType.value.equals(value)) {\n\t\t\t\treturn logicalOperatorType;\n\t\t\t}\n\t\t}\n\t\tthrow new IllegalArgumentException(\"Unsupported logical operator type: \" + value);\n\t}\n\n\tpublic String getValue() {\n\t\treturn this.value;\n\t}\n\n\tpublic String getCodeValue() {\n\t\treturn this.codeValue;\n\t}\n\n}\n","sourceCodeStart":20,"sourceCodeEnd":50,"githubUrl":"https://github.com/alibaba/spring-ai-alibaba/blob/f82da0b50f35744c13968191be2b1cd2452ef550/spring-ai-alibaba-admin/spring-ai-alibaba-admin-server-start/src/main/java/com/alibaba/cloud/ai/studio/admin/builder/generator/model/workflow/LogicalOperatorType.java#L20-L50","documentation":"Thrown by LogicalOperatorType.fromValue when the given string does not match any known logical operator value (e.g. and/or). A plain enum-lookup failure indicating the DSL contains an unrecognized logical operator.","triggerScenarios":"Parsing DSL containing a logical operator field with an unexpected string — typo ('AND' vs 'and'), null/empty value, or operator added in a newer DSL schema version.","commonSituations":"Hand-edited DSL, cross-version Dify/Studio exports, case-sensitivity mistakes when authoring workflow conditions.","solutions":["Use the exact canonical value (check LogicalOperatorType.getValue() of valid constants)","Fix casing/typos in the DSL","Regenerate the DSL from the source platform","Add a mapping for the new value in LogicalOperatorType if supported upstream"],"exampleFix":"// before\nLogicalOperatorType.fromValue(\"AND\");\n// after\nLogicalOperatorType.fromValue(\"and\");\n","handlingStrategy":"validation","validationCode":"boolean known = Arrays.stream(LogicalOperatorType.values()).anyMatch(t -> t.getValue().equals(value));","typeGuard":"LogicalOperatorType safeFromValue(String v) { try { return LogicalOperatorType.fromValue(v); } catch (IllegalArgumentException e) { return null; } }","tryCatchPattern":null,"preventionTips":["Lowercase logical operator values ('and'/'or') when authoring DSL","Use enum getValue() output rather than literals","Pin exporter/importer to the same DSL schema version"],"tags":["invalid-enum-value","dsl","operators"],"backgroundTag":"invalid-enum-value","analyzedSha":"f82da0b50f35744c13968191be2b1cd2452ef550","analyzedAt":"2026-09-09T15:32:42.421Z","contentChangedAt":"2026-09-09T15:32:42.421Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}