Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(logs): correctly handle newlines #2805

Merged
merged 2 commits into from
Jan 19, 2023
Merged

fix(logs): correctly handle newlines #2805

merged 2 commits into from
Jan 19, 2023

Conversation

andrzej-stencel
Copy link
Contributor

Fixes #2802, #2803

The `log` key in container or CRI-O does not have a trailing newline
@andrzej-stencel andrzej-stencel linked an issue Jan 18, 2023 that may be closed by this pull request
@andrzej-stencel andrzej-stencel marked this pull request as ready for review January 18, 2023 14:55
@andrzej-stencel andrzej-stencel requested a review from a team as a code owner January 18, 2023 14:55
Comment on lines +117 to +118
combine_with: |2+

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks pretty weird, why does it get interpreted as a special character?

Copy link
Contributor Author

@andrzej-stencel andrzej-stencel Jan 19, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is just regular Yaml 😉

I looked it up and it seems to be a combination of the "keep" chomping indicator + and the "explicit" indentation indicator 2.

It's actually a bit suspicious, because the next line has no indentation at all, so the 2 seems incorrect 🤔 But hey, the tests pass 🤷

@andrzej-stencel andrzej-stencel merged commit d24928f into main Jan 19, 2023
@andrzej-stencel andrzej-stencel deleted the fix-log-newlines branch January 19, 2023 07:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Multiline logs have newlines stripped Logs from Docker container runtime have a trailing newline
2 participants