{"record":{"id":"78ccce7fecfadd45","repo":"chenhg5/cc-connect","slug":"config-s-references-marker-style-has-unsupported","errorCode":null,"errorMessage":"config: %s.references.marker_style has unsupported value %q","messagePattern":"config: (.+?)\\.references\\.marker_style has unsupported value %q","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"config/config.go","lineNumber":1153,"sourceCode":"\nfunc validateReferenceConfig(prefix string, rc ReferenceConfig) error {\n\tfor _, v := range rc.NormalizeAgents {\n\t\tkey := strings.ToLower(strings.TrimSpace(v))\n\t\tif _, ok := supportedReferenceAgents[key]; !ok {\n\t\t\treturn fmt.Errorf(\"config: %s.references.normalize_agents has unsupported value %q\", prefix, v)\n\t\t}\n\t}\n\tfor _, v := range rc.RenderPlatforms {\n\t\tkey := strings.ToLower(strings.TrimSpace(v))\n\t\tif _, ok := supportedReferencePlatforms[key]; !ok {\n\t\t\treturn fmt.Errorf(\"config: %s.references.render_platforms has unsupported value %q\", prefix, v)\n\t\t}\n\t}\n\tif _, ok := supportedReferenceDisplayPaths[strings.ToLower(strings.TrimSpace(rc.DisplayPath))]; !ok {\n\t\treturn fmt.Errorf(\"config: %s.references.display_path has unsupported value %q\", prefix, rc.DisplayPath)\n\t}\n\tif _, ok := supportedReferenceMarkerStyles[strings.ToLower(strings.TrimSpace(rc.MarkerStyle))]; !ok {\n\t\treturn fmt.Errorf(\"config: %s.references.marker_style has unsupported value %q\", prefix, rc.MarkerStyle)\n\t}\n\tif _, ok := supportedReferenceEnclosureStyles[strings.ToLower(strings.TrimSpace(rc.EnclosureStyle))]; !ok {\n\t\treturn fmt.Errorf(\"config: %s.references.enclosure_style has unsupported value %q\", prefix, rc.EnclosureStyle)\n\t}\n\treturn nil\n}\n\n// validateUsersConfig checks the [projects.users] section for consistency.\nfunc validateUsersConfig(prefix string, u *UsersConfig) error {\n\tif u == nil {\n\t\treturn nil\n\t}\n\tif len(u.Roles) == 0 {\n\t\treturn fmt.Errorf(\"config: %s.users has no roles defined\", prefix)\n\t}\n\twildcardCount := 0\n\tseenUserIDs := make(map[string]string) // userID → role name\n\tfor roleName, rc := range u.Roles {","sourceCodeStart":1135,"sourceCodeEnd":1171,"githubUrl":"https://github.com/chenhg5/cc-connect/blob/4000b2338aa6e850c99df54f8b0ed6ed7460b401/config/config.go#L1135-L1171","documentation":"CC-Connect validates `[projects.references].marker_style` against a fixed set: \"\", \"none\", \"ascii\", \"emoji\". Any other value makes validateReferenceConfig reject the config, quoting the value. It controls how reference markers (e.g. [1], ①) are rendered next to citations.","triggerScenarios":"Loading config.toml with marker_style set to something like \"number\", \"bracket\", or \"unicode\" instead of an allowed value. Matching is case-insensitive and trimmed, so \"ASCII\" would pass.","commonSituations":"Confusing marker_style with enclosure_style vocabularies (bracket/angle belong to enclosure_style, not marker_style); guessing names; typos.","solutions":["Use one of: \"none\", \"ascii\", \"emoji\", or empty string for default","If you wanted bracket-style wrapping, set enclosure_style = \"bracket\" and keep marker_style valid","Fix casing/typos — value must match the allowlist after trim+lowercase"],"exampleFix":"# before\n[projects.references]\nmarker_style = \"number\"\n\n# after\n[projects.references]\nmarker_style = \"ascii\"","handlingStrategy":"validation","validationCode":"var markerStyles = map[string]bool{\"\": true, \"none\": true, \"ascii\": true, \"emoji\": true}\nif !markerStyles[strings.ToLower(strings.TrimSpace(rc.MarkerStyle))] {\n    return fmt.Errorf(\"marker_style %q unsupported\", rc.MarkerStyle)\n}","typeGuard":"func isValidMarkerStyle(v string) bool {\n    switch strings.ToLower(strings.TrimSpace(v)) {\n    case \"\", \"none\", \"ascii\", \"emoji\":\n        return true\n    }\n    return false\n}","tryCatchPattern":null,"preventionTips":["Don't confuse marker_style values (none/ascii/emoji) with enclosure_style values (bracket/angle/code)","Leave empty for the default marker style","Validate config before restarting the daemon"],"tags":["config","validation","allowlist"],"backgroundTag":"invalid-enum-value","analyzedSha":"4000b2338aa6e850c99df54f8b0ed6ed7460b401","analyzedAt":"2026-09-06T11:45:09.575Z","contentChangedAt":"2026-09-06T11:45:09.575Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}