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

RFE: print autodep/autoprov calls if something writes to stderr #620

Closed
nim-nim opened this issue Jan 21, 2019 · 4 comments
Closed

RFE: print autodep/autoprov calls if something writes to stderr #620

nim-nim opened this issue Jan 21, 2019 · 4 comments
Labels
generator Dependency generation related

Comments

@nim-nim
Copy link

nim-nim commented Jan 21, 2019

I had to deal recently with an upstream, whose state caused one of the autodep commands to write to stderr (and not output any of the the expected deps). I think the language the autodep binary is written in allows non-blocking errors. Traces are written to stderr, but processing tries to continue anyway, even though it is usually already doomed, pretty awful for robustness, but that's the language designer choice.

rpm build logs only showed this unhelpful low-level trace, with no indication on which autodep command was erroring, and what were the arguments passed to it. Debugging proved quite tricky.

Please enhance rpm so, when an autodep/autoprov writes to stderr, rpm also prints the command call that resulted in this stderr writing, with all the parameters rpm passed to it.

@nim-nim nim-nim changed the title RFE: log autodep/autoprov calls if something writes to stdout RFE: print autodep/autoprov calls if something writes to stderr Jan 21, 2019
@pmatilai
Copy link
Member

pmatilai commented Feb 4, 2019

In rpm >= 4.14 you can get the exact command and exact file triggering with -vv --rpmfcdebug

Rpm is not interested in the stderr of dependency generators but we could probably provide better diagnostics automatically when a depgen returns with non-zero code.

@nim-nim
Copy link
Author

nim-nim commented Feb 4, 2019

Thanks for the pointer. I'm afraid very few people know about this (me the first)!

Please don't just test for non-zero, test any write on stderr, otherwise you get those weird stderr messages appearing without any trace of what triggered them.

@ffesti ffesti added this to Needs triage in Ticket Review (Outdated) Mar 3, 2020
@ffesti
Copy link
Contributor

ffesti commented Mar 5, 2020

OK, guess having a deeper look into the error handling for the dependency generators is something we should do. Even when it is not entirely clear now what we are going end up doing about this.

@ffesti ffesti moved this from Needs triage to Maybe in Ticket Review (Outdated) Mar 5, 2020
@ffesti ffesti removed this from Maybe in Ticket Review (Outdated) Jul 28, 2022
@pmatilai pmatilai added the generator Dependency generation related label Sep 11, 2023
@pmatilai
Copy link
Member

I don't see us implementing stderr watching as such, so closing this in favor of #1183 - we do need to care about exit code, and emit meaningful diagnostics output in that case.

Advance Dependency Generators automation moved this from To do to Done Nov 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
generator Dependency generation related
Development

No branches or pull requests

3 participants