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

Errors from selected templated services hide other units #16

Open
ballit6782 opened this issue Jan 19, 2025 · 3 comments
Open

Errors from selected templated services hide other units #16

ballit6782 opened this issue Jan 19, 2025 · 3 comments
Milestone

Comments

@ballit6782
Copy link

ballit6782 commented Jan 19, 2025

It seems that templated services (such as [email protected]) are not handled properly :

Image

On top of showing this error, it hides other selected units.

@ballit6782 ballit6782 changed the title After clicking on templated services, isd fails to switch to other units Errors from selected templated services hide other units Jan 19, 2025
@isd-project isd-project added this to the v0.3.0 milestone Jan 19, 2025
isd-project added a commit that referenced this issue Jan 20, 2025
In reference to #16, `isd` now correctly merges stderr and stdout.
@isd-project
Copy link
Owner

isd-project commented Jan 20, 2025

Good catch!
Thank you for reporting! 🙏

This is a tricky one. "Technically", this is partially the correct behavior, at least if the unit file is selected last.
I have "fixed" an inconsistency between systemctl and isd in the last commit, but it still won't work as "expected" for you.

You can compare the output with systemctl status [email protected] udisks2.service.
systemd will "stop" outputting status information on the first "error".

Now (working just as systemctl status):

Image

Here the "working unit" -09.service is highlighted / selected last, but the stderr is printed at the top, similar to systemctl.
But if I first select -09.service and then [email protected] then only the error message will be shown:

Image

Possible workarounds would "deviate" from the systemctl behaviour, so I am inclined to leave it as is.
Why would you want to keep the (uninstantiated) template unit in the selection?
I understand that it might be relevant to quickly compare the output of cat but since that is "valid" and produces the correct output, I don't really see a reason to add a potentially complex workaround.

Do you think documenting this behavior would suffice?
I am looking forward to your comments, thanks!

@ballit6782
Copy link
Author

Ah right, this happens inside systemd.

I reported it because it was a bit confusing to me, but indeed it's not a very big issue. Maybe a solution would be to "grey out" uninstantiated templates in the list ? Right now there is nothing that makes them stand out, and as they don't have an actual "Status", it would'nt conflict with the existing color code ?

@isd-project
Copy link
Owner

Nice idea! Yeah, I think I will add it to my list and implement it for the next release 👍

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

No branches or pull requests

2 participants