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

payload/rpm-ostree: Copy stderr to our output #6019

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

cgwalters
Copy link
Contributor

The rpm-ostree container deployment path can fail for many reasons from networking to details in mount setup.

What we really want is a proper API with progress out of bootc/ostree; I will work on that at some point.

In the meantime though, just capture stderr on failure and include it in the payload installation error so people don't have to dig into program.log which is very obscure.

@cgwalters
Copy link
Contributor Author

I think this will work but trying to test it out locally with scripts/makeupdates I'm hitting skew between the current rawhide ISO I think.

@github-actions github-actions bot added the f42 Fedora 42 label Nov 24, 2024
args
)
# TODO refactor things so we can log stdout to the program log or journal.
# For now we just use anaconda's stdout.
Copy link
Contributor

Choose a reason for hiding this comment

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

If you can make it log to Journal, it should be captured even now when something goes wrong - Journal is the de-facto primary log sink for Anaconda these days & what we gather and ask users to attach to bugs. :)

Sure, it would be better if Anaconda got distinct event/callback when something happens, but just making sure everything ends up in Journal would help already. :)

@pep8speaks
Copy link

pep8speaks commented Jan 7, 2025

Hello @cgwalters! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found:

Line 58:13: E128 continuation line under-indented for visual indent

Comment last updated at 2025-01-07 20:27:59 UTC

We have two wrapper function for this which discard one or
the other return value. Make the general function "public" with
via a non-`_` prefixed name, but keep the old name because
there are a number of users.

(Eventually we likely want to clean this up more, but it would
 be highly likely to conflict with other work)

Signed-off-by: Colin Walters <[email protected]>
The rpm-ostree container deployment path can fail for many reasons
from networking to details in mount setup.

What we really want is a proper API with progress out of bootc/ostree;
I will work on that at some point.

In the meantime though, just capture stderr on failure and include
it in the payload installation error so people don't have to
dig into `program.log` which is very obscure.

Signed-off-by: Colin Walters <[email protected]>
@cgwalters
Copy link
Contributor Author

OK, I've tested this now with ostreecontainer --url <garbage> and get the expected more useful error text in the main screen 🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
f42 Fedora 42
Development

Successfully merging this pull request may close these issues.

4 participants