Created attachment 1589324 [details]
test.sh and screen-status-monitor.desktop
Description of problem:
Click Lock menu very soon after login, the screen is locked as expected. But in this case, there is no org.gnome.ScreenSaver related dbus generated, and less way to report screen is locked.
Version-Release number of selected component (if applicable): All Redhat version, I tested at Redhat6.10, and Redhat7.6
How reproducible: Click Lock system menu very quickly after login.
Steps to Reproduce:
1. Put attached test.sh under /tmp/test.sh
2. Put attached screen-status-monitor.desktop to /etc/xdg/autostart/screen-status-monitor.desktop
3. Click Lock menu very quickly after login
4. Verify /tmp/monitor, there is no ScreenSaver related dbus in it
5. Verify /tmp/result, the first "true/false" is to query dbus org.gnome.screensaver.GetAcitve, the second is to query session lock status from loginctl utility, they both indicate "unlocked" status.
In most of time, the query result is "unlocked" status
the query result is "locked" status