-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
system: Keep DBus connection to tuned open over service state changes #21115
system: Keep DBus connection to tuned open over service state changes #21115
Conversation
This is an alternative to #21114. It changes less code and starts the service while the dialog is open (which is nice because we already see the spinner while the service starts.) |
This is ok, the DBus service on the other end of a DBusClient can come and go, the DBusClient keeps working. This avoids closing the DBusClient while it is being used by the rest of the code.
0df1ee3
to
6614bdb
Compare
if (state == "not-installed") | ||
status = _("Tuned is not available"); | ||
else if (state == "not-running") | ||
status = _("Tuned is not running"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This added line is not executed by any test.
else if (state == "not-running") | ||
status = _("Tuned is not running"); | ||
else if (active == "none") | ||
status = _("Tuned is off"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This added line is not executed by any test.
else if (active == "none") | ||
status = _("Tuned is off"); | ||
else if (active == recommended) | ||
status = _("This system is using the recommended profile"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This added line is not executed by any test.
else if (active == recommended) | ||
status = _("This system is using the recommended profile"); | ||
else | ||
status = _("This system is using a custom profile"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This added line is not executed by any test.
Dialogs.show(<TunedDialog updateButton={() => update(tunedDbus)} | ||
poll={() => poll(tunedDbus)} | ||
tunedDbus={tunedDbus} tunedService={tunedService} />); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These 3 added lines are not executed by any test.
No, this doesn't work, unfortunately. Our DBusClient can survive the owner going away and coming back, but there must be an owner when opening the channel. So it works well with auto-activating DBus services that might get restarted, but not here with tuned. Bummer. |
This is ok, the DBus service on the other end of a DBusClient can come and go, the DBusClient keeps working.
This avoids closing the DBusClient while it is being used by the rest of the code.