{"record":{"id":"3e9034f6d5744106","repo":"diesel-rs/diesel","slug":"got-invalid-case-identifier-s-only-lowercas","errorCode":null,"errorMessage":"got invalid case identifier: `{s}`\nonly: `lowercase`, `UPPERCASE`, `PascalCase`, `camelCase`, `snake_case`, `SCREAMING_SNAKE_CASE`, `kebab-case` and `SCREAMING-KEBAB-CASE` are supported","messagePattern":"got invalid case identifier: `(.+?)`\nonly: `lowercase`, `UPPERCASE`, `PascalCase`, `camelCase`, `snake_case`, `SCREAMING_SNAKE_CASE`, `kebab-case` and `SCREAMING-KEBAB-CASE` are supported","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"diesel_attribute_parser/src/lib.rs","lineNumber":500,"sourceCode":"    KebabCase,\n    ScreamingKebabCase,\n}\n\nimpl syn::parse::Parse for RenameVariants {\n    fn parse(input: syn::parse::ParseStream) -> Result<Self> {\n        let lit = input.parse::<syn::LitStr>()?;\n        let v = lit.value();\n        let v = match v.as_str() {\n            \"lowercase\" => Self::LowerCase,\n            \"UPPERCASE\" => Self::UpperCase,\n            \"PascalCase\" => Self::PascalCase,\n            \"camelCase\" => Self::CamelCase,\n            \"snake_case\" => Self::SnakeCase,\n            \"SCREAMING_SNAKE_CASE\" => Self::ScreamingSnakeCase,\n            \"kebab-case\" => Self::KebabCase,\n            \"SCREAMING-KEBAB-CASE\" => Self::ScreamingKebabCase,\n            s => {\n                return Err(syn::Error::new(\n                    lit.span(),\n                    format!(\n                        \"got invalid case identifier: `{s}`\\n\\\n                         only: `lowercase`, `UPPERCASE`, `PascalCase`, `camelCase`, \\\n                         `snake_case`, `SCREAMING_SNAKE_CASE`, `kebab-case` \\\n                         and `SCREAMING-KEBAB-CASE` are supported\"\n                    ),\n                ));\n            }\n        };\n        Ok(v)\n    }\n}\n\nimpl RenameVariants {\n    pub fn apply_case_to_enum_variant(&self, input: String) -> String {\n        match self {\n            // Rust enum variants are already pascal case","sourceCodeStart":482,"sourceCodeEnd":518,"githubUrl":"https://github.com/diesel-rs/diesel/blob/6fa6ed01b24b24248ab2a611698d0a7c6a2e9120/diesel_attribute_parser/src/lib.rs#L482-L518","documentation":"Compile-time error from parsing the rename_all-style string of #[diesel(...)] attribute options. RenameVariants::parse reads a string literal and maps it to one of eight supported case conventions (lowercase, UPPERCASE, PascalCase, camelCase, snake_case, SCREAMING_SNAKE_CASE, kebab-case, SCREAMING-KEBAB-CASE); any other string is rejected. This is a validation guard on the literal value, typically a typo or unsupported case name. Fix: use one of the listed case identifiers.","triggerScenarios":"Thrown at diesel_attribute_parser/src/lib.rs:500 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Use one of the supported case names such as `snake_case`, `PascalCase`, or `SCREAMING_SNAKE_CASE`","Check the spelling and hyphenation of the case name"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"6fa6ed01b24b24248ab2a611698d0a7c6a2e9120","analyzedAt":"2026-09-07T01:50:13.074Z","contentChangedAt":"2026-09-07T01:50:13.074Z","schemaVersion":2},"datasetVersion":"2026-09-16T09:17:16.951Z"}