Closed 0xC0ncord closed 2 years ago
If exec-on-event
is set to true, the exec
command should always run after the on-click
command so the script should update immediately.
However sometimes the exec
command is run after the on-click
command, and sometimes before. The module doesn't update correctly when the exec
command is run before the on-click
command.
According to the documentation:
If an event command is set (e.g. on-click or on-scroll-up) then re-execute the script after executing the event command.
So the exec
command should always be executed after the on-click
command, which is not currently the case. I think that might be what's causing this inconsistent behavior.
I have the following config in use:
When the widget is clicked, the script kills/starts a background process and returns the status of it as
alt
depending on the state of the process. The icon of the widget should update immediately as soon as it is clicked (with respect to the interval it seems), but it does not. I discovered that if I setformat
to"{icon}{}"
this works as expected, even if the script returns an empty string intext
.I expect the widget icon to update immediately even if no
text
is returned by the process started inon-click
.EDIT: It seems to be more wildly inconsistent than I originally thought. Sometimes it updates immediately, sometimes not. I have another widget with this exact configuration (yet using the
text
field) that does not have this issue.