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 "tail 800 lines: journald" flake #14443

Merged
merged 1 commit into from
Jun 1, 2022

Conversation

Luap99
Copy link
Member

@Luap99 Luap99 commented Jun 1, 2022

The test calls podman run -d followed by podman logs. There is no
guarantee the the container or conmon has written all its output.
Adding an extra podman wait should fix this.

Fixes #14362

Does this PR introduce a user-facing change?

None

@openshift-ci openshift-ci bot added release-note-none approved Indicates a PR has been approved by an approver from all required OWNERS files. labels Jun 1, 2022
@Luap99 Luap99 force-pushed the tail-logs-flake branch from acff83b to e1dba76 Compare June 1, 2022 13:29
Copy link
Member

@vrothberg vrothberg left a comment

Choose a reason for hiding this comment

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

LGTM, nice catch!

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jun 1, 2022

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: Luap99, vrothberg

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@rhatdan
Copy link
Member

rhatdan commented Jun 1, 2022

Could have just removed the -d from command above, but this works wel also. I am surprised this one is not firing all the time.
/lgtm
/hold

@openshift-ci openshift-ci bot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jun 1, 2022
@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Jun 1, 2022
@Luap99
Copy link
Member Author

Luap99 commented Jun 1, 2022

No I do not want to remove the -d. The command prints 1000 lines and they should not be in the test logs by default.

@edsantiago
Copy link
Member

LGTM, but do we have any clue why this test runs podman with -d? If there's no reason, can it just be removed? If there's a reason, can it be documented? Same goes for the previous test, the 99 one, which is less likely to race but I just don't like the possibility even in principle. Nice catch BTW.

@rhatdan
Copy link
Member

rhatdan commented Jun 1, 2022

You could redirect the output to /dev/null. But anyways...

@Luap99
Copy link
Member Author

Luap99 commented Jun 1, 2022

You could redirect the output to /dev/null. But anyways...

Then the test will no longer work, it must print the lines in the container and we cannot redirect the output from the podman command inside the testing suite.

@edsantiago
Copy link
Member

No I do not want to remove the -d. The command prints 1000 lines and they should not be in the test logs by default.

They are anyway, or at least 800 of them are (the output of podman logs is 800 lines). I'm OK with the -d, but I'd like to see this reasoning in a comment so future maintainers don't have to have this same conversation. And I would especially like to see the same wait added to the earlier 99 test.

@edsantiago edsantiago changed the title fix "tail 80 lines: journald" flake fix "tail 800 lines: journald" flake Jun 1, 2022
@Luap99 Luap99 force-pushed the tail-logs-flake branch from e1dba76 to 1256d73 Compare June 1, 2022 13:56
@openshift-ci openshift-ci bot removed the lgtm Indicates that a PR is ready to be merged. label Jun 1, 2022
@Luap99
Copy link
Member Author

Luap99 commented Jun 1, 2022

Removed the -d from the other test since it just prints 3 lines.
Added a comment why we use -d for the 800 lines test.

@mheon
Copy link
Member

mheon commented Jun 1, 2022

/lgtm

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Jun 1, 2022
test/e2e/logs_test.go Outdated Show resolved Hide resolved
The test calls podman run -d followed by podman logs. There is no
guarantee the the container or conmon has written all its output.
Adding an extra podman wait should fix this.

Do not remove the -d to not print 1000 unnecessary lines in the logs.

Fixes containers#14362

Signed-off-by: Paul Holzinger <[email protected]>
@Luap99 Luap99 force-pushed the tail-logs-flake branch from 1256d73 to 78d1f5d Compare June 1, 2022 14:49
@openshift-ci openshift-ci bot removed the lgtm Indicates that a PR is ready to be merged. label Jun 1, 2022
@edsantiago
Copy link
Member

/hold cancel
/lgtm

...and I'd just like to use this PR to confirm that #13936 is working nicely:

SKIPPING: This is a doc- and/or test-only PR with no changes under test/system

@openshift-ci openshift-ci bot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jun 1, 2022
@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Jun 1, 2022
@openshift-merge-robot openshift-merge-robot merged commit f5389db into containers:main Jun 1, 2022
@Luap99 Luap99 deleted the tail-logs-flake branch June 1, 2022 16:21
@github-actions github-actions bot added the locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments. label Sep 21, 2023
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 21, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. lgtm Indicates that a PR is ready to be merged. locked - please file new issue/PR Assist humans wanting to comment on an old issue or PR with locked comments. release-note-none
Projects
None yet
Development

Successfully merging this pull request may close these issues.

tail 800 lines journald: incomplete output
6 participants