Skip to content

fix(loki.source.docker): Parse timestamp correctly when log line only contains newline#5489

Merged
kalleep merged 4 commits intomainfrom
kalleep/fix-docker-regression
Feb 10, 2026
Merged

fix(loki.source.docker): Parse timestamp correctly when log line only contains newline#5489
kalleep merged 4 commits intomainfrom
kalleep/fix-docker-regression

Conversation

@kalleep
Copy link
Contributor

@kalleep kalleep commented Feb 10, 2026

Pull Request Details

Regression from #4713. Before that pr we parsed log lines that only included newlines.

In this pr I fixed the issue so we no longer report an error but we keep the behavior of not forwarding empty lines and add a debug log for these cases.

Issue(s) fixed by this Pull Request

Fixes: #5476

Notes to the Reviewer

PR Checklist

  • Documentation added
  • Tests updated
  • Config converters updated

@kalleep kalleep marked this pull request as ready for review February 10, 2026 10:35
@kalleep kalleep requested a review from a team as a code owner February 10, 2026 10:35
@kalleep kalleep changed the title fix(loki.source.docker): parse timestamp correctly when log line only contains newline fix(loki.source.docker): Parse timestamp correctly when log line only contains newline Feb 10, 2026
@kalleep kalleep merged commit 162011d into main Feb 10, 2026
48 checks passed
@kalleep kalleep deleted the kalleep/fix-docker-regression branch February 10, 2026 15:06
@grafana-alloybot grafana-alloybot bot mentioned this pull request Feb 10, 2026
@kalleep kalleep added the backport/v1.13 Backport to release/v1.13 label Feb 10, 2026
grafana-alloybot bot pushed a commit that referenced this pull request Feb 10, 2026
… contains newline (#5489)

### Pull Request Details
Regression from #4713. Before that
pr we parsed log lines that only included newlines.

In this pr I fixed the issue so we no longer report an error but we keep
the behavior of not forwarding empty lines and add a debug log for these
cases.

### Issue(s) fixed by this Pull Request
Fixes: #5476

### Notes to the Reviewer

<!-- Add any relevant notes for the reviewers and testers of this PR.
-->

### PR Checklist

<!-- Remove items that do not apply. For completed items, change [ ] to
[x]. -->

- [ ] Documentation added
- [x] Tests updated
- [ ] Config converters updated

(cherry picked from commit 162011d)
kalleep added a commit that referenced this pull request Feb 11, 2026
… contains newline [backport] (#5496)

## Backport of #5489

This PR backports #5489 to release/v1.13.

### Original PR Author
@kalleep

### Description
### Pull Request Details
Regression from #4713. Before that
pr we parsed log lines that only included newlines.

In this pr I fixed the issue so we no longer report an error but we keep
the behavior of not forwarding empty lines and add a debug log for these
cases.

### Issue(s) fixed by this Pull Request
Fixes: #5476

### Notes to the Reviewer

<!-- Add any relevant notes for the reviewers and testers of this PR.
-->

### PR Checklist

<!-- Remove items that do not apply. For completed items, change [ ] to
[x]. -->

- [ ] Documentation added
- [x] Tests updated
- [ ] Config converters updated


---
*This backport was created automatically.*

Co-authored-by: Karl Persson <23356117+kalleep@users.noreply.github.com>
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 25, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

backport/v1.13 Backport to release/v1.13 frozen-due-to-age

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Error spam when log lines don't have timestamp

2 participants