PowerToys icon indicating copy to clipboard operation
PowerToys copied to clipboard

PowerToys.Awake no longer shows window or keeps display on when launched with command-line arguments

Open dezertdezine opened this issue 8 months ago • 3 comments

Microsoft PowerToys version

0.90.1

Installation method

PowerToys auto-update

Area(s) with issue?

Awake

Steps to reproduce

Description:

On Windows 10, I have a shortcut pinned to the taskbar to launch PowerToys.Awake with the following configuration:

Description: PowerToys.Awake
Target: "C:\Program Files\PowerToys\PowerToys.Awake.exe" --display-on=true --time-limit=86400 --pid
Start in: "C:\Program Files\PowerToys\"
Run: Normal window

This used to open a window and keep the display on for 24 hours. As of a recent update, launching the shortcut no longer shows a window or keeps the display on. It seems like the command-line options are no longer working as expected.

Steps to Reproduce:

  1. Create a shortcut with the configuration above.
  2. Pin it to the taskbar.
  3. Launch it from the taskbar.

✔️ Expected Behavior

  • A window appears showing the awake session details.
  • Display stays on for the specified duration (24 hours).

❌ Actual Behavior

  • No window appears.
  • Display turns off according to system settings.

Additional Information

  • This used to work correctly before. Might be a regression.
  • Tested launching directly from Command Prompt with the same result.

dezertdezine avatar Apr 14 '25 04:04 dezertdezine

I have the same issue with Windows 11 Pro.

Bug report [attached...

PowerToysReport_2025-05-14-12-41-35.zip

srperryuk avatar May 14 '25 13:05 srperryuk

Seems to be ok from today... appears to be fixed in v0.91.1.

srperryuk avatar May 20 '25 20:05 srperryuk

Today, I updated to PowerToys v0.91.1 and rebooted, but the problem persisted. I then disabled the module from the dashboard, and after that, the CLI worked as expected. Perhaps disabling the module was the fix all along?

dezertdezine avatar May 21 '25 08:05 dezertdezine

Hi @dezertdezine. Could I ask a couple of questions:

  1. You included the --pid option in your command, but no value after it. Was this a mistake, or did you intend to track another application? When no value is provided, the argument will be ignored for now, so your timed awake will still work. However, if we tighten up parameter checks in the future, you may get an error.

  2. You noted that things were working again a while ago. Could I confirm that it is still the case so we can close out this issue, please?

Many thanks!

/needinfo

daverayment avatar Sep 10 '25 13:09 daverayment

Hi @daverayment.

  1. It looks like the --pid option was indeed added in error. I’ve removed it, and the command continues to work as expected.
  2. I can confirm it's still working as expected. From my point of view, it should be fine to close this issue.

dezertdezine avatar Sep 10 '25 15:09 dezertdezine

That's great to hear, @dezertdezine. Thanks very much for confirming.

daverayment avatar Sep 10 '25 16:09 daverayment