{"record":{"id":"a96aba863b476436","repo":"amir20/dozzle","slug":"invalid-format-unclosed-quotes","errorCode":null,"errorMessage":"invalid format: unclosed quotes","messagePattern":"invalid format: unclosed quotes","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"internal/container/logfmt.go","lineNumber":64,"sourceCode":"\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tif char == '\"' {\n\t\t\t\t\tinQuotes = true\n\t\t\t\t\tstart = i + 1\n\t\t\t\t} else if char == ' ' {\n\t\t\t\t\tvalue = log[start:i]\n\t\t\t\t\tresult.Set(key, value)\n\t\t\t\t\tisKey = true\n\t\t\t\t\tstart = i + 1\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\t// Handle the last key-value pair if there is no trailing space\n\tif !isKey && start < len(log) {\n\t\tif inQuotes {\n\t\t\treturn nil, errors.New(\"invalid format: unclosed quotes\")\n\t\t}\n\t\tvalue = log[start:]\n\t\tresult.Set(key, value)\n\t} else if isKey && start < len(log) {\n\t\treturn nil, errors.New(\"invalid format: unexpected key without value\")\n\t}\n\n\tif !isKey {\n\t\tif inQuotes {\n\t\t\treturn nil, errors.New(\"invalid format: unclosed quotes\")\n\t\t}\n\t\tvalue = log[start:]\n\t\tresult.Set(key, value)\n\t}\n\n\treturn result, nil\n}\n","sourceCodeStart":46,"sourceCodeEnd":82,"githubUrl":"https://github.com/amir20/dozzle/blob/d9463cbe21874e44ab79db6fa63e746ca7d22928/internal/container/logfmt.go#L46-L82","documentation":"At end of input ParseLogFmt is still inside an unterminated quoted value (inQuotes true when the scan finishes). The value's opening '\"' was never closed, so the pair cannot be committed and the whole line fails to parse.","triggerScenarios":"Thrown at internal/container/logfmt.go:64 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Close the quote in the source log line, e.g. msg=\"hello world\".","If quotes are unintended, remove them so the value is parsed as a plain token.","If upstream may emit unclosed quotes, catch this error and fall back to treating the line as a plain text log entry."],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"d9463cbe21874e44ab79db6fa63e746ca7d22928","analyzedAt":"2026-09-07T10:08:55.855Z","contentChangedAt":"2026-09-07T10:08:55.855Z","schemaVersion":2},"datasetVersion":"2026-09-16T04:17:20.429Z"}