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

Don't consume stderr in merge-squashfs #736

Merged
merged 1 commit into from
Jul 6, 2023
Merged

Don't consume stderr in merge-squashfs #736

merged 1 commit into from
Jul 6, 2023

Conversation

jjcarstens
Copy link
Member

Part of nerves-project/nerves#877 for adding more useful output during the firmware build process.

nerves-project/nerves#876 shows cases where mix firmware fails to build. In reproducing, I found that merge-squashfs was failing silently. Specifically at this line because 2>/dev/null was forwarding stderr to be ignored.

Instead, this changes to let stderr through so more helpful messages can be reviewed

Part of nerves-project/nerves#877 for adding more useful output during the firmware build process.

nerves-project/nerves#876 shows cases where `mix firmware` fails to build. In reproducing, I found that `merge-squashfs` was failing silently. Specifically at this line because `2>/dev/null` was forwarding stderr to be ignored.

Instead, this changes to let stderr through so more helpful messages can be reviewed
@fhunleth
Copy link
Member

What's the error?

My feeling is that redirecting stderr was don't on purpose. I agree that it shouldn't be redirected here, but I think that merge-squashfs probably needs to do some stderr redirection now to prevent extraneous output on success cases.

@jjcarstens
Copy link
Member Author

In this case - FATAL ERROR: write_file: file squashfs-root/usr/lib/xtables/libip6t_hl.so already exists

@jjcarstens
Copy link
Member Author

I ran it with a a few different successful builds and it does not seem to output anything (using unsquashfs 4.6.1)

@fhunleth fhunleth merged commit 40871ba into main Jul 6, 2023
@fhunleth fhunleth deleted the script-err-output branch July 6, 2023 15:58
@fhunleth
Copy link
Member

fhunleth commented Jul 6, 2023

Yes. Thanks!!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants