{"record":{"id":"d3af786bda3214ca","repo":"tui-cs/Terminal.Gui","slug":"null-property-name","errorCode":null,"errorMessage":"null property name.","messagePattern":"null property name\\.","errorType":"exception","errorClass":"JsonException","httpStatus":null,"severity":"error","filePath":"Terminal.Gui/Configuration/SchemeJsonConverter.cs","lineNumber":75,"sourceCode":"                    \"code\" => scheme with { Code = attribute },\n                    \"codecomment\" => scheme with { CodeComment = attribute },\n                    \"codekeyword\" => scheme with { CodeKeyword = attribute },\n                    \"codestring\" => scheme with { CodeString = attribute },\n                    \"codenumber\" => scheme with { CodeNumber = attribute },\n                    \"codeoperator\" => scheme with { CodeOperator = attribute },\n                    \"codetype\" => scheme with { CodeType = attribute },\n                    \"codepreprocessor\" => scheme with { CodePreprocessor = attribute },\n                    \"codeidentifier\" => scheme with { CodeIdentifier = attribute },\n                    \"codeconstant\" => scheme with { CodeConstant = attribute },\n                    \"codepunctuation\" => scheme with { CodePunctuation = attribute },\n                    \"codefunctionname\" => scheme with { CodeFunctionName = attribute },\n                    \"codeattribute\" => scheme with { CodeAttribute = attribute },\n                    _ => throw new JsonException ($\"{propertyName}: Unrecognized Scheme Attribute name.\")\n                };\n            }\n            else\n            {\n                throw new JsonException (\"null property name.\");\n            }\n        }\n\n        throw new JsonException ($\"After {propertyName}: Invalid Json.\");\n    }\n\n    /// <inheritdoc/>\n    public override void Write (Utf8JsonWriter writer, Scheme value, JsonSerializerOptions options)\n    {\n        writer.WriteStartObject ();\n\n        foreach (VisualRole role in Enum.GetValues<VisualRole> ())\n        {\n            // Get the attribute for the role\n\n            if (!value.TryGetExplicitlySetAttributeForRole (role, out Attribute? attribute))\n            {\n                // Skip attributes that are not explicitly set","sourceCodeStart":57,"sourceCodeEnd":93,"githubUrl":"https://github.com/tui-cs/Terminal.Gui/blob/2e47b11478db083499917f2ad27c34d30efb0df1/Terminal.Gui/Configuration/SchemeJsonConverter.cs#L57-L93","documentation":"reader.GetString() returned null for a property name inside a Scheme object. Well-formed JSON always has non-null string property names, so this indicates deeply malformed input or a reader positioned on an unexpected token.","triggerScenarios":"Extremely malformed JSON where the reader is on a non-string token that the loop interpreted as a property name; corrupted or hand-mangled config.","commonSituations":"Corrupted config file; truncated/garbled JSON; a buggy config generator.","solutions":["Re-create the config from a known-good default.","Run the file through a JSON validator to locate the corruption."],"exampleFix":null,"handlingStrategy":"validation","validationCode":"// The file is corrupt; validate it parses cleanly before loading\ntry { JsonDocument.Parse (File.ReadAllText (path)); }\ncatch (JsonException) { /* file is corrupt; regenerate from default */ }","typeGuard":null,"tryCatchPattern":"try { ConfigurationManager.Apply (); }\ncatch (JsonException ex) when (ex.Message == \"null property name.\")\n{ /* config is deeply malformed; regenerate from default */ }","preventionTips":["Do not hand-edit minified JSON.","Keep config under version control to recover from corruption."],"tags":["config","json","scheme","corruption"],"backgroundTag":null,"analyzedSha":"2e47b11478db083499917f2ad27c34d30efb0df1","analyzedAt":"2026-08-13T19:20:08.826Z","schemaVersion":2},"datasetVersion":"2026-08-14T00:17:13.853Z"}