{"record":{"id":"35139dd6b152ca1c","repo":"Foundry376/Mailspring","slug":"validation-failed-at-keypath-json-stringify-35139d","errorCode":null,"errorMessage":"Validation failed at ${keyPath}, ${JSON.stringify(value)} must be null","messagePattern":"Validation failed at (.+?), (.+?) must be null","errorType":"validation","errorClass":"Error","httpStatus":null,"severity":"error","filePath":"app/src/config.ts","lineNumber":829,"sourceCode":"    },\n  },\n\n  string: {\n    validate(keyPath, value, schema) {\n      if (typeof value !== 'string') {\n        throw new Error(\n          `Validation failed at ${keyPath}, ${JSON.stringify(value)} must be a string`\n        );\n      }\n      return value;\n    },\n  },\n\n  null: {\n    // null sort of isnt supported. It will just unset in this case\n    coerce(keyPath, value, schema) {\n      if (![undefined, null].includes(value)) {\n        throw new Error(`Validation failed at ${keyPath}, ${JSON.stringify(value)} must be null`);\n      }\n      return value;\n    },\n  },\n\n  object: {\n    coerce(keyPath, value, schema) {\n      if (!isPlainObject(value)) {\n        throw new Error(\n          `Validation failed at ${keyPath}, ${JSON.stringify(value)} must be an object`\n        );\n      }\n      if (schema.properties == null) {\n        return value;\n      }\n\n      const newValue = {};\n      for (const prop in value) {","sourceCodeStart":811,"sourceCodeEnd":847,"githubUrl":"https://github.com/Foundry376/Mailspring/blob/648c685d602ece6bb00c22534b8734de6ac644b3/app/src/config.ts#L811-L847","documentation":"Config schema enforcer for type 'null': the value is neither undefined nor null, but the schema declares this key must be null. In practice the enforcer is only reached when a schema pins a key to null; any concrete value fails. Note that coercing null-ish values just unsets the key.","triggerScenarios":"Thrown at app/src/config.ts:829 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Unset the key entirely instead of assigning a value to a null-typed setting","Remove the null-typed schema entry if the key is meant to hold data"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"648c685d602ece6bb00c22534b8734de6ac644b3","analyzedAt":"2026-09-03T02:00:24.311Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-10T07:17:11.731Z"}